From 5802e157bf65d353d71be3dd7ff0579bcc971163 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B5=85=E5=BF=B5?= Date: Fri, 11 Jul 2025 19:43:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=B7=A5=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 4 ++-- .env.production | 2 +- src/api/menuApi.ts | 4 ++++ src/router/routes/staticRoutes.ts | 6 ++++++ src/router/routesAlias.ts | 2 +- src/typings/api.d.ts | 1 + src/views/auth/login/index.vue | 4 +++- src/views/work/myOrder/index.vue | 9 ++++++++- src/views/work/order/index.vue | 19 +++++++++++++++---- 9 files changed, 41 insertions(+), 10 deletions(-) diff --git a/.env.development b/.env.development index 67f5f87..e82d846 100644 --- a/.env.development +++ b/.env.development @@ -6,8 +6,8 @@ VITE_BASE_URL = / # API 地址前缀 # VITE_API_URL = https://m1.apifoxmock.com/m1/6400575-6097373-default # VITE_API_URL = http://219.157.255.213:25702 -VITE_API_URL = https://mzl.dev.hnxinyouhe.com -# VITE_API_URL = https://fdesk.hnxinyouhe.com +# VITE_API_URL = https://mzl.dev.hnxinyouhe.com +VITE_API_URL = https://fdesk.hnxinyouhe.com # Delete console diff --git a/.env.production b/.env.production index 4625c59..729be18 100644 --- a/.env.production +++ b/.env.production @@ -4,7 +4,7 @@ VITE_BASE_URL = / # API 地址前缀 -VITE_API_URL = https://mzl.dev.hnxinyouhe.com +VITE_API_URL = https://fdesk.hnxinyouhe.com # Delete console VITE_DROP_CONSOLE = true \ No newline at end of file diff --git a/src/api/menuApi.ts b/src/api/menuApi.ts index b78161a..68506c7 100644 --- a/src/api/menuApi.ts +++ b/src/api/menuApi.ts @@ -13,6 +13,9 @@ export const menuService = { const userStore = useUserStore() // 模拟接口返回的菜单数据 const menuData = userStore.info.menu + if(menuData.length==0){ + ElMessage.error('暂无系统菜单权限') + } const menuData1 = asyncRoutes // 处理菜单数据 // const menuList1 = menuData1.map((route) => menuDataToRouter(route)) @@ -23,6 +26,7 @@ export const menuService = { await new Promise((resolve) => setTimeout(resolve, delay)) return { menuList } + } catch (error) { throw error instanceof Error ? error : new Error('获取菜单失败') } diff --git a/src/router/routes/staticRoutes.ts b/src/router/routes/staticRoutes.ts index f9e3a8c..7a011c4 100644 --- a/src/router/routes/staticRoutes.ts +++ b/src/router/routes/staticRoutes.ts @@ -11,6 +11,12 @@ export const staticRoutes: AppRouteRecordRaw[] = [ path: '/', redirect: HOME_PAGE }, + { + path: '/console', + name: 'Console', + component: () => import('@views/dashboard/console/index.vue'), + meta: { title: 'menus.dashboard.console', isHideTab: true, setTheme: true } + }, { path: RoutesAlias.Login, name: 'Login', diff --git a/src/router/routesAlias.ts b/src/router/routesAlias.ts index 4e4d965..a48b03d 100644 --- a/src/router/routesAlias.ts +++ b/src/router/routesAlias.ts @@ -56,4 +56,4 @@ export enum RoutesAlias { // 主页路由 // export const HOME_PAGE = RoutesAlias.Dashboard -export const HOME_PAGE = '/work/order' +export const HOME_PAGE = RoutesAlias.Dashboard diff --git a/src/typings/api.d.ts b/src/typings/api.d.ts index 144e729..2a5f815 100644 --- a/src/typings/api.d.ts +++ b/src/typings/api.d.ts @@ -58,6 +58,7 @@ declare namespace Api { namespace User { /** 用户信息 */ interface UserInfo { + user: any userId: number userName: string roles: string[] diff --git a/src/views/auth/login/index.vue b/src/views/auth/login/index.vue index c0c0091..e607b46 100644 --- a/src/views/auth/login/index.vue +++ b/src/views/auth/login/index.vue @@ -426,7 +426,9 @@ try { // 这里调用获取品牌列表的接口 feishuresponse.value = await UserService.getfeishuAppList({ corp_id: companyid.value }) - feishulogin() + if(activeLoginType.value=='qrcode'){ + feishulogin() + } console.log(feishuresponse) } catch (error) { } } diff --git a/src/views/work/myOrder/index.vue b/src/views/work/myOrder/index.vue index c57c53f..6c61fda 100644 --- a/src/views/work/myOrder/index.vue +++ b/src/views/work/myOrder/index.vue @@ -23,7 +23,7 @@ @@ -453,6 +453,13 @@ function handleVideoClick(url: string) {