Przeglądaj źródła

航站视图默认航站问题

zhongxiaoyu 1 rok temu
rodzic
commit
fd1db3790e

+ 2 - 2
src/views/newArrival/index.vue

@@ -95,7 +95,7 @@ export default {
   },
   mounted () {
     this.timer = setInterval(() => {
-      this.getAirPortData(0)
+      this.getAirPortData()
     }, LOOP_INTERVAL.arrivalTable)
   },
   destroyed () {
@@ -141,7 +141,7 @@ export default {
         res = this.TauthId ? await this.getQueryListAuth(this.TqueryId || SERVICE_ID.getAirpotId, {}, 1, 999, this.TauthId) : await this.getQueryList(SERVICE_ID.getAirpotId)
         if (Number(res.code) === 0) {
           this.AirportList = res.returnData;
-          if (type) {
+          if (type && !this.formData.currentAirport) {
             const flag = res.returnData.filter(item => item.IATACode == 'CAN');
             this.formData.currentAirport = this.TauthId && flag.length ? 'CAN' : res.returnData[0].IATACode;
           }

+ 2 - 2
src/views/newDeparture/index.vue

@@ -100,7 +100,7 @@ export default {
   },
   mounted () {
     this.timer = setInterval(() => {
-      this.getAirPortData(0)
+      this.getAirPortData()
     }, LOOP_INTERVAL.departureTable)
   },
   destroyed () {
@@ -146,7 +146,7 @@ export default {
         res = this.TauthId ? await this.getQueryListAuth(this.TqueryId || SERVICE_ID.getAirpotId, {}, 1, 999, this.TauthId) : await this.getQueryList(SERVICE_ID.getAirpotId)
         if (Number(res.code) === 0) {
           this.AirportList = res.returnData;
-          if (type) {
+          if (type && !this.formData.currentAirport) {
             const flag = res.returnData.filter(item => item.IATACode == 'CAN');
             this.formData.currentAirport = this.TauthId && flag.length ? 'CAN' : res.returnData[0].IATACode;
           }

+ 2 - 2
src/views/newTransfer/index.vue

@@ -98,7 +98,7 @@ export default {
   },
   mounted () {
     this.timer = setInterval(() => {
-      this.getAirPortData(0)
+      this.getAirPortData()
     }, LOOP_INTERVAL.transferArrivalTable)
   },
   destroyed () {
@@ -149,7 +149,7 @@ export default {
         res = this.TauthId ? await this.getQueryListAuth(this.TqueryId || SERVICE_ID.getAirpotId, {}, 1, 999, this.TauthId) : await this.getQueryList(SERVICE_ID.getAirpotId)
         if (Number(res.code) === 0) {
           this.AirportList = res.returnData;
-          if (type) {
+          if (type && !this.formData.currentAirport) {
             const flag = res.returnData.filter(item => item.IATACode == 'CAN');
             this.formData.currentAirport = this.TauthId && flag.length ? 'CAN' : res.returnData[0].IATACode;
           }