我使用此代码使用Google Analytics
获取实时信息和App Review,代码在AppDelegate中:
[GAI sharedInstance].trackUncaughtExceptions = YES;
[[GAI sharedInstance].logger setLogLevel:kGAILogLevelVerbose];
[GAI sharedInstance].dispatchInterval = kGANDispatchPeriodSec;
self.tracker = [[GAI sharedInstance] trackerWithName:@"APP_NAME" trackingId:kGoogleAnalyticsCode];
self.tracker.allowIDFACollection = NO;
[self.tracker set:kGAIScreenName value:@"APP_NAME"];
[self.tracker send:[[GAIDictionaryBuilder createScreenView] build]];
我在控制台中获取此日志:
VERBOSE: GoogleAnalytics 3.13 +[GAITrackerModel initialize] (GAITrackerModel.m:88): idfa class missing, won't collect idfa
VERBOSE: GoogleAnalytics 3.13 -[GAIBatchingDispatcher persist:] (GAIBatchingDispatcher.m:517): Saved hit: {
parameters = {
"&_crc" = 0;
"&_s" = 10;
"&_u" = ".etnK9L";
"&_v" = "mi3.1.3";
"&av" = "1.0";
"&dm" = "iPhone7,2";
"&ds" = app;
"&sr" = 750x1334;
"&t" = screenview;
"&ul" = "en-il";
"&v" = 1;
gaiVersion = "3.13";
};
timestamp = "2015-10-08 13:36:40 +0000";
}
VERBOSE: GoogleAnalytics 3.13 __70-[GAIBatchingDispatcher checkIAdCampaignAttributionWithHitParameters:]_block_invoke (GAIBatchingDispatcher.m:749): iAd campaign tracking disabled because the iAd framework is not linked. See http://goo.gl/426NGa for instructions.
INFO: GoogleAnalytics 3.13 -[GAIReachabilityChecker reachabilityFlagsChanged:] (GAIReachabilityChecker.m:159): Reachability flags update: 0X000002
任何想法在Google Analytics
的实时控制台中我什么都看不到的问题