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

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

haizhouwang 2 лет назад
Родитель
Сommit
b266268ce0

+ 9 - 0
src/http/moudules/letter.js

@@ -568,6 +568,15 @@ export const huataiqueryClauseData = (data) => {
         data
     })
   }
+//国任特约查询
+export const guorenqueryClauseData = (data) => {
+    return axios({
+        url: "/api/guoRen/queryClauseData",
+        method: "post",
+        data
+    })
+  }
+
 //紫金撤单
 export const zijincancelorder = (data) => {
   return axios({

+ 1 - 0
src/views/AgreementManage/CarInsurance/AgreementEntry.vue

@@ -81,6 +81,7 @@
     </el-main>
     <!-- 新增协议的对话框 -->
     <el-dialog :title="dialogTitle" v-dialogDrag :visible.sync="agreementdialogVisible" width="60%"
+    :close-on-click-modal="false" :close-on-press-escape="false"
       style="margin-top: -8vh;" @close="closeDialog()">
       <el-row style="margin-bottom: 10px;" v-if="agreement.agreestatuButtonSizes == '2'">
         <el-col :span="4" style="text-align: right"><label style="margin-right: 10px;">退回修改原因:</label></el-col>

+ 37 - 7
src/views/Letter/Letter.vue

@@ -1001,6 +1001,7 @@
               </div>
             </template>
             <template v-if="reslistitem.namesimple == '国任财险' && reslistitem.checked && reslistitem.agreementId">
+              <el-button class="Driving-risk" type="text" @click="contributingGuoRen(reslistitem.agreementId)">选择特约</el-button>
               <div class="flex f-c Driving-risk">
                 <h3>意外险信息</h3>
                 <el-form :inline="true" :model="guoRenaccidentForm" class="demo-form-inline" size="small">
@@ -2112,9 +2113,9 @@
         <el-button size="small" type="primary" @click="renewalCodeconfirm">确 定</el-button>
       </span>
     </el-dialog>
-    <el-dialog title="提交核保" :visible.sync="hbsubmitdialogVisible" width="1200px">
+    <el-dialog :title="contributingState?'选择特约':'提交核保'" :visible.sync="hbsubmitdialogVisible" width="1200px">
       <div style="margin-bottom: 20px;font-weight: bold;">特约选择</div>
-      <el-table size="small" :data="zijinengageListData" border v-loading="accidentLoading" @select="zijinengageChange"
+      <el-table size="small" :data="zijinengageListData" border v-loading="contributingLoading" @select="zijinengageChange"
         ref="expandTable" highlight-current-row @cell-dblclick="zijincellDblclick"  :cell-class-name="tableCellClassName"
         :header-cell-style="{ background: '#F2F7FC', fontWeight: '700', color: '#ee7000' }">
         <el-table-column type="selection" width="55"></el-table-column>
@@ -2130,7 +2131,9 @@
       </el-table>
       <span slot="footer" class="dialog-footer">
         <el-button size="small" @click="hbsubmitdialogVisible = false">取 消</el-button>
-        <el-button size="small" type="warning" @click="hbsubmit">提交核保</el-button>
+        <el-button v-if="contributingState" size="small" type="warning" @click="hbsubmitdialogVisible=false">确定</el-button>
+        <el-button v-else size="small" type="warning" @click="hbsubmit">提交核保</el-button>
+
       </span>
     </el-dialog>
     <el-image-viewer v-if="showViewer" :on-close="closeViewer" :z-index="9999" :url-list="[ProViewImg]" />
@@ -2242,6 +2245,7 @@ export default {
       accidenttableData: [],
       accidentLoading: false,
       guoRenaccidentLoading: false,
+      contributingLoading:false,
       guoRenaccidentPremium:'',
       guoRenaccidentForm: {
         quantity: "1",
@@ -2249,6 +2253,7 @@ export default {
       }, //国任意外险内容
       accidentPremium: "",
       accidentPremiumGr:'',
+      contributingState:false, //是否为国任特约
       pickerOptions: {
         disabledDate(time) {
           //若选择的日期小于当前日期(包含今天)
@@ -3438,7 +3443,6 @@ export default {
       });
     }
 
-
     //--订单编辑回显--
     this.paramsEdit = this.$route.query.data; //接收参数
     if (this.paramsEdit) {
@@ -3448,7 +3452,6 @@ export default {
       this.bbtbcarShow = false;
       this.bbczcarShow = false;
       const { carinfo, ownerinfo, applyinfo, insureinfo, quoteno, orderno } = _this.paramsEdit;
-
       _this.carInfo = carinfo;
       if( _this.carInfo.carnature=="8A"){
         _this.carInfo.carnature='02'
@@ -4106,6 +4109,22 @@ export default {
     ZADrivingRadio(row){
       this.ZADrivingChange(row)
     },
+    // 国任特约选择
+    contributingGuoRen(id){
+      this.zijinengageListData = [];
+      this.contributingLoading=true
+      this.contributingState=true
+      this.hbsubmitdialogVisible=true
+        this.$api.letter.guorenqueryClauseData
+        ({ agreementId: id }).then(res => {
+          this.contributingLoading=false
+          res.data.forEach(val=>{
+            val.clauseName=val.clauses
+            val.clauseContent=val.clausesContext
+          })
+            this.zijinengageListData = res.data;
+          });
+    },
     //紫金特约选择
     zijinengageChange(select, row) {
       this.zijinengageList = [];
@@ -4368,7 +4387,6 @@ export default {
         this.$message({ message: "发证日期早于初登日期", type: "error" });
         return;
       }
-
       this.$refs["carInfo"].validate(valid => {
         if (valid) {
           var _this = this;
@@ -5095,6 +5113,16 @@ export default {
     },
     //国任报价
     guoRen(num, id) {
+      let guoRenSpecialAgreementVo=[]
+      this.zijinengageList.forEach(val=>{
+        guoRenSpecialAgreementVo.push({
+          clauses:val.clauseName,
+          clausesContext:val.clauses,
+          clauseCode:val.clauseCode,
+          riskCode:val.riskCode,
+          riskName:val.riskName,
+        })
+      })
       let accidentalDrivingVo = {};
       if ( this.guoRenaccidentForm.goodsCode) {
         accidentalDrivingVo = {
@@ -5110,9 +5138,9 @@ export default {
         renewalCodeJq: this.renewalCodeJq,
         renewalCodeSy: this.renewalCodeSy,
         agreementId: this.totalCompanyList[num].agreementId,
+        guoRenSpecialAgreementVo
       };
       this.$api.letter.guorenquote(params).then(res => {
-
         this.totalCompanyList[num].msg = res.msg;
         if (!!res.msg && res.msg.indexOf("不存在有效协议") >= 0) {
           this.totalCompanyList[num].quoteCode = "4";
@@ -5482,6 +5510,7 @@ export default {
       this.companyId = data.result.companyId;
       this.apiType = data.apiType;
       this.hbsubmitdialogVisible = true;
+      this.contributingState=false
       if(data.namesimple=='紫金财险'){
         this.$api.letter.zijinqueryClauseData({ companyId: this.companyId }).then(res => {
             this.zijinengageListData = res.data;
@@ -5514,6 +5543,7 @@ export default {
     },
     hbsubmit() {
       this.hbsubmitdialogVisible = false;
+      this.contributingState=false
       this.$api.letter.getByCompanyId({ companyId: this.companyId }).then(async res => {
         if (res.code == 200) {
           var data = res.data;