Просмотр исходного кода

Merge branch 'dev' of http://www.baoxianzhanggui.com:8090/sxzgd/vue-insagent-pc into dev

haizhouwang 2 лет назад
Родитель
Сommit
2a6dd4c35a
3 измененных файлов с 25 добавлено и 12 удалено
  1. 2 2
      config/dev.env.js
  2. 5 8
      src/views/Letter/Letter.vue
  3. 18 2
      src/views/Letter/Orderlist.vue

+ 2 - 2
config/dev.env.js

@@ -5,8 +5,8 @@ const prodEnv = require('./prod.env')
 module.exports = merge(prodEnv, {
   NODE_ENV: '"development"',
   ENV_CONFIG:'"dev"',
-  // BASE_URL: '"https://test.baoxianzhanggui.com/web-api"',//测试服务器
-  BASE_URL:'"https://sxzgkj.baoxianzhanggui.com/web-api"'//正式服务器
+  BASE_URL: '"https://test.baoxianzhanggui.com/web-api"',//测试服务器
+  // BASE_URL:'"https://sxzgkj.baoxianzhanggui.com/web-api"'//正式服务器
   // BASE_URL: '"http://192.168.0.115:8080/"' //凯森
   // BASE_URL: '"http:///192.168.0.253:8082/"',//田智
   // BASE_URL: '"http:///192.168.0.253:8082/"',//田智

+ 5 - 8
src/views/Letter/Letter.vue

@@ -1520,7 +1520,6 @@
                   :data="TPInsuranceData"
                   border
                   v-if="insuranceTP"
-                  @row-click="TPDrivingChange"
                   ref="RsTable"
                   highlight-current-row
                   :header-cell-style="{ background: '#F2F7FC', fontWeight: '700', color: '#ee7000' }"
@@ -5345,7 +5344,6 @@ else{
     },
     huanongInsuranceChange(index){
       this.HNInsuranceData=(this.huanongInsuranceData).find(val=>val.planCode==index).planSubInfo[0].riskInfo
-
       this.huanongaccidentalDrivingVo= Object.assign(
         this.accidentFormHN,
         this.huanongInsuranceData.find(val=>val.planCode==index)
@@ -5353,8 +5351,8 @@ else{
     },
     taipingInsuranceChange(index){
       this.TPInsuranceData=[(this.taipingInsuranceData).find(val=>val.rationType==index)]
-      if(this.TPInsuranceData.length){
-        this.TPDrivingChange(this.TPInsuranceData[0])
+      if(this.TPInsuranceData && this.TPInsuranceData.length){
+          this.taipingaccidentalDrivingVo=this.TPInsuranceData[0];
       }
     },
     zijinInsuranceChange(index){
@@ -5690,10 +5688,7 @@ else{
       })
     },
 
-    //太平驾意险选择
-      TPDrivingChange(row){
-      this.taipingaccidentalDrivingVo=row;
-    },
+   
     //恒邦驾意险选择
     HBDrivingChange(row){
       this.hengbangaccidentalDrivingVo=row;
@@ -5878,6 +5873,7 @@ else{
 
     },
     clearAccidentForm() {
+      this.accidentForm={}
       this.accidentForm.fen=1
       this.accidentForm.premium=0
     },
@@ -6692,6 +6688,7 @@ else{
         let data = this.accidentDataList.find(
           val => val.code == this.accidentForm.accidentType
         );
+
         accidentalDrivingVo = {
           rideRiskCode: data.code ? data.code : "",
           rideRiskName: data.name ? data.name : "",

+ 18 - 2
src/views/Letter/Orderlist.vue

@@ -685,7 +685,7 @@
             orderInfo.carinfo.purchasePrice
           }}</el-descriptions-item>
           <el-descriptions-item label="使用性质">
-            {{ orderInfo.carinfo.carnature == "8A" ? "家庭自用" : "" }}
+            {{orderInfo.carinfo.carnature  }}
           </el-descriptions-item>
           <el-descriptions-item label="注册日期">{{
             orderInfo.carinfo.registerDate
@@ -1537,9 +1537,11 @@ export default {
       querystatusLoaing: false,
       quotationhistorydialogVisible: false, //报价历史显示状态
       HistoryList: [], //报价历史数据
+      natureOfVehicleUseoptions:[],
     };
   },
   created() {
+    this.getDicType("natureOfVehicleUse");//车辆使用性质
     this.$api.letter.gainTopList().then((res) => {
       this.companyList = res.data;
     });
@@ -1572,6 +1574,7 @@ export default {
         return item.dictValue === ele;
       }).dictTag;
     },
+  
   },
   unmounted() {
     window.removeEventListener("resize", this.getDimensions);
@@ -1627,6 +1630,14 @@ export default {
         this.HistoryList = res.data;
       });
     },
+    getDicType(type) {
+      this.$api.insCompany.dicType(type).then(res => {
+        if (res.code == 200) {
+            this[type + 'options'] = res.data.ddList;
+        }
+      })
+
+    },
     capType(val) {
       if (val == "0") {
         return "success";
@@ -2096,6 +2107,11 @@ export default {
         }
       });
     },
+    natureOfVehicleUseCap(ele) {
+      return this.natureOfVehicleUseoptions.find((item) => {
+        return item.dictValue === ele;
+      }).dictTag;
+    },
     //应用详情
     OrderDetails(dy, item) {
       this.carImageList = [];
@@ -2108,7 +2124,6 @@ export default {
       this.pic2Control = false;
       this.pic3Control = false;
       this.pic4Control = false;
-
       this.pic5Control = false;
 
       for (let i = 0; i < this.global.insureList.length; i++) {
@@ -2122,6 +2137,7 @@ export default {
         if (res.code == 200) {
           this.licenseNo = res.data.licenseno; //车牌号
           this.inscompany = res.data.inscompany; //保险公司
+          res.data.carinfo.carnature= this.natureOfVehicleUseCap(res.data.carinfo.carnature)
           if (res.data.accidentInfo) {
             res.data.accidentInfo.constructor === Object
               ? [res.data.accidentInfo]