diff --git a/.env.production b/.env.production index edcba1dcea732798da1e9c73fb8386a4f864a99d..e00340397f0a9a7ea2f220f87e131b08578d415f 100644 --- a/.env.production +++ b/.env.production @@ -2,7 +2,7 @@ VITE_USE_MOCK = true # public path -VITE_PUBLIC_PATH = / +VITE_PUBLIC_PATH = 'https://tmallab.cn/ops/' # Delete console VITE_DROP_CONSOLE = true diff --git a/src/store/modules/user.ts b/src/store/modules/user.ts index 8340d94684c84b8485c51540acc50193e0c00fa0..573f9286693f2b5bc6dbd01e469d8ae14a62ecc7 100644 --- a/src/store/modules/user.ts +++ b/src/store/modules/user.ts @@ -142,6 +142,11 @@ export const useUserStore = defineStore({ routes.forEach((route) => { router.addRoute(route as unknown as RouteRecordRaw); }); + if (routes.findIndex((v) => v.path === '/supplierInfoManage') !== -1) { + userInfo.homePath = '/supplierInfoManage/index'; + } else { + userInfo.homePath = '/RegionalSpotManage/index'; + } router.addRoute(PAGE_NOT_FOUND_ROUTE as unknown as RouteRecordRaw); permissionStore.setDynamicAddedRoute(true); }