Sfoglia il codice sorgente

修改返回后台的体验问题

wangn 5 anni fa
parent
commit
075934af24

+ 2 - 2
hdApp/src/admin/home/result.vue

@@ -32,11 +32,11 @@ export default {
     loginSys(){
       uni.removeStorageSync('OPEN_SHOP_ID')
       uni.removeStorageSync('SHOP_ADMIN_STROAGE_SHOW')
-      this.$store.commit("setLoginInfo", {});
       this.$util.pageTo({
         url: '/admin/home/workbench',
-        type: 3
+        type: 4
       })
+      this.$store.commit("setLoginInfo", {});
     },
     openInform(){
       this.pageTo({

+ 8 - 10
hdApp/src/mixins/globalMixins.js

@@ -27,7 +27,6 @@ export default {
 	},
 	// 页面生命周期才触发
   onLoad: function (option) {
-    console.log(11111)
 		this.option = option || null
 		if (option.token) {
 			uni.setStorageSync('token', option.token)
@@ -36,7 +35,13 @@ export default {
 			uni.setStorageSync('account', option.account)
 		}
     uni.setStorageSync('currentQuery', JSON.stringify(option))
-    console.log(uni.getStorageSync('SHOP_ADMIN_STROAGE_SHOW'),'this.shopAdminId', this.getLoginInfo, this.getLoginInfo.openShop)
+	},
+	onShow(){
+		if (isLogin()&&!this.$util.isEmpty(this.getLoginInfo)) {
+			if (this.init) {
+				this.init()
+      }
+    }
     if (this.$util.isEmpty(this.getLoginInfo)) {
       wxLoginFn(true).then(res => {
         //客户可以访问的地址
@@ -63,6 +68,7 @@ export default {
             uni.removeStorageSync('SHOP_ADMIN_STROAGE_SHOW')
             uni.setStorageSync('OPEN_SHOP_ID', res.data.admin.openShop)
           } else {
+            this.AUTHORITY_SHOW = false;
             uni.showTabBar()
           }
         }
@@ -74,14 +80,6 @@ export default {
         }
       })
     }
-
-	},
-	onShow(){
-		if (isLogin()&&!this.$util.isEmpty(this.getLoginInfo)) {
-			if (this.init) {
-				this.init()
-      }
-    }
 	},
 	methods: {
     ...mapActions(['setUserShopAll']),

+ 1 - 1
hdApp/src/pagesClient/official/result.vue

@@ -24,7 +24,7 @@ export default {
             console.log(e)
         },
         close() {
-          uni.reLaunch({url: '/admin/home/workbench'})
+          this.pageTo({url: '/admin/home/workbench', type: 4})
           this.$store.commit("setLoginInfo", {});
         }
     }