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

Merge branch 'dev' of http://39.101.143.165:8090/dong_k/tenant-Platform into dev

@dongkboy 2 месяцев назад
Родитель
Сommit
b94379e57c
1 измененных файлов с 18 добавлено и 3 удалено
  1. 18 3
      src/views/insurancePolicy/index.vue

+ 18 - 3
src/views/insurancePolicy/index.vue

@@ -976,7 +976,7 @@
                                     :value="item.value"></el-option>
                                 </el-select>
                                 <span v-if="props.row.kindName == '乘客责任险'">*{{ insurancePolicyForm.seatCount - 1
-                                }}/座</span>
+                                  }}/座</span>
                               </div>
                             </template>
                           </el-table-column>
@@ -1046,7 +1046,7 @@
                           <el-table-column label="产品名称" prop="productName" align="center">
                             <template #default="props">
                               <el-button link type="primary" @click="getJYXDetail(props.row)">{{ props.row.productName
-                              }}</el-button>
+                                }}</el-button>
                             </template>
                           </el-table-column>
                           <el-table-column label="数量" align="center">
@@ -3335,6 +3335,13 @@ let loading = ref(false)  // 提交加载状态
  * @param scope 当前行作用域
  */
 const handleSubmit = async (InsurancePolicyRefs: FormInstance | undefined, scope: any) => {
+  if (!Number(insurancePolicyForm.value.purchasePrice)) {
+    ElMessage({
+      message: '请重新选择车型',
+      type: 'warning'
+    })
+    return
+  }
   const valid = await validateForm(InsurancePolicyRefs)
   if (!valid) {
     ElMessage({
@@ -3370,6 +3377,13 @@ const handleSubmit = async (InsurancePolicyRefs: FormInstance | undefined, scope
  * 批量报价
  */
 const batchQuotes = async (InsurancePolicyRefs: FormInstance | undefined) => {
+  if (!Number(insurancePolicyForm.value.purchasePrice)) {
+    ElMessage({
+      message: '请重新选择车型',
+      type: 'warning'
+    })
+    return
+  }
   const valid = await validateForm(InsurancePolicyRefs)
   if (!valid) {
     ElMessage({
@@ -3506,6 +3520,7 @@ const paramValidate = () => {
 }
 // 统一报价
 const quoteInsurance = async (companyId: any, companyIndex: any, val: any) => {
+
   quoteData.value[companyIndex].loading = true
   let company = quoteData.value[companyIndex]
   let product = company.projectList?.find((v, i) => val.productIndex === i)
@@ -3832,7 +3847,7 @@ const ruleFilterCompany = (item: any, obj: any) => {
               item.quoteResult = { ...a, ...obj };
               item.insurancePlanInfo = {}
               item.insurancePlanInfo.drivings = obj.accidentalDrivings;
-              item.insurancePlanInfo.kinds = obj.kindInfoVo.filter(v=>v.id);
+              item.insurancePlanInfo.kinds = obj.kindInfoVo.filter(v => v.id);
               item.quoteCode = 200
               item.checked = true
               // 如果有错误信息,设置状态为失败 并记录错误信息