Преглед изворни кода

0506添加舱位价格提示lhj

liuhj пре 1 година
родитељ
комит
553e925466
1 измењених фајлова са 10 додато и 1 уклоњено
  1. 10 1
      src/components/OP/EntryDetails.vue

+ 10 - 1
src/components/OP/EntryDetails.vue

@@ -674,7 +674,10 @@ export default {
                 if(res.data.code==200){
                     that.options=res.data.data.groupNameData;
                     that.currencys=res.data.data.currencyInit;
-                    that.value=res.data.data.groupNameData[0].id;
+                    // console.log(that.value)
+                    if(that.value==null){
+                        that.value=res.data.data.groupNameData[0].id;
+                    }
                     that.listvalueoptions=res.data.data.wordTypeData;
                     that.tablevalueoptions=res.data.data.excelTypeData;
                     that.GetEnterExitCostInfobyDiId()
@@ -1206,6 +1209,7 @@ export default {
                     //that.GetEnterExitCostCorrelationTips();
                 }else{
                     that.fullscreenLoading=false;
+                    that.GetEnterExitCostCorrelationTips();
                     that.$message.warning(res.data.msg);
                 }
             })
@@ -1581,6 +1585,7 @@ export default {
         },
         //选择团组名称调用
         chengvalue(){
+            window.localStorage.setItem('sgvalue', this.value);
             this.fullscreenLoading=true;
             this.GetEnterExitCostInfobyDiId()
         },
@@ -1905,8 +1910,12 @@ export default {
     },
     mounted(){
         this.userId=JSON.parse(localStorage.getItem('userinif')).userInfo.userId;
+        this.value=JSON.parse(localStorage.getItem('sgvalue'))
         this.GetEnterExitCostDataSource();
         this.GetNationalTravelFeeData();
+    },
+    destroyed(){
+        window.localStorage.removeItem('sgvalue');
     }
 }
 </script>