lex 2 years ago
parent
commit
c3de38e85e

+ 1 - 1
src/student/home-layout-orchestra/auth-login.tsx

@@ -31,7 +31,7 @@ export default defineComponent({
       promisefiyPostMessage({ api: 'getUserAccount' }).then(
         async (res: any) => {
           const content = res.content
-          state.orchestraInfo.token = content.token
+          state.orchestraInfo.token = content.token.split(' ')[1]
           state.orchestraInfo.phone = content.phone
           state.orchestraInfo.nickname = content.nickname
           state.orchestraInfo.avatar = content.avatar

+ 1 - 1
src/student/home/index.tsx

@@ -81,7 +81,7 @@ export default defineComponent({
           if (content.unionId) {
             window.location.reload()
           } else {
-            state.orchestraInfo.token = content.token
+            state.orchestraInfo.token = content.token.split(' ')[1]
             state.orchestraInfo.phone = content.phone
             state.orchestraInfo.nickname = content.nickname
             state.orchestraInfo.avatar = content.avatar

+ 1 - 1
src/student/main.ts

@@ -38,7 +38,7 @@ if (browser().isOrchestraStudent) {
   // 获取管乐团token
   promisefiyPostMessage({ api: 'getUserAccount' }).then((res: any) => {
     const content = res.content
-    state.orchestraInfo.token = content.token
+    state.orchestraInfo.token = content.token.split(' ')[1]
     state.orchestraInfo.phone = content.phone
     state.orchestraInfo.nickname = content.nickname
     state.orchestraInfo.avatar = content.avatar