From 470f38fcd1a3de5b4587164cf46b4e37889d4952 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=86=8A=E6=88=90=E5=BC=BA?= Date: Wed, 18 Nov 2020 15:17:12 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/store/modules/user.js | 2 +- src/utils/permission.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 40e8560..3c8682d 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -26,7 +26,7 @@ const user = { let res = await apiUserInfo() if (res.code === 200) { commit('SET_USER_INFO', res.user) - commit('SET_USER_INFO', res.data) + commit('SET_USER_AUTH', res.data) return 1 } else { this.$message.error(res.msg0) diff --git a/src/utils/permission.js b/src/utils/permission.js index 5676df4..1079dd6 100644 --- a/src/utils/permission.js +++ b/src/utils/permission.js @@ -10,6 +10,7 @@ async function handleDingtalkLogin (val) { const res = await apiDingtalkLogin(val) console.log('钉钉免登录res: ', res) if (res && res.code === 200) { + console.log('res.token: ', res.token) this.$cookies.set('token', res.token) return 1 // window.open(window.location.protocol + '//' + window.location.host + '/digitization/kpi/workbench/home?code=' + this.dingCode.code)