签名页信息不显示

This commit is contained in:
liu.xiaofeng@ebiz-digits.com
2023-08-01 16:56:45 +08:00
parent 26fd37d63d
commit 7bb682871e
10 changed files with 231 additions and 361 deletions

View File

@@ -131,13 +131,19 @@ export default {
}, },
// 获取签名状态 // 获取签名状态
getOrderDetail() { getOrderDetail() {
openLoading()
let that = this let that = this
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
this.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
return new Promise((resolve) => { return new Promise((resolve) => {
getOrderDetail1(data).then(res => { getOrderDetail1(data).then(res => {
this.$toast.clear()
if (res.result == '0') { if (res.result == '0') {
res.orderDTO.ebizSignDTOS.map(item => { res.orderDTO.ebizSignDTOS.map(item => {
if (item.signType == '0' || item.signType == '2') { if (item.signType == '0' || item.signType == '2') {

View File

@@ -2,7 +2,6 @@
<div class="insuranceInformation-container pb50 redRadioCheckbox"> <div class="insuranceInformation-container pb50 redRadioCheckbox">
<van-notice-bar :scrollable="false" v-if="!Time" class="notice">{{ `提示阅读时长需在${this.Time ? this.time : this.number}秒以上` }}</van-notice-bar> <van-notice-bar :scrollable="false" v-if="!Time" class="notice">{{ `提示阅读时长需在${this.Time ? this.time : this.number}秒以上` }}</van-notice-bar>
<iframe :src="src + pdfUrl" class="iframe"></iframe> <iframe :src="src + pdfUrl" class="iframe"></iframe>
<van-radio-group v-model="radio" class="pb10 pt20 pl30 fs14"> <van-radio-group v-model="radio" class="pb10 pt20 pl30 fs14">
<van-radio name="1" @click="click"> <van-radio name="1" @click="click">
本人确认已阅读 本人确认已阅读
@@ -75,11 +74,7 @@ export default {
[NoticeBar.name]: NoticeBar [NoticeBar.name]: NoticeBar
}, },
mounted() { mounted() {
let that = this
that.timeOut()
document.body.style.backgroundColor = '#fff' document.body.style.backgroundColor = '#fff'
},
async created() {
if (!this.isWeixin) { if (!this.isWeixin) {
setTimeout(() => { setTimeout(() => {
// eslint-disable-next-line no-undef // eslint-disable-next-line no-undef
@@ -98,53 +93,33 @@ export default {
if (this.isWeixin) { if (this.isWeixin) {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
} }
if (this.detailJump != '1') { if (this.detailJump != '1') {
// 投被保险人是否同人 // 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
} }
// if (this.detailJump != '1') {
// this.getOrderDetail()
// }
if (this.isWeixin) { if (this.isWeixin) {
let imgBase64Data = sessionStorage.getItem('twoimgBase64Data') let imgBase64Data = sessionStorage.getItem('twoimgBase64Data')
let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned')) let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned'))
// let wxSigned = false
let signInfo = JSON.parse(localStorage.getItem('signInfo')) let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log('`````````````````````````````````')
console.log('imgBase64Data: twoimgBase64Data:' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) { if (wxSigned) {
console.log('第二次进入电子保单')
console.log('````````````````````````````````')
this.getOrderDetail().then(() => { this.getOrderDetail().then(() => {
this.Time = true this.Time = true
this.isOver = true this.isOver = true
this.radio = '1' this.radio = '1'
this.base64 = imgBase64Data this.base64 = imgBase64Data
this.isDisabledComplite = false this.isDisabledComplite = false
console.log('signInfo.status:' + signInfo.status)
if (signInfo.status == '0') { if (signInfo.status == '0') {
// this.appntSign.documentStatus = '3'
console.log('``````````````````')
//因签字后微信端签字面板无法返回状态,导致签字状态不变,下一步按钮无法点击 //因签字后微信端签字面板无法返回状态,导致签字状态不变,下一步按钮无法点击
this.$set(this.appntSign, 'documentStatus', '3') this.$set(this.appntSign, 'documentStatus', '3')
console.log('appntSign.documentStatus: ' + this.appntSign.documentStatus)
this.isSign = false this.isSign = false
this.isDisabledComplite = false this.isDisabledComplite = false
// this.isDisable = false
} else { } else {
this.$set(this.insuredSign, 'documentStatus', '3') this.$set(this.insuredSign, 'documentStatus', '3')
// this.insuredSign.documentStatus = '3'
this.isDisabledComplite = false this.isDisabledComplite = false
this.isSign = false this.isSign = false
} }
}) })
} else { } else {
console.log('第一次进入电子保单')
this.timeOut() this.timeOut()
this.getOrderDetail() this.getOrderDetail()
} }
@@ -154,6 +129,10 @@ export default {
this.getOrderDetail() this.getOrderDetail()
} }
} }
this.timeOut()
},
created() {
}, },
methods: { methods: {
appCallBack(data) { appCallBack(data) {
@@ -209,6 +188,12 @@ export default {
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
this.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getOrderDetail(data).then(res => { getOrderDetail(data).then(res => {
if (res.result == '0') { if (res.result == '0') {

View File

@@ -74,12 +74,11 @@ export default {
[Dialog.name]: Dialog, [Dialog.name]: Dialog,
[NoticeBar.name]: NoticeBar [NoticeBar.name]: NoticeBar
}, },
mounted() { created() {
let that = this
that.timeOut()
document.body.style.backgroundColor = '#fff'
}, },
async created() { async mounted() {
document.body.style.backgroundColor = '#fff'
if (!this.isWeixin) { if (!this.isWeixin) {
setTimeout(() => { setTimeout(() => {
// eslint-disable-next-line no-undef // eslint-disable-next-line no-undef
@@ -98,52 +97,32 @@ export default {
if (this.isWeixin) { if (this.isWeixin) {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
} }
if (this.detailJump != '1') { if (this.detailJump != '1') {
// 投被保险人是否同人 // 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
} }
// if (this.detailJump != '1') {
// this.getOrderDetail()
// }
if (this.isWeixin) { if (this.isWeixin) {
let imgBase64Data = sessionStorage.getItem('twoimgBase64Data') let imgBase64Data = sessionStorage.getItem('twoimgBase64Data')
let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned')) let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned'))
// let wxSigned = false
let signInfo = JSON.parse(localStorage.getItem('signInfo')) let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log('`````````````````````````````````')
console.log('imgBase64Data: twoimgBase64Data:' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) { if (wxSigned) {
console.log('第二次进入电子保单')
console.log('````````````````````````````````')
this.getOrderDetail().then(() => { this.getOrderDetail().then(() => {
this.Time = true this.Time = true
this.isOver = true this.isOver = true
this.radio = '1' this.radio = '1'
this.base64 = imgBase64Data this.base64 = imgBase64Data
this.isDisabledComplite = false this.isDisabledComplite = false
console.log('signInfo.status:' + signInfo.status)
if (signInfo.status == '0') { if (signInfo.status == '0') {
// this.appntSign.documentStatus = '3'
console.log('``````````````````')
this.$set(this.appntSign, 'documentStatus', '3') this.$set(this.appntSign, 'documentStatus', '3')
console.log('appntSign.documentStatus: ' + this.appntSign.documentStatus)
this.isSign = false this.isSign = false
this.isDisabledComplite = false this.isDisabledComplite = false
// this.isDisable = false
} else { } else {
this.$set(this.insuredSign, 'documentStatus', '3') this.$set(this.insuredSign, 'documentStatus', '3')
// this.insuredSign.documentStatus = '3'
this.isDisabledComplite = false this.isDisabledComplite = false
this.isSign = false this.isSign = false
} }
}) })
} else { } else {
console.log('第一次进入电子保单')
this.timeOut() this.timeOut()
this.getOrderDetail() this.getOrderDetail()
} }
@@ -153,6 +132,7 @@ export default {
this.getOrderDetail() this.getOrderDetail()
} }
} }
this.timeOut()
}, },
methods: { methods: {
appCallBack(data) { appCallBack(data) {

View File

@@ -83,89 +83,70 @@ export default {
[Dialog.name]: Dialog, [Dialog.name]: Dialog,
[NoticeBar.name]: NoticeBar [NoticeBar.name]: NoticeBar
}, },
mounted() { created() {
let that = this
that.timeOut()
document.body.style.backgroundColor = '#fff'
}, },
async created() { async mounted() {
// 当前代理人渠道--个险渠道,中介渠道 let that = this
document.body.style.backgroundColor = '#fff'
// 当前代理人渠道--个险渠道,中介渠道
let dataReturn = await riskRules.getAgentInfoFunc(this) let dataReturn = await riskRules.getAgentInfoFunc(this)
this.branchTypeVal = dataReturn.branchTypeVal this.branchTypeVal = dataReturn.branchTypeVal
if (!this.isWeixin) { if (!that.isWeixin) {
setTimeout(() => { setTimeout(() => {
// eslint-disable-next-line no-undef // eslint-disable-next-line no-undef
EWebBridge.webCallAppInJs('webview_left_button', { EWebBridge.webCallAppInJs('webview_left_button', {
img: this.$assetsUrl + 'images/del-close-btn@3x.png', img: that.$assetsUrl + 'images/del-close-btn@3x.png',
intercept: '1' //是否拦截原生返回事件 1是 其他否 intercept: '1' //是否拦截原生返回事件 1是 其他否
}) })
}, 100) }, 100)
window.appCallBack = this.appCallBack window.appCallBack = that.appCallBack
} }
let that = this
that.detailJump = window.localStorage.getItem('detailJump') that.detailJump = window.localStorage.getItem('detailJump')
that.signVal = window.localStorage.getItem('sign-val') that.signVal = window.localStorage.getItem('sign-val')
// 获取投保人信息 // 获取投保人信息
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')) that.saleInsuredInfo = JSON.parse(that.$CacheUtils.getLocItem('saleInsuredInfo'))
if (this.isWeixin) { if (that.isWeixin) {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(that.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
} }
if (this.detailJump != '1') { if (that.detailJump != '1') {
// 投被保险人是否同人 // 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(that.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
} }
// if (this.detailJump != '1') {
// this.getOrderDetail()
// }
if (this.isWeixin) { if (this.isWeixin) {
let imgBase64Data = sessionStorage.getItem('twoimgBase64Data') let imgBase64Data = sessionStorage.getItem('twoimgBase64Data')
let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned')) let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned'))
// let wxSigned = false
let signInfo = JSON.parse(localStorage.getItem('signInfo')) let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log('`````````````````````````````````')
console.log('imgBase64Data: twoimgBase64Data:' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) { if (wxSigned) {
console.log('第二次进入电子保单') that.getOrderDetail().then(() => {
console.log('````````````````````````````````') that.Time = true
this.getOrderDetail().then(() => { that.isOver = true
this.Time = true that.radio = '1'
this.isOver = true that.base64 = imgBase64Data
this.radio = '1' that.isDisabledComplite = false
this.base64 = imgBase64Data
this.isDisabledComplite = false
console.log('signInfo.status:' + signInfo.status)
if (signInfo.status == '0') { if (signInfo.status == '0') {
// this.appntSign.documentStatus = '3' that.$set(that.appntSign, 'documentStatus', '3')
console.log('``````````````````') that.isSign = false
this.$set(this.appntSign, 'documentStatus', '3') that.isDisabledComplite = false
console.log('appntSign.documentStatus: ' + this.appntSign.documentStatus)
this.isSign = false
this.isDisabledComplite = false
// this.isDisable = false
} else { } else {
this.$set(this.insuredSign, 'documentStatus', '3') that.$set(that.insuredSign, 'documentStatus', '3')
// this.insuredSign.documentStatus = '3' that.isDisabledComplite = false
this.isDisabledComplite = false that.isSign = false
this.isSign = false
} }
}) })
} else { } else {
console.log('第一次进入电子保单') that.timeOut()
this.timeOut() that.getOrderDetail()
this.getOrderDetail()
} }
} else { } else {
this.timeOut() that.timeOut()
if (this.detailJump != '1') { if (that.detailJump != '1') {
this.getOrderDetail() that.getOrderDetail()
} }
} }
that.timeOut()
}, },
methods: { methods: {
appCallBack(data) { appCallBack(data) {
@@ -221,8 +202,15 @@ export default {
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
this.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getOrderDetail(data).then(res => { getOrderDetail(data).then(res => {
this.$toast.clear()
if (res.result == '0') { if (res.result == '0') {
if(res.orderDTO.universalRiskNotifyDTO && res.orderDTO.universalRiskNotifyDTO.isUniversalRiskNotifyShowPoint){ if(res.orderDTO.universalRiskNotifyDTO && res.orderDTO.universalRiskNotifyDTO.isUniversalRiskNotifyShowPoint){
this.isUniversalRiskNotifyShowPoint = res.orderDTO.universalRiskNotifyDTO.isUniversalRiskNotifyShowPoint this.isUniversalRiskNotifyShowPoint = res.orderDTO.universalRiskNotifyDTO.isUniversalRiskNotifyShowPoint

View File

@@ -56,9 +56,10 @@ export default {
[NoticeBar.name]: NoticeBar [NoticeBar.name]: NoticeBar
}, },
created() { created() {
this.init()
}, },
mounted() { async mounted() {
await this.init()
let readingType = localStorage.getItem('readingProtocolType') let readingType = localStorage.getItem('readingProtocolType')
if (readingType && readingType === '1') { if (readingType && readingType === '1') {
this.protocol = true this.protocol = true
@@ -86,7 +87,7 @@ export default {
} }
}, },
methods: { methods: {
async init(){ init(){
this.getOrderDetail() this.getOrderDetail()
}, },
timeOut() { timeOut() {
@@ -110,11 +111,18 @@ export default {
// 获取PDF的路径 // 获取PDF的路径
getOrderDetail() { getOrderDetail() {
let that = this let that = this
this.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getOrderDetail(data).then(res => { getOrderDetail(data).then(res => {
this.$toast.clear()
if (res.result == '0') { if (res.result == '0') {
res.orderDTO.ebizSignDTOS.map(item => { res.orderDTO.ebizSignDTOS.map(item => {
if (item.documentCode == '12') { if (item.documentCode == '12') {

View File

@@ -881,147 +881,8 @@ export default {
} }
} }
}, },
async created() { created() {
let data = {
orderNo: this.$route.query.orderNo
}
getOrderDetail(data).then(res => {
if (res.result == '0') {
let array = []
res.orderDTO.ebizSignDTOS.map(item => {
array.push(item.documentCode)
})
this.isPersonalInformation = array.findIndex(item => item === '12')
}
})
if (!this.isWeixin) {
setTimeout(() => {
// eslint-disable-next-line no-undef
EWebBridge.webCallAppInJs('webview_left_button', {
img: this.$assetsUrl + 'images/del-close-btn@3x.png',
intercept: '1' //是否拦截原生返回事件 1是 其他否
})
}, 100)
window.appCallBack = this.appCallBack
}
let that = this
// 获取当前时间的时间戳
// var day2 = new Date()
// var day = day2.setTime(day2.getTime())
// console.log(day)
// console.log(new Date('2020-01-01 23:59:59').getTime())
// if (day > new Date('2020-01-01 23:59:59').getTime()) {
// this.dayShow = true
// }
// 获取产品编码
// this.chooseProductCodes = JSON.parse(localStorage.chooseProductCodes)
that.detailJump = window.localStorage.getItem('detailJump')
if (this.detailJump == '1') {
this.pdfUrl = encodeURIComponent(config.imgDomain + `/returnDirectStream?imgPath=${localStorage.getItem('insurance-policyUrl')}`)
}
that.signVal = window.localStorage.getItem('sign-val')
// 判断是不是万能险
let comment = window.localStorage.getItem('productCode')
// if (comment == 'GFRS_M0003') {
if (comment == 'GFRS_M0003' || comment == 'GFRS_M0015' || comment == 'GFRS_M0017') {
this.isComment = true
}
// 获取投保人信息
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
// 在微信
if (this.isWeixin) {
// 在微信且不是回执签收
if (this.detailJump != '1') {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
let imgBase64Data = sessionStorage.getItem('imgBase64Data')
let wxSigned = sessionStorage.getItem('wxSigned')
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log('`````````````````````````````````')
console.log('imgBase64Data:twoimgBase64Data ' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) {
console.log('第二次进入电子保单!')
console.log('that222222222222', that)
this.getOrderDetail().then(() => {
this.Time = true
this.isOver = true
this.radio = '1'
this.base64 = imgBase64Data
this.isDisabledComplite = false
console.log('signInfo.status:' + signInfo.status)
if (signInfo.status == '0') {
// this.appntSign.documentStatus = '3'
console.log('``````````````````')
this.$set(this.appntSign, 'documentStatus', '3')
console.log('appntSign.documentStatus: ' + this.appntSign.documentStatus)
this.isSign = false
this.isDisabledComplite = false
// this.isDisable = false
} else {
this.$set(this.insuredSign, 'documentStatus', '3')
// this.insuredSign.documentStatus = '3'
this.isDisabledComplite = false
this.isSign = false
}
})
} else {
console.log('````````````````````````')
console.log('第一次进入电子保单')
this.timeOut()
this.getOrderDetail()
}
} else {
// 在微信而且是回执签收
document.title = '保险合同签收回执电子确认书签名'
let imgBase64Data = sessionStorage.getItem('imgBase64Data')
let wxSigned = sessionStorage.getItem('wxSigned')
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log('`````````````````````````````````')
console.log('imgBase64Data:twoimgBase64Data ' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) {
console.log('第二次进入电子保单!')
console.log('that222222222222', that)
this.Time = true
this.isOver = true
this.radioSure = '1'
this.base64 = imgBase64Data
this.isDisabledComplite = false
console.log('signInfo.status:' + signInfo.status)
if (signInfo.status == '0') {
// this.appntSign.documentStatus = '3'
console.log('``````````````````')
this.$set(this.appntSign, 'documentStatus', '3')
console.log('appntSign.documentStatus: ' + this.appntSign.documentStatus)
this.isSign = false
this.isDisabledComplite = false
this.isSubmit = false
} else {
this.$set(this.insuredSign, 'documentStatus', '3')
// this.insuredSign.documentStatus = '3'
this.isDisabledComplite = false
this.isSign = false
}
}
}
} else {
// 不在微信且不是回执签收
if (this.detailJump != '1') {
// 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
this.timeOut()
this.getOrderDetail()
} else {
// 不在微信但是在回执签收
document.title = '保险合同签收回执电子确认书签名'
}
}
}, },
computed: { computed: {
listenChange() { listenChange() {
@@ -1080,19 +941,109 @@ export default {
} }
} }
}, },
mounted() { async mounted() {
document.body.style.backgroundColor = '#fff' document.body.style.backgroundColor = '#fff'
let data = {
// console.log('---签名投保单PDFurl:', this.pdfUrl, 'insurance-policyUrl', window.localStorage.getItem('insurance-policyUrl')) orderNo: this.$route.query.orderNo
// this.pdfUrl = "http://10.10.100.98:7012/updown/returnDirectStream?imgPath=Ra4LpmZv2h6FrwZPS48QIETiI2AcWWLx6RavVjoAkoMMdje9Cf6YWX3FlAKn%2FwOBIMX%2BfXJaM6sn%0D%0AiUe41vurjQJ65teJQwdrc2wcOn%2FJtQSVGLphInLPv0HGtHpZ3OhD" }
// this.src = 'http://139.199.50.151:7000/pdfjs/web/viewer.html?file=' getOrderDetail(data).then(res => {
// console.log('------pdf url:', this.src + this.pdfUrl) if (res.result == '0') {
//实例化 let array = []
// this.pdfh5 = new Pdfh5('#pdf', { res.orderDTO.ebizSignDTOS.map(item => {
// pdfurl: config.imgDomain + `/returnDirectStream?imgPath=${window.localStorage.getItem('insurance-policyUrl')}` array.push(item.documentCode)
// // pdfurl: res.data.content.content })
// }) this.isPersonalInformation = array.findIndex(item => item === '12')
// 获取签名信息 }
})
if (!this.isWeixin) {
setTimeout(() => {
EWebBridge.webCallAppInJs('webview_left_button', {
img: this.$assetsUrl + 'images/del-close-btn@3x.png',
intercept: '1' //是否拦截原生返回事件 1是 其他否
})
}, 100)
window.appCallBack = this.appCallBack
}
let that = this
that.detailJump = window.localStorage.getItem('detailJump')
if (this.detailJump == '1') {
this.pdfUrl = encodeURIComponent(config.imgDomain + `/returnDirectStream?imgPath=${localStorage.getItem('insurance-policyUrl')}`)
}
that.signVal = window.localStorage.getItem('sign-val')
// 判断是不是万能险
let comment = window.localStorage.getItem('productCode')
if (comment == 'GFRS_M0003' || comment == 'GFRS_M0015' || comment == 'GFRS_M0017') {
this.isComment = true
}
// 获取投保人信息
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
// 在微信
if (this.isWeixin) {
// 在微信且不是回执签收
if (this.detailJump != '1') {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
let imgBase64Data = sessionStorage.getItem('imgBase64Data')
let wxSigned = sessionStorage.getItem('wxSigned')
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
if (wxSigned) {
this.getOrderDetail().then(() => {
this.Time = true
this.isOver = true
this.radio = '1'
this.base64 = imgBase64Data
this.isDisabledComplite = false
if (signInfo.status == '0') {
this.$set(this.appntSign, 'documentStatus', '3')
this.isSign = false
this.isDisabledComplite = false
} else {
this.$set(this.insuredSign, 'documentStatus', '3')
this.isDisabledComplite = false
this.isSign = false
}
})
} else {
this.timeOut()
this.getOrderDetail()
}
} else {
// 在微信而且是回执签收
document.title = '保险合同签收回执电子确认书签名'
let imgBase64Data = sessionStorage.getItem('imgBase64Data')
let wxSigned = sessionStorage.getItem('wxSigned')
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
if (wxSigned) {
this.Time = true
this.isOver = true
this.radioSure = '1'
this.base64 = imgBase64Data
this.isDisabledComplite = false
if (signInfo.status == '0') {
this.$set(this.appntSign, 'documentStatus', '3')
this.isSign = false
this.isDisabledComplite = false
this.isSubmit = false
} else {
this.$set(this.insuredSign, 'documentStatus', '3')
this.isDisabledComplite = false
this.isSign = false
}
}
}
} else {
// 不在微信且不是回执签收
if (this.detailJump != '1') {
// 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
this.timeOut()
this.getOrderDetail()
} else {
// 不在微信但是在回执签收
document.title = '保险合同签收回执电子确认书签名'
}
}
}, },
beforeRouteLeave(to, from, next) { beforeRouteLeave(to, from, next) {
document.body.style.backgroundColor = '' document.body.style.backgroundColor = ''

View File

@@ -556,34 +556,7 @@ export default {
} }
}, },
created() { created() {
if (!this.isWeixin) {
setTimeout(() => {
// eslint-disable-next-line no-undef
EWebBridge.webCallAppInJs('webview_left_button', {
img: this.$assetsUrl + 'images/del-close-btn@3x.png',
intercept: '1' //是否拦截原生返回事件 1是 其他否
})
}, 100)
window.appCallBack = this.appCallBack
}
let that = this
that.detailJump = window.localStorage.getItem('detailJump')
that.signVal = window.localStorage.getItem('sign-val')
// 获取投保人信息
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
if (this.isWeixin) {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
}
if (this.detailJump != '1') {
// 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
}
}, },
computed: { computed: {
listenChange() { listenChange() {
@@ -623,6 +596,30 @@ export default {
} }
}, },
async mounted() { async mounted() {
if (!this.isWeixin) {
setTimeout(() => {
// eslint-disable-next-line no-undef
EWebBridge.webCallAppInJs('webview_left_button', {
img: this.$assetsUrl + 'images/del-close-btn@3x.png',
intercept: '1' //是否拦截原生返回事件 1是 其他否
})
}, 100)
window.appCallBack = this.appCallBack
}
let that = this
that.detailJump = window.localStorage.getItem('detailJump')
that.signVal = window.localStorage.getItem('sign-val')
// 获取投保人信息
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
if (this.isWeixin) {
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
}
if (this.detailJump != '1') {
// 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
}
if (this.detailJump != '1') { if (this.detailJump != '1') {
this.getOrderDetail() this.getOrderDetail()
} }
@@ -630,39 +627,22 @@ export default {
let imgBase64Data = sessionStorage.getItem('threeimgBase64Data') let imgBase64Data = sessionStorage.getItem('threeimgBase64Data')
let wxSigned = sessionStorage.getItem('threewxSigned') let wxSigned = sessionStorage.getItem('threewxSigned')
let signInfo = localStorage.getItem('signInfo') let signInfo = localStorage.getItem('signInfo')
console.log('`````````````````````````````````')
console.log('imgBase64Data:threeimgBase64Data ' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) { if (wxSigned) {
console.log('第二次进入电子保单')
console.log('````````````````````````````````')
let rs = await this.getOrderDetail() let rs = await this.getOrderDetail()
console.log(rs)
if (rs === 'success') { if (rs === 'success') {
this.Time = true this.Time = true
this.radio = '1' this.radio = '1'
this.base64 = imgBase64Data this.base64 = imgBase64Data
this.isDisabledComplite = false this.isDisabledComplite = false
if (signInfo.status == '1') { if (signInfo.status == '1') {
// this.appntSign.signStatus = '1'
console.log('``````````````````')
console.log('appntSign:' + this.appntSign)
this.$set(this.appntSign, 'signStatus', '1') this.$set(this.appntSign, 'signStatus', '1')
this.isSubmit = false this.isSubmit = false
this.isSign = false this.isSign = false
} else { } else {
// this.insuredSign.signStatus = '1'
console.log('````````````````````')
console.log('insuredSign:' + this.insuredSign)
this.$set(this.insuredSign, 'signStatus', '1') this.$set(this.insuredSign, 'signStatus', '1')
// this.isDisabledComplite = false
} }
} }
console.log('第二次进入保单,完成状态查看')
console.log(this.isDisabledComplite)
} else { } else {
console.log('````````````````````````')
console.log('第一次进入电子保单')
this.timeOut() this.timeOut()
this.getOrderDetail() this.getOrderDetail()
} }
@@ -674,12 +654,6 @@ export default {
} }
document.body.style.backgroundColor = '#fff' document.body.style.backgroundColor = '#fff'
this.pdfUrl = encodeURIComponent(config.imgDomain + `/returnDirectStream?imgPath=${window.localStorage.getItem('insurance-policyUrl')}`) this.pdfUrl = encodeURIComponent(config.imgDomain + `/returnDirectStream?imgPath=${window.localStorage.getItem('insurance-policyUrl')}`)
//实例化
// this.pdfh5 = new Pdfh5('#pdf', {
// pdfurl: config.imgDomain + `/returnDirectStream?imgPath=${window.localStorage.getItem('insurance-policyUrl')}`
// // pdfurl: res.data.content.content
// })
// 获取签名信息
}, },
beforeRouteLeave(to, from, next) { beforeRouteLeave(to, from, next) {
document.body.style.backgroundColor = '' document.body.style.backgroundColor = ''

View File

@@ -60,33 +60,10 @@ export default {
[NoticeBar.name]: NoticeBar [NoticeBar.name]: NoticeBar
}, },
created() { created() {
this.init()
}, },
mounted() { mounted() {
// let readingType = localStorage.getItem('readingProtocolType') this.init()
// if (readingType && readingType === '1') {
// this.protocol = true
// }
// let that = this
// // {{switchFlag.Time?pageVariable.msg:pageVariable.number}}
// that.timeOut()
// that.activeType = window.localStorage.getItem('activeType')
// // Notify({
// // type: 'warning',
// // message: `提示:阅读时长需在${this.Time ? this.time : this.number}秒以上`,
// // duration: 10000,
// // background: '#999999',
// // className: 'notify'
// // })
// document.body.style.backgroundColor = '#fff'
// that.signVal = window.localStorage.getItem('sign-val')
// // if (JSON.parse(window.localStorage.getItem('sign-insured'))) {
// // that.insuredSign = JSON.parse(window.localStorage.getItem('sign-insured'))
// // }
// // if (JSON.parse(window.localStorage.getItem('sign-appnt'))) {
// // that.appntSign = JSON.parse(window.localStorage.getItem('sign-appnt'))
// // }
}, },
methods: { methods: {
async init(){ async init(){
@@ -140,11 +117,18 @@ export default {
// 获取PDF的路径 // 获取PDF的路径
getOrderDetail() { getOrderDetail() {
let that = this let that = this
this.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getOrderDetail(data).then(res => { getOrderDetail(data).then(res => {
this.$toast.clear()
if (res.result == '0') { if (res.result == '0') {
res.orderDTO.insuredDTOs[0].riskDTOLst.forEach(item => { res.orderDTO.insuredDTOs[0].riskDTOLst.forEach(item => {
if(item.isMainRisk == '0'){ if(item.isMainRisk == '0'){

View File

@@ -62,6 +62,7 @@
mounted() { mounted() {
let that = this let that = this
document.body.style.backgroundColor = '#fff' document.body.style.backgroundColor = '#fff'
that.getOrderDetail();
setTimeout(function() { setTimeout(function() {
closeLoading() closeLoading()
that.timeOut() that.timeOut()
@@ -78,7 +79,6 @@
}, 100) }, 100)
window.appCallBack = this.appCallBack window.appCallBack = this.appCallBack
} }
this.getOrderDetail();
let that = this; let that = this;
that.signVal = window.localStorage.getItem('sign-val') that.signVal = window.localStorage.getItem('sign-val')
}, },
@@ -131,13 +131,19 @@
}, },
// 获取签名状态 // 获取签名状态
getOrderDetail() { getOrderDetail() {
openLoading()
let that = this let that = this
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
that.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
return new Promise((resolve) => { return new Promise((resolve) => {
getOrderDetail1(data).then(res => { getOrderDetail1(data).then(res => {
that.$toast.clear()
if (res.result == '0') { if (res.result == '0') {
for(let i = 0;i<res.orderDTO.ebizSignDTOS.length;i++){ for(let i = 0;i<res.orderDTO.ebizSignDTOS.length;i++){
if (res.orderDTO.ebizSignDTOS[i].signType == '0' || res.orderDTO.ebizSignDTOS[i].signType == '2') { if (res.orderDTO.ebizSignDTOS[i].signType == '0' || res.orderDTO.ebizSignDTOS[i].signType == '2') {

View File

@@ -82,16 +82,15 @@ export default {
[Dialog.name]: Dialog, [Dialog.name]: Dialog,
[NoticeBar.name]: NoticeBar [NoticeBar.name]: NoticeBar
}, },
mounted() { created() {
let that = this
that.timeOut()
document.body.style.backgroundColor = '#fff'
}, },
async created() { async mounted() {
// 当前代理人渠道--个险渠道,中介渠道 document.body.style.backgroundColor = '#fff'
// 当前代理人渠道--个险渠道,中介渠道
let dataReturn = await riskRules.getAgentInfoFunc(this) let dataReturn = await riskRules.getAgentInfoFunc(this)
this.branchTypeVal = dataReturn.branchTypeVal this.branchTypeVal = dataReturn.branchTypeVal
if (!this.isWeixin) { if (!this.isWeixin) {
setTimeout(() => { setTimeout(() => {
// eslint-disable-next-line no-undef // eslint-disable-next-line no-undef
@@ -114,48 +113,29 @@ export default {
if (this.detailJump != '1') { if (this.detailJump != '1') {
// 投被保险人是否同人 // 投被保险人是否同人
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
// 获取被保险人信息
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
} }
// if (this.detailJump != '1') {
// this.getOrderDetail()
// }
if (this.isWeixin) { if (this.isWeixin) {
let imgBase64Data = sessionStorage.getItem('twoimgBase64Data') let imgBase64Data = sessionStorage.getItem('twoimgBase64Data')
let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned')) let wxSigned = JSON.parse(sessionStorage.getItem('twowxSigned'))
// let wxSigned = false
let signInfo = JSON.parse(localStorage.getItem('signInfo')) let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log('`````````````````````````````````')
console.log('imgBase64Data: twoimgBase64Data:' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) { if (wxSigned) {
console.log('第二次进入电子保单')
console.log('````````````````````````````````')
this.getOrderDetail().then(() => { this.getOrderDetail().then(() => {
this.Time = true this.Time = true
this.isOver = true this.isOver = true
this.radio = '1' this.radio = '1'
this.base64 = imgBase64Data this.base64 = imgBase64Data
this.isDisabledComplite = false this.isDisabledComplite = false
console.log('signInfo.status:' + signInfo.status)
if (signInfo.status == '0') { if (signInfo.status == '0') {
// this.appntSign.documentStatus = '3'
console.log('``````````````````')
this.$set(this.appntSign, 'documentStatus', '3') this.$set(this.appntSign, 'documentStatus', '3')
console.log('appntSign.documentStatus: ' + this.appntSign.documentStatus)
this.isSign = false this.isSign = false
this.isDisabledComplite = false this.isDisabledComplite = false
// this.isDisable = false
} else { } else {
this.$set(this.insuredSign, 'documentStatus', '3') this.$set(this.insuredSign, 'documentStatus', '3')
// this.insuredSign.documentStatus = '3'
this.isDisabledComplite = false this.isDisabledComplite = false
this.isSign = false this.isSign = false
} }
}) })
} else { } else {
console.log('第一次进入电子保单')
this.timeOut() this.timeOut()
this.getOrderDetail() this.getOrderDetail()
} }
@@ -165,6 +145,7 @@ export default {
this.getOrderDetail() this.getOrderDetail()
} }
} }
this.timeOut()
}, },
methods: { methods: {
appCallBack(data) { appCallBack(data) {
@@ -220,8 +201,15 @@ export default {
let data = { let data = {
orderNo: that.$route.query.orderNo orderNo: that.$route.query.orderNo
} }
that.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……'
})
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getOrderDetail(data).then(res => { getOrderDetail(data).then(res => {
that.$toast.clear()
if (res.result == '0') { if (res.result == '0') {
// 截取代理人机构号的前六位,用于去判断是否属于柳州代理人 // 截取代理人机构号的前六位,用于去判断是否属于柳州代理人
if(res.orderDTO.recmdDTO.managerOrg && res.orderDTO.recmdDTO.managerOrg.length >= 6){ if(res.orderDTO.recmdDTO.managerOrg && res.orderDTO.recmdDTO.managerOrg.length >= 6){