From 08e88a9bf9aedf6b9cac42e705b71115d0e8eeb9 Mon Sep 17 00:00:00 2001
From: pangxingyue <120277894@qq.com>
Date: Thu, 25 Mar 2021 17:06:18 +0800
Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E6=96=B0=E6=8A=95=E4=BF=9D=E4=BA=A7?=
=?UTF-8?q?=E5=93=81=E4=BF=A1=E6=81=AF=E6=8E=A5=E5=8F=A3=E8=BF=94=E5=9B=9E?=
=?UTF-8?q?=E7=BC=96=E5=86=99=EF=BC=8C=E6=8F=90=E4=BA=A4=E7=BC=96=E5=86=99?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../ebiz/insureAgain/InsureInformation.vue | 2 +-
.../ebiz/insureAgain/ProductInformation.vue | 507 ++++++++++++++----
2 files changed, 401 insertions(+), 108 deletions(-)
diff --git a/src/views/ebiz/insureAgain/InsureInformation.vue b/src/views/ebiz/insureAgain/InsureInformation.vue
index ea16b4512..07aaf0cba 100644
--- a/src/views/ebiz/insureAgain/InsureInformation.vue
+++ b/src/views/ebiz/insureAgain/InsureInformation.vue
@@ -688,7 +688,7 @@ export default {
let str = ''
let resultData = await commitReOrder(params)
if (resultData.result == 0) {
- localStorage.setItem('orderNo', resultData.orderNo)
+ localStorage.setItem('newOrderNo', resultData.orderNo)
this.$jump({
flag: 'h5',
extra: {
diff --git a/src/views/ebiz/insureAgain/ProductInformation.vue b/src/views/ebiz/insureAgain/ProductInformation.vue
index 2093dec35..e4dfe7b6a 100644
--- a/src/views/ebiz/insureAgain/ProductInformation.vue
+++ b/src/views/ebiz/insureAgain/ProductInformation.vue
@@ -3,42 +3,69 @@
保险计划详情
-
-
-
-
-
- 主险
- 国富人寿附加住院医疗保险(B款)
-
-
-
-
-
- 保费(元)
-
-
-
-
-
-
- 附加险
- 国富人寿附加住院医疗保险(B款)
-
-
-
-
-
-
-
-
-
-
- 保费(元)
-
-
-
-
+
+
+
{{item.insuYear}}年
+
{{item.payEndYearFlag == 'Y' ? `${item.payEndYear}年` :
+ `至${item.payEndYear}岁`}}
+
一次性交清
+
{{item.payIntvName}}
+
+
+ 主险
+ 国富人寿附加住院医疗保险(B款)
+
+
+ {{item2.dutyName}}
+ {{item2.dutyName}}
+
+ {{item.amt}}
+
+
+ 保费(元)
+
+ {{item.prem}}元
+
+
+
+
+
+
+
+
+
+
+ 附加险
+ {{item.riskName}}
+
+
+ 保额
+
+ {{item2.prem}}
+
+
+ {{item.getLimit}}
+ {{item.getRate}}
+
+
+ 保费(元)
+
+ {{item.prem}}元
+
+
+
+
+
+
+
+ {{ isRead ? '已阅读《特别约定》' : '点击这里阅读《特别约定》' }}
+
+
+
+
+
+
@@ -88,8 +109,9 @@ import ProgressBar from '@/components/ebiz/insureAgain/ProgressBar'
import DropdownBox from '@/components/ebiz/insureAgain/DropdownBox'
import InfoCell from '@/components/ebiz/insureAgain/InfoCell'
import ReadingAgreement from '@/components/ebiz/insureAgain/ReadingAgreement'
-import commitReOrder from '@/api/ebiz/insureAgain/insureAgain'
-import { Checkbox, RadioGroup, Radio, Dialog } from 'vant'
+import { commitReOrder, getReAppntPolicy } from '@/api/ebiz/insureAgain/insureAgain'
+import { Checkbox, RadioGroup, Radio, Dialog, CheckboxGroup } from 'vant'
+import CacheUtils from '@/assets/js/utils/cacheUtils'
export default {
name: 'ProductInformation',
components: {
@@ -98,6 +120,7 @@ export default {
InfoCell,
ReadingAgreement,
[Checkbox.name]: Checkbox,
+ [CheckboxGroup.name]: CheckboxGroup,
[RadioGroup.name]: RadioGroup,
[Radio.name]: Radio
},
@@ -108,76 +131,308 @@ export default {
remitRiskA: false,
style: { height: '100vh', width: '100vw' },
isRead: false,
- active: 1
+ active: 1,
+ riskDTOLst: [],
+ mainList: [], //主险
+ additionalList: [], //附加险
+ checkboxResult: [],
+ insuredDTOs: [],
+ orderInfoDTO: []
}
},
created() {
- this.getProductInfo()
+ this.getReAppntPolicy()
},
methods: {
- getProductInfo() {
- let a = `{
+ getReAppntPolicy() {
+ getReAppntPolicy({ policyNo: CacheUtils.getLocItem('policyNo') }).then(res => {
+ if (res.result == 0) {
+ let a = `{
"orderDTO": {
+ "appntDTO": {
+ "area": "",
+ "averageAnnualIncome": 10,
+ "avoirdupois": 60,
+ "birthday": "1983-03-12",
+ "certiexpiredate": "2035-03-31",
+ "effectiveDateType": "false",
+ "email": "310598205@qq.com",
+ "healthGrade": "1",
+ "homeAddress": "百苑小区101号",
+ "homeArea": "450103",
+ "homeCity": "450100",
+ "homeProvince": "450000",
+ "idNo": "452624198303120727",
+ "idType": "1",
+ "liabilitiesMoney": "0",
+ "lifeGrade": "1",
+ "marriage": "1",
+ "medical": "0",
+ "mobile": "13707711024",
+ "name": "艾琳马上",
+ "nativeplace": "1",
+ "occupationCode": "4070103",
+ "occupationName": "经纪人(内勤)",
+ "otherSalarySource": "",
+ "salarySource": "1",
+ "sex": "1",
+ "stature": 167,
+ "taxResidentId": "1",
+ "workcompany": "国富人寿保险股份有限公司"
+ },
"insuredDTOs": [
{
- "insuredId": 18425,
- "riskDTOLst": [
+ "area": "",
+ "averageAnnualIncome": 1000,
+ "avoirdupois": 60,
+ "birthday": "1983-03-12",
+ "certiexpiredate": "2035-03-31",
+ "companyArea": "",
+ "companyCity": "",
+ "effectiveDateType": "false",
+ "healthGrade": "1",
+ "homeAddress": "百苑小区101号",
+ "homeArea": "450103",
+ "homeCity": "450100",
+ "homeProvince": "450000",
+ "idNo": "452624198303120727",
+ "idType": "1",
+ "liabilitiesMoney": "0",
+ "lifeGrade": "1",
+ "marriage": "1",
+ "medical": "0",
+ "mobile": "13707711024",
+ "name": "艾琳咳咳",
+ "nativeplace": "1",
+ "occupationCode": "4070103",
+ "occupationName": "经纪人(内勤)",
+ "otherSalarySource": "",
+ "province": "",
+ "relationToMainInsured": "5",
+ "salarySource": "1",
+ "sex": "1",
+ "stature": 167,
+ "taxResidentId": "1",
+ "workcompany": "国富人寿保险股份有限公司",
+ "bnfDTOs": [
{
- "amt": 1042,
- "insuYear": 85,
- "insuYearFlag": "A",
- "intMult": 0,
- "isMainRisk": "0",
- "mainRiskCode": "GFRS_M0002",
- "payEndYear": 3,
- "payEndYearFlag": "Y",
- "payIntv": 12,
- "prem": 2000,
- "riskCode": "GFRS_M0002",
- "riskName": "国富人寿国富民鑫年金保险",
- "riskType": "5",
- "standPrem": 2000,
- "thirdInsuraceNo": ""
+ "area": "450103",
+ "birthday": "1980-01-02",
+ "bnfLot": 50,
+ "bnfOrder": 1,
+ "bnfType": "0 1-是法定;0-不是法定",
+ "certiexpiredate": "2035-03-31",
+ "city": "450100",
+ "effectiveDateType": "false",
+ "healthGrade": "1",
+ "idNo": "110101198001020219",
+ "idType": "1",
+ "lifeGrade": "2",
+ "marriage": "2",
+ "mobile": "13707711024",
+ "name": "爱来",
+ "nativeplace": "1",
+ "occupationCode": "2070202",
+ "occupationName": "保险推销员",
+ "province": "450000",
+ "relationToInsured": "3",
+ "sex": "0",
+ "village": "百苑小区101号",
+ "yearSalary": "23"
},
{
- "amt": 50000,
- "dutyLst": [
- {
- "amt": 50000,
- "dutyCode": "410100",
- "dutyName": "意外身故/伤残保险金",
- "prem": 80
- }
- ],
- "getLimit": "0",
- "getRate": "1",
- "insuYear": 1,
- "insuYearFlag": "Y",
- "intMult": 0,
- "isMainRisk": "1",
- "mainRiskCode": "GFRS_M0002",
- "payEndYear": 1000,
- "payEndYearFlag": "Y",
- "payIntv": 0,
- "prem": 80,
- "riskCode": "GFRS_A0005",
- "riskName": "国富人寿附加综合意外伤害保险",
- "riskType": "2",
- "standPrem": 80,
- "thirdInsuraceNo": ""
+ "area": "450103",
+ "birthday": "1983-03-12",
+ "bnfLot": 50,
+ "bnfOrder": 1,
+ "bnfType": "0 1-是法定;0-不是法定",
+ "certiexpiredate": "2035-03-31",
+ "city": "450100",
+ "effectiveDateType": "false",
+ "healthGrade": "1",
+ "idNo": "452624198303120727",
+ "idType": "1",
+ "lifeGrade": "1",
+ "marriage": "1",
+ "mobile": "13707711024",
+ "name": "艾琳马上来",
+ "nativeplace": "1",
+ "occupationCode": "4070103",
+ "occupationName": "经纪人(内勤)",
+ "province": "450000",
+ "relationToInsured": "4",
+ "sex": "1",
+ "village": "百苑小区101号",
+ "yearSalary": "32"
}
],
- "sex": "1"
+ "impartDTO": {
+ "impartItemDTOS": [
+ {
+ "impartAnswer": "1",
+ "impartCode": "9",
+ "impartContent": "最近六个月内是否有下列身体不适症状?①长期咳嗽咳痰、声音嘶哑、痰中带血、咯血;②胸闷、胸痛、心慌、气喘、气短、呼吸困难;③吐血、大便带血、黑便、反复腹痛、恶心、反酸、呕吐、腹泻;④反复尿频、尿痛、血尿、腰痛、外生殖器溃疡;⑤反复皮下出血、鼻腔出血、牙龈出血、发热、持续疲倦;⑥晕倒、意识不清、视力下降、抽搐、反复头痛、头晕;⑦半年内体重增加或减少5公斤以上;⑧关节红肿、疼痛、活动受限。",
+ "IntroDuctions": ""
+ },
+ {
+ "impartAnswer": "1",
+ "impartCode": "12a",
+ "impartContent": "是否曾患有失明、视网膜出血或剥离、视神经炎、青光眼、白内障、眼底病变、视野缺失、屈光度1000度以上、聋哑、中耳炎、梅尼尔氏病或其他眼、耳、鼻、喉或口腔疾病?",
+ "IntroDuctions": ""
+ }
+ ]
+ },
+ "riskDTOLst": [
+ {
+ "riskName": "国富人寿国富民惠医疗保险(2020版)",
+ "insuYear": 1,
+ "insuYearFlag": "Y",
+ "payIntv": 12,
+ "payEndYear": 1000,
+ "payEndYearFlag": "Y",
+ "prem": 10000,
+ "riskCode": "1113202",
+ "isMainRisk": "0",
+ "amt": 22640,
+ "dutyLst": [
+ {
+ "dutyName":"国富民惠医疗保险金",
+ "dutyCode":"320300",
+ "amt":1000000,
+ "prem":536,
+ "getLimit":"0",
+ "getRate":"0"
+ },
+ {
+ "dutyName":"一般医疗保险金",
+ "dutyCode":"",
+ "amt":100000,
+ "prem":536,
+ "getLimit":"",
+ "getRate":""
+ }
+ ]
+ },
+ {
+ "riskName": "国富人寿国富民惠医疗保险(2020版)",
+ "insuYear": 1,
+ "insuYearFlag": "Y",
+ "payIntv": 12,
+ "payEndYear": 1000,
+ "payEndYearFlag": "Y",
+ "prem": 10000,
+ "riskCode": "11132021",
+ "isMainRisk": "1",
+ "amt": 22640,
+ "dutyLst": [
+ {
+ "dutyName":"住院医疗保险金",
+ "dutyCode":"320300",
+ "amt":1000000,
+ "prem":536,
+ "getLimit":"0",
+ "getRate":"0"
+ },
+ {
+ "dutyName":"住院津贴保险金",
+ "dutyCode":"",
+ "amt":100000,
+ "prem":536,
+ "getLimit":"",
+ "getRate":""
+ },
+ {
+ "dutyName":"恶性肿瘤住院津贴保险金",
+ "dutyCode":"",
+ "amt":100000,
+ "prem":536,
+ "getLimit":"",
+ "getRate":""
+ }
+ ]
+ },
+ {
+ "riskName": "国富人寿国富民惠医疗保险(2020版)",
+ "insuYear": 1,
+ "insuYearFlag": "Y",
+ "payIntv": 12,
+ "payEndYear": 1000,
+ "payEndYearFlag": "Y",
+ "prem": 10000,
+ "riskCode": "11132022",
+ "isMainRisk": "1",
+ "amt": 22640,
+ "dutyLst": [
+ {
+ "dutyName":"国富民惠医疗保险金",
+ "dutyCode":"320300",
+ "amt":1000000,
+ "prem":536,
+ "getLimit":"0",
+ "getRate":"0"
+ },
+ {
+ "dutyName":"",
+ "dutyCode":"",
+ "amt":100000,
+ "prem":536,
+ "getLimit":"",
+ "getRate":""
+ }
+ ]
+ }
+ ]
}
],
+ "orderAccountDTO": {
+ "accountName": "艾琳马上",
+ "bankName": "BOCOM",
+ "cardBookCode": "4354256325325678790"
+ },
"orderInfoDTO": {
- "orderNo": "8186270000012119",
- "supportBank": "0"
+ "contNo": "保单号",
+ "contState": "保单状态 1-承保;4-终止;0-投保中",
+ "cValiDate": "生效日期 String",
+ "orderStatus": "签收状态 0-未签收 1-已签收"
}
- },
- "orderType": "RE_RISK_ORDER"
-}`;
-console.log(JSON.parse(a))
+ }
+}`
+ let res = JSON.parse(a)
+ this.insuredDTOs = res.orderDTO.insuredDTOs[0]
+ this.orderInfoDTO = res.orderDTO.orderInfoDTO
+ this.riskDTOLst = this.insuredDTOs.riskDTOLst
+ this.riskDTOLst.forEach((element, index) => {
+ if (element.isMainRisk === '0') {
+ switch (element.payIntv) {
+ case -1:
+ element.payIntvName = '不定期交'
+ break
+ case 0:
+ element.payIntvName = '一次交清'
+ break
+ case 1:
+ element.payIntvName = '月交'
+ break
+ case 3:
+ element.payIntvName = '季交'
+ break
+ case 6:
+ element.payIntvName = '半年交'
+ break
+ case 12:
+ element.payIntvName = '年交'
+ break
+ }
+ this.mainList.push(element)
+ } else {
+ this.additionalList.push(element)
+ }
+ })
+ // console.log(res, '=============this.riskDTOLst================')
+ // console.log(this.mainList, '=============this.mainList================')
+ console.log(this.additionalList, '=============this.additionalList================')
+ }
+ })
},
appCallBack(data) {
if (data.trigger == 'left_button_click') {
@@ -240,16 +495,44 @@ console.log(JSON.parse(a))
* @return {*}
*/
commitReOrder() {
+ let additionals = []
+ this.checkboxResult.forEach(res => {
+ this.additionalList.forEach(res2 => {
+ if (res2.riskCode === res) {
+ additionals.push(res2)
+ }
+ })
+ })
+ let riskDTOLst = [...this.mainList, ...additionals]
let data = {
- 'orderDTO': {
- 'insuredDTOs': '',
- 'orderInfoDTO': '',
- },
- 'orderType': 'RE_RISK_ORDER'
+ orderDTO: {
+ insuredDTOs: [
+ {
+ insuredId: this.insuredDTOs.idNo,
+ sex: this.insuredDTOs.sex,
+ riskDTOLst: riskDTOLst
+ }
+ ],
+ orderInfoDTO: {
+ orderNo: this.orderInfoDTO.contNo,
+ supportBank: '0'
+ }
+ },
+ orderType: 'RE_RISK_ORDER'
}
- commitReOrder(data).then(res=>{
+ commitReOrder(data).then(res => {
if (res.result === '0') {
-
+ // localStorage.setItem('newOrderNo', resultData.orderNo)
+ console.log('/insureAgain/Notification')
+ this.$jump({
+ flag: 'h5',
+ extra: {
+ url: location.origin + `/#/insureAgain/Notification`
+ },
+ routerInfo: {
+ path: `/insureAgain/Notification`
+ }
+ })
}
})
}
@@ -258,7 +541,7 @@ console.log(JSON.parse(a))