| | |
| | | use app\shop\model\branch\Category as CategoryModel; |
| | | use app\shop\model\user\User as UserModel; |
| | | use app\common\service\qrcode\BranchActivityService; |
| | | use app\common\model\branch\ActivityProductPrice as ActivityProductPriceModel; |
| | | |
| | | /** |
| | | * 活动控制器 |
| | |
| | | $model = new ActivityModel; |
| | | $list = $model->getList($this->postData()); |
| | | return $this->renderSuccess('', compact('list')); |
| | | } |
| | | |
| | | /** |
| | | * 审核活动 |
| | | */ |
| | | public function audit($activity_id) |
| | | { |
| | | $model = new ActivityModel; |
| | | if ($model->audit($activity_id, $this->postData())) { |
| | | return $this->renderSuccess('审核成功'); |
| | | } |
| | | return $this->renderError($model->getError() ?: '审核失败'); |
| | | } |
| | | |
| | | /** |
| | |
| | | $tem_act_date[1] = date("Y-m-d H:i:s",$model['activity_end_time']); |
| | | $model['act_date'] = $tem_act_date; |
| | | $model['coordinate'] = $model['latitude'] . ',' . $model['longitude']; |
| | | // 获取核销人员数据 |
| | | $model['verify_user'] = []; |
| | | if ($model['verify_user_ids']) { |
| | | $model['verify_user'] = UserModel::getUserByIds($model['verify_user_ids'], ['avatarUrl', 'nickName']); |
| | | } |
| | | |
| | | $model['product_list'] = (new ActivityProductPriceModel())->getProductPricelist($activity_id); |
| | | |
| | | return $this->renderSuccess('', compact('catgory', 'model')); |
| | | } |
| | | // 活动详情 |