|
@@ -493,7 +493,7 @@ class GA{
|
|
$analytics=self::getInstance($dp);
|
|
$analytics=self::getInstance($dp);
|
|
$dimensionArr=[
|
|
$dimensionArr=[
|
|
// 'date'=>'ga:date',
|
|
// 'date'=>'ga:date',
|
|
- 'sessionCount'=>'ga:sessionCount',
|
|
|
|
|
|
+ // 'sessionCount'=>'ga:sessionCount',
|
|
];
|
|
];
|
|
|
|
|
|
$VIEW_ID = $this->getViewId($dp);//
|
|
$VIEW_ID = $this->getViewId($dp);//
|
|
@@ -525,6 +525,8 @@ class GA{
|
|
$reports= $analytics->reports->batchGet( $body );
|
|
$reports= $analytics->reports->batchGet( $body );
|
|
|
|
|
|
$result=$this->getResults($reports);
|
|
$result=$this->getResults($reports);
|
|
|
|
+ echo "<pre>";
|
|
|
|
+ print_r($reports);exit;
|
|
return $result;
|
|
return $result;
|
|
|
|
|
|
}
|
|
}
|
|
@@ -587,7 +589,7 @@ class GA{
|
|
$body = new \Google_Service_AnalyticsReporting_GetReportsRequest();
|
|
$body = new \Google_Service_AnalyticsReporting_GetReportsRequest();
|
|
$body->setReportRequests( array( $request) );
|
|
$body->setReportRequests( array( $request) );
|
|
$reports= $analytics->reports->batchGet( $body );
|
|
$reports= $analytics->reports->batchGet( $body );
|
|
-
|
|
|
|
|
|
+
|
|
$result=$this->getResults($reports);
|
|
$result=$this->getResults($reports);
|
|
return $result;
|
|
return $result;
|
|
}
|
|
}
|