From b3979773b416dd0e3e1198f7d5628687def00d14 Mon Sep 17 00:00:00 2001 From: andrey Date: Mon, 5 Jul 2021 15:30:35 +0300 Subject: [PATCH] api reports controller --- .../api/controllers/ReportsController.php | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 frontend/modules/api/controllers/ReportsController.php diff --git a/frontend/modules/api/controllers/ReportsController.php b/frontend/modules/api/controllers/ReportsController.php new file mode 100644 index 0000000..42ffdb0 --- /dev/null +++ b/frontend/modules/api/controllers/ReportsController.php @@ -0,0 +1,39 @@ + \yii\filters\ContentNegotiator::className(), + 'formats' => [ + 'application/json' => \yii\web\Response::FORMAT_JSON, + ], + ], + 'corsFilter' => [ + 'class' => GsCors::class, + 'cors' => [ + 'Origin' => ['*'], + //'Access-Control-Allow-Credentials' => true, + 'Access-Control-Allow-Headers' => [ + 'Content-Type', + 'Access-Control-Allow-Headers', + 'Authorization', + 'X-Requested-With' + ], + ] + ] + ]; + } + + public function actionIndex() + { + + } + +}