浏览代码

1.添加libAdIdAccess,Tracker设置IDFACollection。

Pen Li 9 年之前
父节点
当前提交
21669a7598

二进制
RedAnt ERP Mobile/GoogleAnalytics/GoogleAnalytics/Libraries/libAdIdAccess.a


二进制
RedAnt ERP Mobile/RedAnt ERP Mobile.xcworkspace/xcuserdata/macmini1.xcuserdatad/UserInterfaceState.xcuserstate


+ 8 - 0
RedAnt ERP Mobile/iSales-NPD.xcodeproj/project.pbxproj

@@ -50,6 +50,8 @@
 		42BF67CC1E5179970081F90A /* ERPUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = 42BF67CB1E5179970081F90A /* ERPUtils.m */; };
 		42C2E8BC1DB49D02006C0495 /* TearSheet.json in Resources */ = {isa = PBXBuildFile; fileRef = 42C2E8BB1DB49D02006C0495 /* TearSheet.json */; };
 		42C9FB151D5B28FA001DCA8B /* contactAdvanceSearch.json in Resources */ = {isa = PBXBuildFile; fileRef = 42C9FB141D5B28FA001DCA8B /* contactAdvanceSearch.json */; };
+		42D9A0231EB02DA6008AF7AF /* AdSupport.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 42D9A0221EB02DA6008AF7AF /* AdSupport.framework */; };
+		42D9A0251EB03994008AF7AF /* libAdIdAccess.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 42D9A0241EB03994008AF7AF /* libAdIdAccess.a */; };
 		42DC31131D546FBE00BCD1C6 /* category.json in Resources */ = {isa = PBXBuildFile; fileRef = 42DC31121D546FBE00BCD1C6 /* category.json */; };
 		710274251CC606C4009FD219 /* UserListViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 710274241CC606C4009FD219 /* UserListViewController.m */; };
 		71073AE61DD41DD8001BC653 /* so_thumb.json in Resources */ = {isa = PBXBuildFile; fileRef = 71073AE51DD41DD8001BC653 /* so_thumb.json */; };
@@ -343,6 +345,8 @@
 		42BF67CB1E5179970081F90A /* ERPUtils.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ERPUtils.m; path = common/ERPUtils.m; sourceTree = SOURCE_ROOT; };
 		42C2E8BB1DB49D02006C0495 /* TearSheet.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = TearSheet.json; sourceTree = "<group>"; };
 		42C9FB141D5B28FA001DCA8B /* contactAdvanceSearch.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = contactAdvanceSearch.json; sourceTree = "<group>"; };
+		42D9A0221EB02DA6008AF7AF /* AdSupport.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AdSupport.framework; path = System/Library/Frameworks/AdSupport.framework; sourceTree = SDKROOT; };
+		42D9A0241EB03994008AF7AF /* libAdIdAccess.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libAdIdAccess.a; sourceTree = "<group>"; };
 		42DC31121D546FBE00BCD1C6 /* category.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = category.json; sourceTree = "<group>"; };
 		56528CA8B8A71F67C2EE5366 /* Pods.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.debug.xcconfig; path = "Pods/Target Support Files/Pods/Pods.debug.xcconfig"; sourceTree = "<group>"; };
 		6C826876B24EFB83AC94A464 /* Pods.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = Pods.release.xcconfig; path = "Pods/Target Support Files/Pods/Pods.release.xcconfig"; sourceTree = "<group>"; };
@@ -738,6 +742,8 @@
 			isa = PBXFrameworksBuildPhase;
 			buildActionMask = 2147483647;
 			files = (
+				42D9A0251EB03994008AF7AF /* libAdIdAccess.a in Frameworks */,
+				42D9A0231EB02DA6008AF7AF /* AdSupport.framework in Frameworks */,
 				42BEF35F1E89FEE300632AB6 /* CoreData.framework in Frameworks */,
 				42BEF35D1E89FECD00632AB6 /* SystemConfiguration.framework in Frameworks */,
 				71BBA2291CEAC17E00C91DED /* libz.tbd in Frameworks */,
@@ -948,6 +954,7 @@
 			isa = PBXGroup;
 			children = (
 				42BEF33C1E89FE1100632AB6 /* libGoogleAnalytics.a */,
+				42D9A0241EB03994008AF7AF /* libAdIdAccess.a */,
 			);
 			path = Libraries;
 			sourceTree = "<group>";
@@ -992,6 +999,7 @@
 		42BEF35B1E89FECC00632AB6 /* Frameworks */ = {
 			isa = PBXGroup;
 			children = (
+				42D9A0221EB02DA6008AF7AF /* AdSupport.framework */,
 				42BEF35E1E89FEE300632AB6 /* CoreData.framework */,
 				42BEF35C1E89FECD00632AB6 /* SystemConfiguration.framework */,
 			);

+ 4 - 0
RedAnt ERP Mobile/iSales-NPD/AppDelegate.m

@@ -810,6 +810,10 @@ void UncaughtExceptionHandler(NSException *exception) {
     
     GAI *gai = [GAI sharedInstance];
     gai.trackUncaughtExceptions = YES;
+    
+    id<GAITracker> tracker = [[GAI sharedInstance] defaultTracker];
+    // Enable IDFA collection.
+    tracker.allowIDFACollection = YES;
 //    gai.dispatchInterval = 120;// 每隔 2 分钟调度一次数据
     
     // 调试使用

+ 1 - 1
RedAnt ERP Mobile/iSales-NPD/GoogleService-Info.plist

@@ -3,7 +3,7 @@
 <plist version="1.0">
 <dict>
 	<key>TRACKING_ID</key>
-	<string>UA-61172313-2</string>
+	<string>UA-96243475-2</string>
 	<key>PLIST_VERSION</key>
 	<string>1</string>
 	<key>BUNDLE_ID</key>

+ 1 - 1
RedAnt ERP Mobile/iSales-NPD/config.h

@@ -11,7 +11,7 @@
 #define BUILD_NPD
 
 # ifdef DEBUG
-//#define test_server
+#define test_server
 # endif
 
 #define exception_switch 1