diff --git a/app/Http/Controllers/V2/MonitoredData/GetPolygonsIndicatorAnalysisController.php b/app/Http/Controllers/V2/MonitoredData/GetPolygonsIndicatorAnalysisController.php index 13800a69..01e465c5 100644 --- a/app/Http/Controllers/V2/MonitoredData/GetPolygonsIndicatorAnalysisController.php +++ b/app/Http/Controllers/V2/MonitoredData/GetPolygonsIndicatorAnalysisController.php @@ -78,6 +78,7 @@ public function __invoke(EntityModel $entity, string $slug) 'year_of_analysis' => $indicator->year_of_analysis, 'created_at' => $indicator->created_at, 'base_line' => $indicator->created_at, + 'data' => [], ]; if (str_contains($slug, 'treeCoverLoss')) { $valueYears = json_decode($indicator->value, true); @@ -115,6 +116,6 @@ public function processValuesHectares($values) } } - return $separateKeys; + return ['data' => $separateKeys]; } }