lilei 2 rokov pred
rodič
commit
a2407880ad
2 zmenil súbory, kde vykonal 3 pridanie a 2 odobranie
  1. 2 2
      pages/index/index.vue
  2. 1 0
      pages/personData/personData.vue

+ 2 - 2
pages/index/index.vue

@@ -150,8 +150,6 @@
 			this.vinList = []
 			// 检测是否登录
 			this.$store.dispatch('checkLogin',()=>{
-				// 用户头像
-				this.avatarUrl = this.$store.state.vuex_userPhoto || uni.getStorageSync('userPhoto');
 				// 获取数据字典
 				this.getListLookUp();
 				// 获取支付,收款方式
@@ -176,6 +174,8 @@
 		},
 		onShareAppMessage() {},
 		onShow() {
+			// 用户头像
+			this.avatarUrl = uni.getStorageSync('userPhoto');
 			if(this.hasLogin){
 				// 查询门店认证信息
 				if(this.userInfo.sysUserFlag == '0'){

+ 1 - 0
pages/personData/personData.vue

@@ -98,6 +98,7 @@
 					if(ret.status == 200){
 						_this.avatarUrl = ret.data
 						_this.$store.state.vuex_userPhoto = ret.data
+						uni.setStorageSync('userPhoto', ret.data);
 						saveHeadImage({photo: ret.data}).then(res => {
 							if(res.status == 200){
 								uni.showToast({