Selaa lähdekoodia

Merge branch 'feature_20250527_门店拜访任务列表访问速度优化' into uat(dev)

zhujindu 6 kuukautta sitten
vanhempi
commit
c31888c504
1 muutettua tiedostoa jossa 17 lisäystä ja 16 poistoa
  1. 17 16
      src/views/deviceWithin/storeVisit.vue

+ 17 - 16
src/views/deviceWithin/storeVisit.vue

@@ -213,22 +213,23 @@ export default {
       restartProcessButtion: false,
       wuliaoTable: false,
       wuliaoList: [],
+      urlParameter: {},
     };
   },
   created() {
-    this.urlParameter = this.$route.query;
-    this.storeId = this.$route.query.storeId + '';
-    this.visitId = this.$route.query.visitId;
-    this.rdId = this.$route.query.rdId + '';
-    this.addressLine = this.$route.query.addressLine + '';
-    this.storeCategory = this.$route.query.storeCategory + '';
-    this.storeName = this.$route.query.storeName + '';
-    this.contactName = this.$route.query.contactName + '';
-    this.visitModel = this.$route.query.visitModel + '';
-    this.lat = this.$route.query.lat + '';
-    this.lon = this.$route.query.lon + '';
-    sessionStorage.setItem('visitModel', '1');
-    this.uType = localStorage.getItem('uType');
+    // this.urlParameter = this.$route.query;
+    // this.storeId = this.$route.query.storeId + '';
+    // this.visitId = this.$route.query.visitId;
+    // this.rdId = this.$route.query.rdId + '';
+    // this.addressLine = this.$route.query.addressLine + '';
+    // this.storeCategory = this.$route.query.storeCategory + '';
+    // this.storeName = this.$route.query.storeName + '';
+    // this.contactName = this.$route.query.contactName + '';
+    // this.visitModel = this.$route.query.visitModel + '';
+    // this.lat = this.$route.query.lat + '';
+    // this.lon = this.$route.query.lon + '';
+    // sessionStorage.setItem('visitModel', '1');
+    // this.uType = localStorage.getItem('uType');
   },
   beforeRouteLeave(to, from, next) {
     if (to.path == '/deviceWithin/index' && from.path == '/storeVisitpage') {
@@ -239,6 +240,9 @@ export default {
     next();
   },
   activated() {
+    // 是否请求任务列表接口
+    let getRequestFlage = localStorage.getItem('getRequestFlage');
+    if (getRequestFlage != 'true') return;
     this.urlParameter = this.$route.query;
     this.storeId = this.$route.query.storeId + '';
     this.visitId = this.$route.query.visitId;
@@ -252,9 +256,6 @@ export default {
     this.lon = this.$route.query.lon + '';
     // this.list = [];
     this.uType = localStorage.getItem('uType');
-    // 是否请求任务列表接口
-    let getRequestFlage = localStorage.getItem('getRequestFlage');
-    if (getRequestFlage != 'true') return;
     this.list = [];
     if (this.$route.query.type != 'edit') {
       this.timeShow = true;