index(); return $this->success('', $detail); } /** * @notes 主题页面列表 * @return \think\response\Json * @author cjhao * @date 2021/8/5 10:44 */ public function lists() { return $this->dataLists(); } /** * @notes 获取主题页面 * @author cjhao * @date 2021/8/5 10:44 */ public function getPage() { $params = $this->request->get(); $detail = (new DecorateThemePageLogic())->getPage($params); return $this->success('', $detail); } /** * @notes 设置主页 * @return \think\response\Json * @author cjhao * @date 2021/8/6 16:08 */ public function setHome() { $params = (new DecoratePageValidate())->post()->goCheck('setHome'); (new DecorateThemePageLogic())->setHome($params['id']); return $this->success('操作成功', [], 1, 1); } /** * @notes 新增主题页面 * @return \think\response\Json * @author cjhao * @date 2021/8/5 11:03 */ public function add() { $params = $this->request->post(); $id = (new DecorateThemePageLogic())->add($params); return $this->success('操作成功', ['id' => $id]); } /** * @notes 编辑主题页面 * @return \think\response\Json * @author cjhao * @date 2021/8/5 11:04 */ public function edit() { $params = (new DecoratePageValidate())->post()->goCheck('edit'); $data = (new DecorateThemePageLogic())->edit($params); return $this->success('操作成功', $data, 1, 1); } /** * @notes 删除主页 * @return \think\response\Json * @author cjhao * @date 2021/8/9 19:31 */ public function del() { $params = (new DecoratePageValidate())->post()->goCheck('del'); (new DecorateThemePageLogic())->del($params['id']); return $this->success('操作成功', [], 1, 1); } /** * @notes 商城页面 * @return \think\response\Json * @author cjhao * @date 2021/8/12 16:28 */ public function getShopPage() { $type = $this->request->get('type','shop'); $page = (new DecorateThemePageLogic())->getShopPage($type); return $this->success('操作成功',$page); } }