测试签名

This commit is contained in:
mengxiaolong
2020-08-04 11:14:35 +08:00
parent 0bb7547e59
commit 832ce7dd8c

View File

@@ -199,7 +199,6 @@ export default {
},
async insurantUpload(file) {
let res = await this.afterRead(file)
console.log(res)
this.supplement.insurantUploadResult.push({
rgssUrl: res.path
})
@@ -209,14 +208,12 @@ export default {
this.transfer.cardUploadResult.push({
rgssUrl: res.path
})
console.log(res)
},
//签名
async autograph(personType) {
let problemInfo = JSON.parse(localStorage.getItem('currentProblemItem'))
if (!this.isWeixin) {
// eslint-disable-next-line
const res = await EWebBridge.webCallAppInJs('ca_sign', {
let signParam = {
name: personType === 0 ? problemInfo.prtName : problemInfo.insuredName,
type: '1',
number: '142727199301063550',
@@ -224,17 +221,23 @@ export default {
pageNo: '1',
index: 1,
offset: 20,
pos: 3
})
pos: 3,
signatureWidth: this.$utils.signParams().signatureWidth,
signatureHeight: this.$utils.signParams().signatureHeight
}
console.log(signParam)
// eslint-disable-next-line
const res = await EWebBridge.webCallAppInJs('ca_sign', signParam)
let signRes = JSON.parse(res)
// 投保人签名
if (personType === 0 && res.state === '1') {
if (personType === 0 && signRes.state === '1') {
this.policyholderSigned = true
}
// 被保人签名
else if (personType === 1 && res.state === '1') {
else if (personType === 1 && signRes.state === '1') {
this.insurantSigned = true
}
console.log(res)
console.log('签名结果: ', res)
} else {
this.toAirSign('0', '签字日期', '-150', '2', personType)
}
@@ -345,7 +348,6 @@ export default {
},
async getMessage({ type, data }) {
// 获取dialog信息type为confirm时为短信框alert时是确定框
console.log(type, data)
let currentProblem = JSON.parse(localStorage.getItem('currentProblemItem'))
let problemData = {
id: currentProblem.id,
@@ -362,7 +364,6 @@ export default {
// 契约问题件
if (this.issueType === 'TB89') {
problemData.content = this.newContract.feedback
console.log(problemData)
}
// 补充资料类问题件
else if (this.issueType === '828601') {
@@ -378,7 +379,6 @@ export default {
item.subBusinessType = '0'
}
problemData.list.push(...this.supplement.policyholderUploadResult)
console.log(problemData)
}
// 转账不成功问题件
else {
@@ -391,12 +391,9 @@ export default {
item.subBusinessType = '0'
}
problemData.list = this.transfer.cardUploadResult
console.log(problemData)
}
// 更新
let res = await updateQuestionDetail(problemData)
console.log(res)
this.dialog.show = false
}
},
@@ -405,7 +402,6 @@ export default {
id: this.$route.params.id
})
this.problemDetail = rs.content.list[0]
console.log(this.problemDetail)
let problemDetail = rs.content.list[0]
this.supplement.descriptionInsurant = problemDetail.content
this.supplement.descriptionPolicyholder = problemDetail.issueContent
@@ -434,9 +430,6 @@ export default {
let imgBase64Data = sessionStorage.getItem('oneimgBase64Data')
let wxSigned = sessionStorage.getItem('onewxSigned')
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
console.log(signInfo)
console.log('imgBase64Data: twoimgBase64Data:' + imgBase64Data)
console.log('wxSigned: ' + wxSigned)
if (wxSigned) {
console.log('第二次进问题件详情页面')
this.base64D = imgBase64Data