diff --git a/src/views/ebiz/product/HomeProduct.vue b/src/views/ebiz/product/HomeProduct.vue index d318b3c36..1aab8b3b3 100644 --- a/src/views/ebiz/product/HomeProduct.vue +++ b/src/views/ebiz/product/HomeProduct.vue @@ -253,7 +253,6 @@ export default { // 内外勤判断 this.isInner = /^N{1}/.test(result.branchType) || /^S/.test(result.branchType) || /^T/.test(result.branchType) || /^JZG/.test(result.branchType) // 判断是否内勤 this.branchType = result.branchType //6 网销渠道 - window.localStorage.setItem('branchType', this.branchType) this.isGoodStart = result.showTemplateKmh === 'KMH' ? '1' : '2' // 判断是否开门红 1-开门红 2-否 this.isPersonalInsu = this.personalInsu.indexOf(result.branchType) > -1 // 判断是否个险渠道 this.organizationImgUrl = this.isGoodStart == '1' ? this.organizationKmhImgUrl : this.organizationNormalImgUrl diff --git a/src/views/ebiz/sale/InsuredInfo.vue b/src/views/ebiz/sale/InsuredInfo.vue index 0e496c251..4030d3d62 100644 --- a/src/views/ebiz/sale/InsuredInfo.vue +++ b/src/views/ebiz/sale/InsuredInfo.vue @@ -519,6 +519,7 @@ import riskRules from '@/views/ebiz/common/risk-rules' import { gbcProjectDetail, getDepartmentByProjectNo } from '@/api/GBC/GBC' import { getCheckModelAgentInfo } from '@/api/ebiz/common/common' + import { getAgentInfo } from '@/api/ebiz/my/my' export default { name: 'insuredInfo', @@ -690,14 +691,7 @@ } }, async created() { - this.branchType = window.localStorage.getItem('branchType') || null - if(this.branchType == '14'){ - // 网点名称 - const userInfo = await getCheckModelAgentInfo({}) - if(userInfo.result == 0) { - this.insureInfo.branchName = userInfo.comName - } - } + await this.getAgentInfo() this.specilFlag = this.$route.query.specilFlag localStorage.removeItem('bankCardUrlPath') localStorage.removeItem('bankCard') @@ -810,6 +804,19 @@ } }, methods: { + async getAgentInfo() { + const result = await getAgentInfo({}) + if (result.result === '0') { + this.branchType = result.branchType + if(this.branchType == '14'){ + // 网点名称 + const userInfo = await getCheckModelAgentInfo({}) + if(userInfo.result == 0) { + this.insureInfo.branchName = userInfo.comName + } + } + } + }, idNoVerification(val) { if (this.insuredDialogInfo.idType == '1') { if (!idNoCheck.isIdno(val)) {