测试更新问题件详情

This commit is contained in:
mengxiaolong
2020-08-04 13:32:23 +08:00
parent 832ce7dd8c
commit b337b3e90c
4 changed files with 68 additions and 32 deletions

View File

@@ -20,7 +20,7 @@ export default [
}
},
{
path: '/questions/result',
path: '/questions/result/:result',
name: 'result',
component: g('Result'),
meta: {

View File

@@ -26,7 +26,7 @@
{{ supplement.descriptionPolicyholder }}
</p>
</div>
<van-uploader :after-read="policyHolderUpload" name="copy" @delete="deleteImg" v-model="supplement.copyImgList" />
<van-uploader :after-read="policyHolderUpload" name="copy" v-model="supplement.copyImgList" />
</div>
</div>
</div>
@@ -81,7 +81,7 @@
<span>投保人/监护人亲笔签名</span>
<van-button type="danger" size="small" @click="autograph(0)">{{ policyholderSigned ? '已签名' : '签名' }}</van-button>
</div>
<div class="list">
<div class="list" v-if="problemDetail.receiveType === '1'">
<span>被投保人亲笔签名</span>
<van-button type="danger" size="small" @click="autograph(1)">{{ insurantSigned ? '已签名' : '签名' }}</van-button>
</div>
@@ -176,8 +176,10 @@ export default {
issueType: 0,
// 投保人是否已签名
policyholderSigned: false,
policyholderBase64: '',
// 被保人是否已签名
insurantSigned: false,
insurantBase64: '',
// 接收验证码手机号码
phoneNum: '',
showConfirm: false,
@@ -194,9 +196,6 @@ export default {
rgssUrl: res.path
})
},
deleteImg(file, detail) {
console.log(file, detail)
},
async insurantUpload(file) {
let res = await this.afterRead(file)
this.supplement.insurantUploadResult.push({
@@ -231,10 +230,12 @@ export default {
let signRes = JSON.parse(res)
// 投保人签名
if (personType === 0 && signRes.state === '1') {
this.policyholderBase64 = decodeURI(signRes.sign)
this.policyholderSigned = true
}
// 被保人签名
else if (personType === 1 && signRes.state === '1') {
this.insurantBase64 = decodeURI(signRes.sign)
this.insurantSigned = true
}
console.log('签名结果: ', res)
@@ -329,22 +330,17 @@ export default {
// 转账失败问题件不用签名
if (this.issueType !== '818901') {
// 校验签名
if (this.policyholderSigned && this.insurantSigned) {
this.dialog = {
type: 'confirm',
show: true,
text: '为确定用户身份我们将向186xxxx8972此手机号发送验证码'
}
if (this.problemDetail.receiveType === '0') {
if (!this.policyholderSigned) return this.$toast('请完成签名后继续操作')
} else {
this.$toast('请完成全部签名后继续操作')
}
} else {
this.dialog = {
type: 'confirm',
show: true,
text: '为确定用户身份我们将向186xxxx8972此手机号发送验证码'
if (!this.policyholderSigned || !this.insurantSigned) return this.$toast('请完成签名后继续操作')
}
}
this.dialog = {
type: 'confirm',
show: true,
text: '为确定用户身份我们将向186xxxx8972此手机号发送验证码'
}
},
async getMessage({ type, data }) {
// 获取dialog信息type为confirm时为短信框alert时是确定框
@@ -394,6 +390,17 @@ export default {
}
// 更新
let res = await updateQuestionDetail(problemData)
console.dir(res)
if (res.result === '0') {
this.$jump({
flag: 'h5',
extra: {
forbidSwipeBack: '1',
url: location.origin + `/#/questions/result/${res.result}`
},
routerInfo: { path: `/questions/result/${res.result}` }
})
}
this.dialog.show = false
}
},
@@ -402,9 +409,9 @@ export default {
id: this.$route.params.id
})
this.problemDetail = rs.content.list[0]
let problemDetail = rs.content.list[0]
this.supplement.descriptionInsurant = problemDetail.content
this.supplement.descriptionPolicyholder = problemDetail.issueContent
this.problemDetail.receiveType = JSON.parse(localStorage.getItem('currentProblemItem')).receiveType
this.supplement.descriptionInsurant = this.problemDetail.content
this.supplement.descriptionPolicyholder = this.problemDetail.issueContent
},
//微信空签
toAirSign(status, keyword, offset, originStatus, personType) {
@@ -591,7 +598,7 @@ export default {
}
}
.autograph {
padding: 10px;
padding: 10px 10px 20px 10px;
font-size: 12px;
.list {
&:first-child {

View File

@@ -44,7 +44,7 @@
</div>
<div class="list">
<van-tag class="tag" plain>状态</van-tag>
<div class="text">{{ item.status | statusFilter }}</div>
<div class="text">{{ item.status | stateFilter }}</div>
</div>
</div>
<div class="buttons">
@@ -89,7 +89,7 @@
</div>
<div class="list">
<van-tag class="tag" plain>状态</van-tag>
<div class="text">{{ item.status | statusFilter }}</div>
<div class="text">{{ item.status | stateFilter }}</div>
</div>
</div>
</div>
@@ -209,7 +209,7 @@ export default {
createTimeFormatFilter(val) {
return dateUtil.formatDate(new Date(val), 'yyyy-MM-dd HH:mm:ss')
},
statusFilter(val) {
stateFilter(val) {
switch (val) {
case '0':
return '已下发'

View File

@@ -1,21 +1,50 @@
<template>
<div class="result-container">
<!-- <div class="success">
<div class="success" v-if="$route.params.result === '0'">
<van-icon name="checked" color="#99CCFF" size="120" />
<p>提交成功</p>
</div> -->
<div class="fail">
</div>
<div class="fail" v-if="$route.params.result === '1'">
<van-icon name="clear" color="#FF6633" size="120" />
<p>提交失败</p>
<div class="reason">
Lorem, ipsum dolor sit amet consectetur adipisicing elit. Consectetur tenetur itaque labore quas amet accusamus quam in dicta officia, qui quidem maxime
facilis animi ea laudantium quo laborum odio! Tempore.
失败原因: Lorem, ipsum dolor sit amet consectetur adipisicing elit.
</div>
</div>
</div>
</template>
<script>
export default {}
export default {
created() {
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
},
methods: {
appCallBack(data) {
if (data.trigger == 'left_button_click') {
this.$jump({
flag: 'h5',
extra: {
title: '提交结果',
// 当前页面禁止右滑返回
forbidSwipeBack: 1,
url: location.origin + `/#/questions/list`
},
routerInfo: {
path: `/questions/list`
}
})
}
}
}
}
</script>
<style lang="scss" scoped>
.result-container {