From 9c43fe42bdb78d093af25b6ad83d557e7be05dc5 Mon Sep 17 00:00:00 2001 From: limu Date: Thu, 25 Jan 2024 14:48:53 +0800 Subject: [PATCH] Changes --- app/api/controller/Store.php | 14 ++++++++++++++ app/api/service/Store.php | 9 ++++++++- config/store.php | 8 ++++++++ 3 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 config/store.php diff --git a/app/api/controller/Store.php b/app/api/controller/Store.php index dde71e37..ef117773 100644 --- a/app/api/controller/Store.php +++ b/app/api/controller/Store.php @@ -12,6 +12,7 @@ declare (strict_types=1); namespace app\api\controller; +use app\api\service\User as UserService; use think\response\Json; use app\api\service\Store as StoreService; use think\db\exception\DataNotFoundException; @@ -37,4 +38,17 @@ class Store extends Controller $service = new StoreService; return $this->renderSuccess($service->data()); } + + public function joinStore(): Json + { + // 当前用户信息 + $userInfo = UserService::getCurrentLoginUser(true); + $service = new StoreService; + return $this->renderSuccess('申请成功,请耐心等待'); + } + + public function getStoreType(): Json + { + return $this->renderSuccess(config('store.store_type')); + } } \ No newline at end of file diff --git a/app/api/service/Store.php b/app/api/service/Store.php index e7e24613..507e09f6 100644 --- a/app/api/service/Store.php +++ b/app/api/service/Store.php @@ -58,7 +58,8 @@ class Store extends BaseService * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException */ - private function getModules() { + private function getModules() + { return StoreModuleModel::getModules($this->storeId); } @@ -108,4 +109,10 @@ class Store extends BaseService { return StoreModel::getInfo(); } + + //申请入驻 + public function joinStore() + { + + } } \ No newline at end of file diff --git a/config/store.php b/config/store.php new file mode 100644 index 00000000..2d361d07 --- /dev/null +++ b/config/store.php @@ -0,0 +1,8 @@ + [ + '京东店铺','拼多多店铺','苏宁店铺','唯品会店铺','淘宝店铺','天猫店铺','其他平台' + ], +];