| 123456789101112131415161718192021222324252627282930313233343536373839404142 |
- <?php
- namespace addons\Store\backend\controllers;
- use addons\Store\common\services\StoreStatisticsService;
- /**
- * 资产统计
- */
- class StoreStatisticsController extends BaseController
- {
- /**
- * 资产统计
- *
- * @return string
- */
- public function actionIndex(): string
- {
- return $this->render('index');
- }
- /**
- * 收入明细
- *
- * @return mixed
- */
- public function actionIncomeLog()
- {
- if (!\Yii::$app->request->isAjax) {
- return $this->render($this->action->id);
- }
- $params = $this->request->get();
- if (empty($params['store_id'])) {
- return $this->error('门店参数不存在');
- }
- $service = new StoreStatisticsService($this->mall_id, $params['store_id']);
- return $this->success('success', $service->getIncomeLogList($params, $this->pageSize));
- }
- }
|