Jelajahi Sumber

1、付款码上显示驾意险
2、查看详情显示驾意险
3、报价历史添加紫金,已缴费待审核状态撤单功能

lihongxiao 2 tahun lalu
induk
melakukan
2ef93272d3
3 mengubah file dengan 75 tambahan dan 16 penghapusan
  1. 2 2
      config/dev.env.js
  2. 47 8
      src/views/Letter/Letter.vue
  3. 26 6
      src/views/Letter/Orderlist.vue

+ 2 - 2
config/dev.env.js

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

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

@@ -1097,6 +1097,8 @@
                 @click="bjdpreview(scope.row.id)">报价单</el-button>
               <el-button size="small" v-show="scope.row.orderstatus == '2'" type="text" style="color:rgb(240, 12, 10)"
                 @click="Payment(scope.row.id)">付款码</el-button>
+                <el-button size="mini" type="text" v-if="scope.row.orderstatus == '2' && ['紫金财险'].includes(scope.row.inscompany)"
+                @click="cancelorder(scope.row)" style="color:#f56c6c">撤单</el-button>
             </template>
           </el-table-column>
         </el-table>
@@ -1274,18 +1276,27 @@
           </div>
         </div>
       </div>
-      <div class="Enclosure" v-if="queryOrders.accidentInfo">
+      <div class="Enclosure" v-if="queryOrders.accidentInfo&&queryOrders.accidentInfo.length>0">
         <div class="home flex j-s a-c back">
           <div class="flex j-s a-c color">
             <img src="../../../src/icon/company.png" alt class="icon-img" />
             <span style="margin-left:10px;">驾意险</span>
           </div>
         </div>
-        <el-descriptions size="small">
-          <el-descriptions-item label="产品">{{ queryOrders.accidentInfo.rideRiskName }}</el-descriptions-item>
-          <el-descriptions-item label="份数">{{ queryOrders.accidentInfo.quantity }}</el-descriptions-item>
-          <el-descriptions-item label="价格">{{ queryOrders.accidentInfo.unitPremium }}/份</el-descriptions-item>
-        </el-descriptions>
+        <div style="font-size:12px"  >
+          <div class="jyxStyle" style=" font-weight: bold;color: #333;">
+            <span style="width:50%;margin-left:50px">产品</span>
+            <span style="width:20%">份数</span>
+            <span style="width:20%">价格</span>
+          </div>
+          <div  v-for="(kindinfoitem, kindinfoindex) in queryOrders.accidentInfo" :key="kindinfoindex">
+            <div style="margin-top:20px" class="jyxStyle">
+              <span style="width:50%;margin-left:50px">{{ kindinfoitem.projectName }}</span>
+              <span style="width:20%">{{ kindinfoitem.quantity ?kindinfoitem.quantity:'1' }}</span>
+              <span style="width:20%">{{ kindinfoitem.actualPremium}}/份</span>
+            </div>
+          </div>
+        </div>
       </div>
       <div class="Enclosure" v-if="queryOrders">
         <div class="home flex j-s a-c back">
@@ -1580,6 +1591,10 @@
             <span>交强:</span>
             <span>{{ jqpremium }}</span>
           </div>
+          <div v-if="jypremium">
+            <span>驾意:</span>
+            <span>{{ jypremium }}</span>
+          </div>
           <div v-show="sypremium">
             <span>商业:</span>
             <span>{{ sypremium }}</span>
