|
|
@@ -2394,7 +2394,7 @@ let btns = ref({
|
|
|
checked: false
|
|
|
}],
|
|
|
})
|
|
|
-const handleChange = (item: any, type: any) => {
|
|
|
+const handleChange = async (item: any, type: any) => {
|
|
|
|
|
|
switch (type) {
|
|
|
case 'owner1':
|
|
|
@@ -2473,6 +2473,11 @@ const handleChange = (item: any, type: any) => {
|
|
|
}
|
|
|
break;
|
|
|
case 'insurance':
|
|
|
+ const valid = await validateForm(InsurancePolicyRefs.value)
|
|
|
+ if (!valid) {
|
|
|
+ ElMessage.warning('请完整填写相关信息')
|
|
|
+ return
|
|
|
+ }
|
|
|
ruleFilterCompany(item, null)
|
|
|
let list4 = optionObj.value.insuranceType.filter(a => a.label != item.label)
|
|
|
list4.forEach(a => a.checked = false)
|
|
|
@@ -3425,6 +3430,10 @@ const validate = async (quoteList) => {
|
|
|
for (let i = 0; i < quoteList.length; i++) {
|
|
|
const element = quoteList[i];
|
|
|
const product = element.projectList?.find((v, index) => element.productIndex === index)
|
|
|
+ if (!product) {
|
|
|
+ ElMessage.warning('请选择方案')
|
|
|
+ return
|
|
|
+ }
|
|
|
const noMatchObj = product.drivings.find(v => v.minQuantity && Number(v.quantity ?? 0) < Number(v.minQuantity))
|
|
|
if (noMatchObj) {
|
|
|
ElMessage({
|