|
|
@@ -916,8 +916,9 @@
|
|
|
报价公司
|
|
|
</span>
|
|
|
</template>
|
|
|
- <el-table :data="showQuoteData" style="width: calc(100% - 48px); margin: 0 24px" row-key="id"
|
|
|
- :preserve-expanded-content="true" @row-click="handleClickRow" @expand-change="handelExpend">
|
|
|
+ <el-table ref="quoteDataRef" :data="showQuoteData" style="width: calc(100% - 48px); margin: 0 24px"
|
|
|
+ row-key="id" :preserve-expanded-content="true" @expand-change="handelExpend"
|
|
|
+ @selection-change="handleSelectionChange">
|
|
|
<el-table-column type="expand">
|
|
|
<template #default="scope">
|
|
|
<div class="equities"
|
|
|
@@ -1149,6 +1150,10 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column prop="checked" align="center" width="55">
|
|
|
+ <template #header>
|
|
|
+ <el-checkbox v-model="selectAll" :indeterminate="showQuoteData.some(v => v.checked !== selectAll)"
|
|
|
+ @change="handleSelectionChange" />
|
|
|
+ </template>
|
|
|
<template #default="scope">
|
|
|
<el-checkbox v-model="scope.row.checked" @change="handleSelect(scope.row)" />
|
|
|
</template>
|
|
|
@@ -2748,6 +2753,7 @@ const handleEquitiesSave = (data: any) => {
|
|
|
const getSchemeResult = (bool: false) => {
|
|
|
if (!insurancePolicyForm.value.order.insuranceCompanyCode) return
|
|
|
if (!insurancePolicyForm.value.productId) return
|
|
|
+ const insuranceCompanyCode = insurancePolicyForm.value.order.insuranceCompanyCode
|
|
|
api.insurancePolicyApi.getSchemeResult({
|
|
|
companyId: insurancePolicyForm.value.order.insuranceCompanyCode,
|
|
|
productId: insurancePolicyForm.value.productId,
|
|
|
@@ -2768,7 +2774,7 @@ const getSchemeResult = (bool: false) => {
|
|
|
}
|
|
|
// 方案信息
|
|
|
quoteData.value.forEach((item: any) => {
|
|
|
- if (item.id === insurancePolicyForm.value.order.insuranceCompanyCode) {
|
|
|
+ if (item.id === insuranceCompanyCode) {
|
|
|
list = list.map((item1: any) => {
|
|
|
return {
|
|
|
...item1,
|
|
|
@@ -2822,6 +2828,16 @@ const getSchemeResult = (bool: false) => {
|
|
|
})
|
|
|
}
|
|
|
|
|
|
+const selectAll = ref(false)
|
|
|
+const handleSelectionChange = (val) => {
|
|
|
+ const bool = showQuoteData.value.some(v => v.checked !== selectAll.value)
|
|
|
+ if (bool) selectAll.value = true
|
|
|
+ for (let i = 0; i < showQuoteData.value.length; i++) {
|
|
|
+ const element = showQuoteData.value[i]
|
|
|
+ element.checked = bool || val
|
|
|
+ handleSelect(element)
|
|
|
+ }
|
|
|
+}
|
|
|
const handleSelect = (row: any) => {
|
|
|
insurancePolicyForm.value.order.insuranceCompanyCode = row.id
|
|
|
getSchemeResult()
|
|
|
@@ -2831,9 +2847,6 @@ const handelExpend = (e: any) => {
|
|
|
insurancePolicyForm.value.order.insuranceCompanyCode = e.id
|
|
|
getSchemeResult()
|
|
|
}
|
|
|
-const handleClickRow = (a: any, b: any) => {
|
|
|
-
|
|
|
-}
|
|
|
|
|
|
/**
|
|
|
* 根据视图成功状态过滤报价数据
|
|
|
@@ -3475,6 +3488,7 @@ const handleSubmit = async (InsurancePolicyRefs: FormInstance | undefined, scope
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
+
|
|
|
/**
|
|
|
* 批量报价
|
|
|
*/
|