Commit 28168cadb5efbd83e7130566798fcfa7bf76c509
1 parent
9b8fbac2
ga output
Showing
1 changed file
with
8 additions
and
2 deletions
Show diff stats
app/library/App/Controllers/GaController.php
... | ... | @@ -78,8 +78,14 @@ class GaController extends CrudResourceController { |
78 | 78 | |
79 | 79 | $response = $analytics->reports->batchGet($body); |
80 | 80 | |
81 | - $response = $response->toSimpleObject(); | |
82 | - $response = $response->reports[0]['data']['rows']; | |
81 | + $report = $response->getReports()[0]; | |
82 | + $rows = $report->getData()->getRows(); | |
83 | + | |
84 | + die(var_dump($rows)); | |
85 | + | |
86 | + | |
87 | + //$response = $response->toSimpleObject(); | |
88 | + //$response = $response->reports[0]['data']['rows']; | |
83 | 89 | |
84 | 90 | $result = []; |
85 | 91 | ... | ... |