用户中心未登录也请求接口处理

master
gongfuxiang 2024-11-09 22:48:36 +08:00
parent 65b02c2122
commit f928a668d8
2 changed files with 4 additions and 12 deletions

View File

@ -175,7 +175,6 @@
var common_static_url = app.globalData.get_static_url('common');
var static_url = app.globalData.get_static_url('user');
var client_value = app.globalData.application_client();
export default {
data() {
return {
@ -273,16 +272,10 @@
count: old_nav.length > 0 ? old_nav[3].count : 0,
},
];
var nav_logout_data = {
name: client_value == 'mp' ? this.$t('setup.setup.5493ui') : this.$t('user.user.2k0227'),
icon: client_value == 'mp' ? 'cache' : 'logout',
var nav_logout_data = (user == null) ? null : {
name: this.$t('user.user.2k0227'),
icon: 'logout',
};
// #ifdef APP || H5
// apph5退
if(user == null) {
nav_logout_data = null;
}
// #endif
this.setData({
user: user,
@ -488,9 +481,8 @@
this.setData({
user: null,
nickname: '',
// #ifdef APP || H5
avatar: app.globalData.data.default_user_head_src,
nav_logout_data: null,
// #endif
});
//

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

After

Width:  |  Height:  |  Size: 6.6 KiB