yuanyuan 3 lat temu
rodzic
commit
8da697cb91
2 zmienionych plików z 2 dodań i 2 usunięć
  1. 1 1
      src/router/index.js
  2. 1 1
      src/views/product/Detail.vue

+ 1 - 1
src/router/index.js

@@ -915,7 +915,7 @@ router.beforeEach((to, from, next) => {
         sessionStorage.setItem('invitor', to.query.invitor);
     }
     if (to.meta.pageType != Page.Every && to.path !== '/collectionDetail' && to.path !== '/castingDetail') {
-        if (!store.state.userInfo && to.meta.pageType !== Page.Login) {
+        if (!store.state.userInfo && to.meta.pageType != Page.Login) {
             store
                 .dispatch('getUserInfo')
                 .then(() => {

+ 1 - 1
src/views/product/Detail.vue

@@ -1136,7 +1136,7 @@ export default {
             if (!fromRoute || !fromRoute.name) {
                 this.$router.replace('/home');
             } else {
-                this.$router.back();
+                this.$router.go(-1);
             }
         }
     },