shish 5 лет назад
Родитель
Сommit
06d138647e
2 измененных файлов с 2 добавлено и 6 удалено
  1. 0 4
      ghsApp/src/App.vue
  2. 2 2
      ghsApp/src/utils/auth.js

+ 0 - 4
ghsApp/src/App.vue

@@ -28,7 +28,6 @@ export default {
 			})
 		}
 		// #endif
-
 		// 删除缓存
 		if (process.env.NODE_ENV == 'production') {
 			uni.removeStorageSync('shopUser')
@@ -38,7 +37,6 @@ export default {
 		// uni.clearStorage()
 		const extConfig = wx.getExtConfigSync ? wx.getExtConfigSync() : {}
 		uni.setStorageSync('account', extConfig.account)
-
 		// #endif
 		wxLoginFn(true)
 			.then(res => {
@@ -66,7 +64,6 @@ export default {
 				getUser(true)
 				//获取门店信息
 				this.setUserShopAll()
-
 			})
 	},
 	onLoad(){
@@ -86,7 +83,6 @@ export default {
 	}
 }
 </script>
-
 <style lang="scss">
 	//没有scss变量方法的,主要引入 这样打包的时候就不会所有的组件都打包进去
 	@import './static/iconfont/iconfont.css';

+ 2 - 2
ghsApp/src/utils/auth.js

@@ -28,7 +28,7 @@ export async function getShopUser(update) {
 		userInfo = res.data
 		store.dispatch('setShopUser', userInfo)
 	}).catch(() => {
-		uni.removeStorageSync('token')
+		//uni.removeStorageSync('token')
 	})
 
 	return userInfo
@@ -47,7 +47,7 @@ export async function getUser(update) {
 		userInfo = res.data
 		store.dispatch('setUser', userInfo)
 	}).catch(() => {
-		uni.removeStorageSync('token')
+		//uni.removeStorageSync('token')
 	})
 
 	return userInfo