@@ -3113,6 +3128,7 @@ export default {
       sumpremium: "", //保费合计
       jqpremium: "", //交强
       sypremium: "", //商业
+      jypremium:'',//驾意险
       taxamount: "", //车船税
       jqstartdate: "", //交强时间
       systartdate: "", //商业时间
@@ -3406,6 +3422,7 @@ export default {
       };
       this.$api.letter.queryQuoteHistory(params).then(res => {
         res.data.forEach(item => {
+          item.accidentInfo.constructor=== Object?[res.data.accidentInfo]:res.data.accidentInfo
           item.username = this.paramsEdit.username+'('+this.paramsEdit.userid+')'
         })
         this.HistoryList = res.data;
@@ -3770,6 +3787,7 @@ export default {
       };
       this.$api.letter.queryQuoteHistory(params).then(res => {
         res.data.forEach(item => {
+          item.accidentInfo.constructor=== Object?[res.data.accidentInfo]:res.data.accidentInfo
           item.username = this.paramsEdit.username+'('+this.paramsEdit.userid+')'
         })
         this.HistoryList = res.data;
@@ -4280,6 +4298,7 @@ export default {
       };
       this.$api.letter.queryQuoteHistory(params).then(res => {
         res.data.forEach(item => {
+          item.accidentInfo.constructor=== Object?[res.data.accidentInfo]:res.data.accidentInfo
           item.username = this.paramsEdit.username+'('+this.paramsEdit.userid+')'
         })
         this.HistoryList = res.data;
@@ -5134,6 +5153,17 @@ export default {
     imageUpload() {
       this.imageUploaddialogVisible = true;
     },
+    cancelorder(item) {
+      this.$api.letter.zijincancelorder({ companyId: item.id }).then(res => {
+        if(res.code==200){
+          this.$message({
+          message: res.msg,
+          type: 'success'
+        });
+        this.QuotationHistory()
+        }
+      })
+    },
     imageEcho(quotenos) {
       //影像查询
       this.$api.letter.findByQuoteNo(quotenos)
@@ -5403,6 +5433,7 @@ export default {
                           loading.close();
                           _this.$message({
                             showClose: true,
+                            dangerouslyUseHTMLString: true,
                             message: this.queryOrders.inscompany + "提核--:" + res.msg,
                             type: "error",
                             duration: 0
@@ -5958,6 +5989,7 @@ export default {
       that.carfrontImg =  image.src 
       image.onload = function(){
         let aaa= that.base64ToFile(that.compress(image, 500, 400, 0.7),name)
+
       that.carfrontImg = image.src;
       const params = new FormData(); // 声明formData数据类型
       params.append("multipartFile", aaa);
@@ -6485,13 +6517,14 @@ export default {
       };
       this.$api.letter.getByCompanyId(params).then(res => {
         if (res.code == "200") {
-          const { inscompany, sumpremium, carinfo, insuredname, jqpremium, sypremium, taxamount, jqstartdate, systartdate, applyinfo } = res.data;
+          const { inscompany, sumpremium, carinfo, insuredname, jqpremium, sypremium, taxamount, jqstartdate, systartdate, applyinfo,jypremium } = res.data;
           this.inscompany = inscompany; // 保险公司
           this.sumpremium = sumpremium; // 总价
           this.licenseNo = carinfo.licenseNo; // 车牌号
           this.applyName = insuredname; // 车主
           this.jqpremium = jqpremium; // 交强
           this.sypremium = sypremium; // 商业
+          this.jypremium = jypremium; // 商业
           this.taxamount = taxamount; // 车船税
           this.jqstartdate = jqstartdate; // 交强起保日期
           this.systartdate = systartdate; // 商业起保日期
@@ -7394,6 +7427,10 @@ export default {
       margin-top: 0
   }
 }
+.jyxStyle>span{
+  display: inline-block;
+  text-align: center;
+}
 /* 清除图片上传动画bug */
 /deep/ {
   .el-upload-list__item {
@@ -7513,4 +7550,6 @@ export default {
     }
   }
 
-}</style>
+}
+
+</style>

+ 26 - 6
src/views/Letter/Orderlist.vue

@@ -184,6 +184,10 @@
             <span>交强:</span>
             <span>{{ jqpremium }}</span>
           </div>
+          <div v-if="jypremium">
+            <span>驾意:</span>
+            <span>{{ jypremium }}</span>
+          </div>
           <div v-if="sypremium">
             <span>商业:</span>
             <span>{{ sypremium }}</span>
@@ -382,18 +386,27 @@
           </div>
         </div>
       </div>
-      <div class="Enclosure" v-if="orderInfo.accidentInfo">
+      <div class="Enclosure" v-if="orderInfo.accidentInfo&&orderInfo.accidentInfo.length>0">
         <div class="home flex j-s a-c back">
           <div class="flex j-s a-c color">
             <img src="../../../src/icon/company.png" alt class="icon-img" />
             <span style="margin-left:10px;">驾意险</span>
           </div>
         </div>
-        <el-descriptions size="small">
-          <el-descriptions-item label="产品">{{ orderInfo.accidentInfo.rideRiskName }}</el-descriptions-item>
-          <el-descriptions-item label="份数">{{ orderInfo.accidentInfo.quantity }}</el-descriptions-item>
-          <el-descriptions-item label="价格">{{ orderInfo.accidentInfo.unitPremium }}/份</el-descriptions-item>
-        </el-descriptions>
+        <div style="font-size:12px"  >
+          <div class="jyxStyle" style=" font-weight: bold;color: #333;">
+            <span style="width:50%;margin-left:50px">产品</span>
+            <span style="width:20%">份数</span>
+            <span style="width:20%">价格</span>
+          </div>
+          <div  v-for="(kindinfoitem, kindinfoindex) in orderInfo.accidentInfo" :key="kindinfoindex">
+            <div style="margin-top:20px" class="jyxStyle">
+              <span style="width:50%;margin-left:50px">{{ kindinfoitem.projectName }}</span>
+              <span style="width:20%">{{ kindinfoitem.quantity ?kindinfoitem.quantity:'1' }}</span>
+              <span style="width:20%">{{ kindinfoitem.actualPremium}}/份</span>
+            </div>
+          </div>
+        </div>
       </div>
       <div class="Enclosure" v-if="orderInfo">
         <div class="home flex j-s a-c back">
@@ -1574,6 +1587,7 @@ export default {
       jqpremium: "",//交强
       sypremium: "",//商业
       taxamount: "",//车船税
+      jypremium:"",//驾意险
       jqstartdate: "",//交强时间
       systartdate: "",//商业时间
       mobile: "",//投保人手机号
@@ -1952,6 +1966,7 @@ export default {
           this.jqpremium = res.data.jqpremium;//交强
           this.sypremium = res.data.sypremium;//商业
           this.taxamount = res.data.taxamount;//车船税
+          this.jypremium = res.data.jypremium;//驾意险
           this.jqstartdate = res.data.jqstartdate;//交强起保日期
           this.systartdate = res.data.systartdate;//商业起保日期
           this.mobile = res.data.applyinfo.mobile;//投保人手机号
@@ -2020,6 +2035,7 @@ export default {
         if (res.code == 200) {
           this.licenseNo = res.data.licenseno;//车牌号
           this.inscompany = res.data.inscompany;//保险公司
+          res.data.accidentInfo.constructor === Object?[res.data.accidentInfo]:res.data.accidentInfo
           Object.assign(this.orderInfo, res.data);
           for (let i = 0; i < this.orderInfo.riskinfo.length; i++) {
             if (this.orderInfo.riskinfo[i].riskCode == "0510") {
@@ -3073,4 +3089,8 @@ export default {
 .Risk_title>div :nth-child(3) {
   border-top-right-radius: 10px;
 }
+.jyxStyle>span{
+  display: inline-block;
+  text-align: center;
+}
 </style>