request->get('classId',0); $where['merchantId'] = $this->sjId; $where['classId'] = $classId; $list = ItemClass::getGhsItemList($where); util::success($list); } public function actionAdd() { $post = Yii::$app->request->post(); $post['adminId'] = $this->adminId; $post['shopId'] = $this->shopId; $post['merchantId'] = $this->sjId; ItemService::addGhsItem($post); util::complete('添加成功'); } public function actionUpdate() { $data = Yii::$app->request->post(); $data['adminId'] = $this->adminId; $data['merchantId'] = $this->sjId; ItemService::updateGshItem($data); util::complete('修改成功'); } public function actionDelete() { $get = Yii::$app->request->get(); $id = isset($get['id']) ? $get['id'] : 0; ItemService::deleteGhsItem($id,$this->shopId,$this->adminId); util::complete('操作成功'); } //获取平台里的花材信息 public function actionPlatformItem() { $py = Yii::$app->request->get('py',''); $where = []; if($py){ $where = ['py' => $py]; } $list = xhItemService::getItemList('*',$where,'id desc'); util::success($list); } }