refactor(productFlow): 优化保费计算和被保人信息组件

- 移除未使用的 syncLocalstorageData 和 cacheUtils 导入
- 注释掉社保选项的选择器组件及相关逻辑
- 移除 IndexBar 组件的引入和注册
- 优化布尔值判断逻辑,使用严格不等于比较
- 统一风险代码和产品代码的严格相等比较
- 清理冗余的条件判断和代码注释
This commit is contained in:
hz
2025-11-27 14:43:08 +08:00
parent 22f73a7bf7
commit eb5c201a5f
2 changed files with 13 additions and 17 deletions

View File

@@ -469,11 +469,9 @@ import SelectRadio from '@/components/ebiz/SelectRadio'
import riskRules from '@/views/ebiz/commonFlowImprove/risk-rules'
import AddtionRiskList from '@/views/ebiz/commonFlowImprove/AddRiskList.vue'
import { trial } from '@/api/ebiz/common/common'
import { syncLocalstorageData } from '@/assets/js/syncLocalstorageData'
import { validateRelationshipToInsured } from '@/views/ebiz/productFlowImprove/components/js/relationshipToInsured'
import TotalPremium from '@/views/ebiz/saleFlowProImprove/components/TotalPremium.vue'
import { deepClone } from '@/assets/js/utils/objectUtils'
import cacheUtils from '@/assets/js/utils/cacheUtils'
import { applicant, insured } from '@/views/ebiz/saleFlowProImprove/js/state'
const DUTY_DEFAULT_MUTIPLE = 1000

View File

@@ -234,15 +234,15 @@
v-validate="'required'"
@click="toSelect('3')"
/> -->
<select-radio
v-if="Number(branchType) !== 14"
v-validate="'required'"
:radios="medicalRadio"
:value.sync="userInfo.medical"
label="有无社保"
name="有无社保"
required
/>
<!-- <select-radio-->
<!-- v-if="Number(branchType) !== 14"-->
<!-- v-validate="'required'"-->
<!-- :radios="medicalRadio"-->
<!-- :value.sync="userInfo.medical"-->
<!-- label="有无社保"-->
<!-- name="有无社保"-->
<!-- required-->
<!-- />-->
<van-field
v-validate="'required'"
:value="userInfo.taxResidentId | idToText('taxIdentity')"
@@ -567,7 +567,6 @@
<script>
import { Area, CellGroup, Checkbox, Dialog, Field, Picker, Popup, Radio, RadioGroup } from 'vant'
import SelectRadio from './components/SelectRadio.vue'
import IndexBar from '@/components/ebiz/sale/IndexBar'
import FieldDatePicter from '@/components/ebiz/FieldDatePicter'
import OccupationPicker from './components/OccupationPicker.vue'
import CustomerPicker from './components/CustomerPicker.vue'
@@ -607,7 +606,6 @@ export default {
[RadioGroup.name]: RadioGroup,
[Radio.name]: Radio,
IdentityCardScan: IdentityCardScan,
[IndexBar.name]: IndexBar,
[Dialog.name]: Dialog,
SearchField
},
@@ -751,7 +749,7 @@ export default {
this.insureInfo.orderNo = this.userInfo.orderNo || ''
this.setCustomerMarriage(res.orderDTO.appntDTO.marriage)
//是否长期
this.userInfo.effectiveDateType = res.orderDTO.appntDTO.effectiveDateType == 'false' ? false : true
this.userInfo.effectiveDateType = res.orderDTO.appntDTO.effectiveDateType !== 'false'
//有无社保
this.userInfo.medical = res.orderDTO.appntDTO.medical
//设为联系地址
@@ -777,13 +775,13 @@ export default {
//------------------------专为桂企写死--begin---------------//
if (res.orderDTO.insuredDTOs[0] && res.orderDTO.insuredDTOs[0].riskDTOLst) {
this.specilFlag = res.orderDTO.insuredDTOs[0].riskDTOLst.some(v => {
return v.riskCode == 'GFRS_M0024' || v.riskCode == 'GFRS_M0040'
return v.riskCode === 'GFRS_M0024' || v.riskCode === 'GFRS_M0040'
})
? '1'
: '0'
} else if (res.orderDTO.orderInfoDTO.productCode == 'GFRS_M0024') {
} else if (res.orderDTO.orderInfoDTO.productCode === 'GFRS_M0024') {
this.specilFlag = '1'
} else if (res.orderDTO.orderInfoDTO.productCode == 'GFRS_M0040') {
} else if (res.orderDTO.orderInfoDTO.productCode === 'GFRS_M0040') {
this.specilFlag = '1'
}
if (this.$route.query.orderNo) {