From ce3c9d345a27d3a86e6c096d927f3ee619b6e68f Mon Sep 17 00:00:00 2001 From: zhangxiaoxu123 <819527061@qq.com> Date: 星期三, 26 十月 2022 13:46:50 +0800 Subject: [PATCH] 细节 --- src/store/modules/user.js | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 23d175b..ab7a6bf 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -30,6 +30,9 @@ const user = { state: { + id: getStore({ + name: 'id' + }), userInfo: getStore({ name: 'userInfo' }) || {}, @@ -198,6 +201,14 @@ } }, mutations: { + SET_ID: (state, id) => { + state.id = id + setStore({ + name:'id', + content: state.id, + type: 'session' + }) + }, SET_ACCESS_TOKEN: (state, access_token) => { state.access_token = access_token setStore({ -- Gitblit v1.9.1