From 2701925e997420e546b03ced40e021fea61a0a9d Mon Sep 17 00:00:00 2001 From: Qi <3194726156@qq.com> Date: Sat, 24 May 2025 19:53:01 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AE=BF=E9=97=AE=E6=97=B6?= =?UTF-8?q?=E9=97=B4=E5=88=A4=E6=96=AD=E5=92=8C=E5=AF=B9=E4=BA=8E=E5=BC=82?= =?UTF-8?q?=E5=B8=B8=E7=9A=84=E9=83=A8=E5=88=86=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/index.ts | 17 +- src/router/routes.ts | 12 +- src/views/home/index.vue | 319 +++++++++++++++++++----------------- src/views/leaderShip.vue | 2 +- src/views/mainPage.vue | 12 +- src/views/waiTeacher.vue | 7 +- src/views/waiTeacherTwo.vue | 7 +- 7 files changed, 211 insertions(+), 165 deletions(-) diff --git a/src/api/index.ts b/src/api/index.ts index 5d0f71d..fc0b879 100644 --- a/src/api/index.ts +++ b/src/api/index.ts @@ -85,11 +85,18 @@ export async function getMajor(code) { return response; } //检查用户身份 -export async function checkUser(code) { - const response = await http.post('/h5/cees/ceesUser/checkUser', { - userId: code, - }); - return response; +export async function checkUser(code, openid, unionid) { + try { + const response = await http.post('/h5/cees/ceesUser/checkUser', { + userId: code, + openId: openid, + unionId: unionid, + }); + return response; + } catch (err) { + // 抛出错误,让外层 catch 拿到详细信息 + throw err; + } } //检查用户身份 export async function checkUserByEmployeeCode(employeeCode,code) { diff --git a/src/router/routes.ts b/src/router/routes.ts index 4b36d9a..f215dc4 100644 --- a/src/router/routes.ts +++ b/src/router/routes.ts @@ -2,7 +2,12 @@ export const routes = [ { path: '/', redirect: '/home', - component: () => import('@/layout/basic/index.vue'), + //component: () => import('@/layout/basic/index.vue'), + meta: { + title: '哈尔滨师范大学评卷报名系统', + keepAlive: true, + showHeader: false, + }, children: [ { path: 'home', @@ -95,6 +100,11 @@ export const routes = [ // 找不到路由重定向到404页面 path: '/:pathMatch(.*)', redirect: '/home', + meta: { + title: '哈尔滨师范大学评卷报名系统', + keepAlive: true, + showHeader: false, + }, }, ]; diff --git a/src/views/home/index.vue b/src/views/home/index.vue index 2b83ce8..ed96791 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -30,10 +30,11 @@