diff --git a/.env.development b/.env.development index 41b0ae9..fbcc74b 100644 --- a/.env.development +++ b/.env.development @@ -1,6 +1,6 @@ VITE_APP_NAME=后台管理(开发环境) -#VITE_API_URL=http://192.168.1.131:9200/api -VITE_SERVER_API_URL=http://127.0.0.1:8000/api +VITE_API_URL=http://127.0.0.1:9200/api +#VITE_SERVER_API_URL=http://127.0.0.1:8000/api #VITE_API_URL=https://cms-api.s209.websoft.top/api diff --git a/src/api/shop/shopMerchantApply/index.ts b/src/api/shop/shopMerchantApply/index.ts index 1a725f6..29e9c69 100644 --- a/src/api/shop/shopMerchantApply/index.ts +++ b/src/api/shop/shopMerchantApply/index.ts @@ -40,7 +40,7 @@ export async function listShopMerchantApply(params?: ShopMerchantApplyParam) { */ export async function addShopMerchantApply(data: ShopMerchantApply) { const res = await request.post>( - SERVER_API_URL + '/shop/shop-merchant-apply', + '/shop/shop-merchant-apply', data ); if (res.data.code === 0) { @@ -75,6 +75,17 @@ export async function checkShopMerchantApply(data: ShopMerchantApply) { return Promise.reject(new Error(res.data.message)); } +// 根据入驻申请创建商户 +export async function createMerchantFromApply(applyId: number) { + const res = await request.post>( + SERVER_API_URL + '/shop/shop-merchant-apply/create-merchant/' + applyId + ); + if (res.data.code === 0) { + return res.data.message; + } + return Promise.reject(new Error(res.data.message)); +} + /** * 删除商户入驻申请 */ diff --git a/src/api/shop/shopMerchantApply/model/index.ts b/src/api/shop/shopMerchantApply/model/index.ts index 6e02334..b4a6c80 100644 --- a/src/api/shop/shopMerchantApply/model/index.ts +++ b/src/api/shop/shopMerchantApply/model/index.ts @@ -8,6 +8,8 @@ export interface ShopMerchantApply { applyId?: number; // 类型 type?: number; + // 证件类型 + idType?: string; // 主体名称 merchantName?: string; // 证件号码 @@ -69,4 +71,4 @@ export interface ShopMerchantApplyParam extends PageParam { shopType?: string; phone?: string; keywords?: string; -} +} \ No newline at end of file diff --git a/src/config/menu.ts b/src/config/menu.ts index 7053780..d6d5872 100644 --- a/src/config/menu.ts +++ b/src/config/menu.ts @@ -34,6 +34,18 @@ export default [ component: '/appstore', meta: { title: '应用管理', icon: 'AppstoreOutlined' } }, + { + path: '/shop', + redirect: '/shop/shopMerchantApply', + meta: { title: '商城管理', icon: 'ShoppingOutlined' }, + children: [ + { + path: '/shop/shopMerchantApply', + component: '/shop/shopMerchantApply', + meta: { title: '商户入驻申请', icon: 'UserAddOutlined' } + } + ] + }, { path: '/system', redirect: '/system/user', @@ -114,4 +126,4 @@ export default [ component: '/passport/register/index.vue', meta: { title: '免费注册' } } -]; +]; \ No newline at end of file diff --git a/src/router/routes.ts b/src/router/routes.ts index eca468f..45cbd72 100644 --- a/src/router/routes.ts +++ b/src/router/routes.ts @@ -45,6 +45,16 @@ export const routes = [ component: () => import('@/components/QrLogin/demo.vue'), meta: { title: '二维码登录演示' } }, + { + path: '/merchant/apply', + component: () => import('@/views/passport/merchant/apply.vue'), + meta: { title: '商家入驻申请' } + }, + { + path: '/merchant/success', + component: () => import('@/views/passport/merchant/success.vue'), + meta: { title: '申请提交成功' } + }, // { // path: '/forget', // component: () => import('@/views/passport/forget/index.vue'), diff --git a/src/views/cms/cmsWebsite/components/search.vue b/src/views/cms/cmsWebsite/components/search.vue index c893ea6..8a76723 100644 --- a/src/views/cms/cmsWebsite/components/search.vue +++ b/src/views/cms/cmsWebsite/components/search.vue @@ -1,100 +1,71 @@ diff --git a/src/views/passport/merchant/apply.vue b/src/views/passport/merchant/apply.vue new file mode 100644 index 0000000..e845f2d --- /dev/null +++ b/src/views/passport/merchant/apply.vue @@ -0,0 +1,581 @@ + + + + + diff --git a/src/views/passport/merchant/success.vue b/src/views/passport/merchant/success.vue new file mode 100644 index 0000000..feda021 --- /dev/null +++ b/src/views/passport/merchant/success.vue @@ -0,0 +1,41 @@ + + + + + diff --git a/src/views/shop/shopMerchant/components/apply.vue b/src/views/shop/shopMerchant/components/apply.vue new file mode 100644 index 0000000..e845f2d --- /dev/null +++ b/src/views/shop/shopMerchant/components/apply.vue @@ -0,0 +1,581 @@ + + + + + diff --git a/src/views/shop/shopMerchant/components/extra.vue b/src/views/shop/shopMerchant/components/extra.vue new file mode 100644 index 0000000..64591d1 --- /dev/null +++ b/src/views/shop/shopMerchant/components/extra.vue @@ -0,0 +1,56 @@ + + + + diff --git a/src/views/shop/shopMerchant/components/search.vue b/src/views/shop/shopMerchant/components/search.vue index 9f23b97..9f9bf53 100644 --- a/src/views/shop/shopMerchant/components/search.vue +++ b/src/views/shop/shopMerchant/components/search.vue @@ -1,18 +1,20 @@ + + \ No newline at end of file diff --git a/src/views/shop/shopMerchantApply/components/search.vue b/src/views/shop/shopMerchantApply/components/search.vue new file mode 100644 index 0000000..ac0c0a1 --- /dev/null +++ b/src/views/shop/shopMerchantApply/components/search.vue @@ -0,0 +1,143 @@ + + + \ No newline at end of file diff --git a/src/views/shop/shopMerchantApply/components/shopMerchantApplyEdit.vue b/src/views/shop/shopMerchantApply/components/shopMerchantApplyEdit.vue new file mode 100644 index 0000000..e315d50 --- /dev/null +++ b/src/views/shop/shopMerchantApply/components/shopMerchantApplyEdit.vue @@ -0,0 +1,657 @@ + + + + + \ No newline at end of file diff --git a/src/views/shop/shopMerchantApply/index.vue b/src/views/shop/shopMerchantApply/index.vue new file mode 100644 index 0000000..b5a36e4 --- /dev/null +++ b/src/views/shop/shopMerchantApply/index.vue @@ -0,0 +1,215 @@ + + + + + \ No newline at end of file