Przeglądaj źródła

设置默认值

shish 1 rok temu
rodzic
commit
8ce6451f50
1 zmienionych plików z 4 dodań i 0 usunięć
  1. 4 0
      mallApp/src/mixins/globalMixins.js

+ 4 - 0
mallApp/src/mixins/globalMixins.js

@@ -47,9 +47,13 @@ export default {
 
 
 		if (option.account) {
 		if (option.account) {
 			uni.setStorageSync('account', option.account)
 			uni.setStorageSync('account', option.account)
+		}else{
+			uni.setStorageSync('account', 0)
 		}
 		}
 		if (option.hdId) {
 		if (option.hdId) {
 			uni.setStorageSync('hdId', option.hdId)
 			uni.setStorageSync('hdId', option.hdId)
+		}else{
+			uni.setStorageSync('hdId', 0)
 		}
 		}
 
 
 		uni.setStorageSync('currentQuery', JSON.stringify(option))
 		uni.setStorageSync('currentQuery', JSON.stringify(option))