设置->资料与账号功能开发

This commit is contained in:
x ronger 2020-08-02 19:40:28 +08:00
parent 60a7ec7e2f
commit 794dc3cdf4
2 changed files with 5 additions and 1 deletions

View File

@ -195,7 +195,7 @@
_ts.$set(_ts, 'user', res.user);
_ts.$set(_ts, 'avatarUrl', res.user.avatarUrl);
_ts.$set(_ts, 'svgShow', false);
// _ts.$store.commit('setUserInfo', res.user);
_ts.$store.commit('setUserInfo', res.user);
_ts.$message.success('更新成功 !');
}
}

View File

@ -18,6 +18,10 @@ export const mutations = {
},
setUploadHeaders(state, data){
state.uploadHeaders = data
},
setUserInfo(state, data) {
state.oauth.avatarURL = data.avatarUrl;
state.oauth.nickname = data.nickname;
}
}