mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-10 19:46:43 +08:00
[FIX]【自助入司流程优化】《担保书》空签调整
This commit is contained in:
@@ -18,11 +18,15 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="pl30 pb15">
|
<div class="pl30 pb15">
|
||||||
本人签字:
|
本人签字:
|
||||||
<van-button type="danger" size="small" @click="sign" :disabled="isDisable" v-no-more-click="1000">{{
|
<van-button v-if="!isWeixin" type="danger" size="small" @click="sign" :disabled="isDisable" v-no-more-click="1000">{{
|
||||||
appntSign.signState == '0' ? '签名' : '已签名'
|
appntSign.signState == '0' ? '签名' : '已签名'
|
||||||
}}</van-button>
|
}}</van-button>
|
||||||
|
<van-button v-else type="danger" size="small" @click="sign" disabled="disabled" v-no-more-click="1000">{{
|
||||||
|
appntSign.signState == '0' ? '未签名' : '已签名'
|
||||||
|
}}</van-button>
|
||||||
</div>
|
</div>
|
||||||
<van-button type="danger" :disabled="isDisabledComplite" @click="goNext" v-no-more-click="1000" size="large">下一步</van-button>
|
<van-button v-if="!isWeixin" type="danger" :disabled="isDisabledComplite" @click="goNext" v-no-more-click="1000" size="large">下一步</van-button>
|
||||||
|
<van-button v-if="isWeixin" type="danger" :disabled="isDisabledComplite" @click="goNext" v-no-more-click="1000" size="large">提交</van-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -35,7 +39,10 @@ import { filtSignList, getAgreementNextPagePath } from './js/methods'
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
|
let isWeixin = this.$utils.device().isWeixin //判断环境
|
||||||
return {
|
return {
|
||||||
|
// 是否在微信
|
||||||
|
isWeixin,
|
||||||
src: location.origin + '/pdfjs/web/viewer.html?file=',
|
src: location.origin + '/pdfjs/web/viewer.html?file=',
|
||||||
pdfUrl: '',
|
pdfUrl: '',
|
||||||
radio: '',
|
radio: '',
|
||||||
@@ -54,9 +61,15 @@ export default {
|
|||||||
// 是否签名 true 签名 false 未签名
|
// 是否签名 true 签名 false 未签名
|
||||||
isSign: false,
|
isSign: false,
|
||||||
isSignD: false,
|
isSignD: false,
|
||||||
|
//协议list
|
||||||
|
signList: [],
|
||||||
|
//当前页面协议签署后下一页路由
|
||||||
|
nextPagePath: '',
|
||||||
|
//签署人 0-申请人 1-担保人
|
||||||
|
code: '',
|
||||||
//推荐人信息
|
//推荐人信息
|
||||||
agentInfo: {},
|
agentInfo: {},
|
||||||
// 推荐人签名信息
|
// 签名信息
|
||||||
appntSign: {
|
appntSign: {
|
||||||
signState: '0',
|
signState: '0',
|
||||||
signStateD: '0'
|
signStateD: '0'
|
||||||
@@ -64,9 +77,9 @@ export default {
|
|||||||
//原生返回的加密包
|
//原生返回的加密包
|
||||||
base64: '',
|
base64: '',
|
||||||
//担保人原生返回的加密包
|
//担保人原生返回的加密包
|
||||||
base64D: '',
|
base64D: ''
|
||||||
// 是否重复签名
|
// 是否重复签名
|
||||||
isReSign: '0'
|
// isReSign: '0'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
@@ -84,6 +97,7 @@ export default {
|
|||||||
this.timeOut()
|
this.timeOut()
|
||||||
}
|
}
|
||||||
this.agreementQuery()
|
this.agreementQuery()
|
||||||
|
this.code = this.$route.query.code
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
//获取签署协议人信息
|
//获取签署协议人信息
|
||||||
@@ -105,20 +119,40 @@ export default {
|
|||||||
if (res.result == '0') {
|
if (res.result == '0') {
|
||||||
res.content.ebizAgreementDtoList.map(item => {
|
res.content.ebizAgreementDtoList.map(item => {
|
||||||
console.log(item)
|
console.log(item)
|
||||||
if (item.type == '12') {
|
if (item.type == '12' && item.documentType == this.code) {
|
||||||
that.appntSign = item
|
that.appntSign = item
|
||||||
|
// if (item.signState == '0') {
|
||||||
|
// this.isDisable = false
|
||||||
|
// this.isDisableD = false
|
||||||
|
// that.appntSign.signStateD = '0'
|
||||||
|
// that.appntSign.signState = '0'
|
||||||
|
// this.isReSign = '0'
|
||||||
|
// } else {
|
||||||
|
// this.isDisable = true
|
||||||
|
// this.isDisableD = true
|
||||||
|
// that.appntSign.signStateD = '1'
|
||||||
|
// that.appntSign.signState = '1'
|
||||||
|
// this.isReSign = '1'
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
if (item.type == '12' && item.documentType == '0') {
|
||||||
|
//申请人签名信息
|
||||||
if (item.signState == '0') {
|
if (item.signState == '0') {
|
||||||
this.isDisable = false
|
this.isDisable = false
|
||||||
this.isDisableD = false
|
|
||||||
that.appntSign.signStateD = '0'
|
|
||||||
that.appntSign.signState = '0'
|
that.appntSign.signState = '0'
|
||||||
this.isReSign = '0'
|
|
||||||
} else {
|
} else {
|
||||||
this.isDisable = true
|
this.isDisable = true
|
||||||
|
that.appntSign.signState = '1'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (item.type == '12' && item.documentType == '1') {
|
||||||
|
//担保人签名信息
|
||||||
|
if (item.signState == '0') {
|
||||||
|
this.isDisableD = false
|
||||||
|
that.appntSign.signStateD = '0'
|
||||||
|
} else {
|
||||||
this.isDisableD = true
|
this.isDisableD = true
|
||||||
that.appntSign.signStateD = '1'
|
that.appntSign.signStateD = '1'
|
||||||
that.appntSign.signState = '1'
|
|
||||||
this.isReSign = '1'
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@@ -198,73 +232,97 @@ export default {
|
|||||||
loadingType: 'spinner',
|
loadingType: 'spinner',
|
||||||
message: '加载中……'
|
message: '加载中……'
|
||||||
})
|
})
|
||||||
EWebBridge.webCallAppInJs('ca_sign', {
|
if (this.isWeixin) {
|
||||||
//身份证号码
|
this.toAirSign('0', '担保人签名', '3', '1')
|
||||||
number: localStorage.idNoD,
|
} else {
|
||||||
//姓名
|
EWebBridge.webCallAppInJs('ca_sign', {
|
||||||
name: localStorage.idNameD,
|
//身份证号码
|
||||||
//身份证号码id
|
number: localStorage.idNoD,
|
||||||
type: '1',
|
//姓名
|
||||||
keyword: '担保人签名',
|
name: localStorage.idNameD,
|
||||||
pageNo: '1',
|
//身份证号码id
|
||||||
index: '1',
|
type: '1',
|
||||||
offset: '5',
|
keyword: '担保人签名',
|
||||||
pos: '3'
|
pageNo: '1',
|
||||||
}).then(data => {
|
index: '1',
|
||||||
this.$toast.clear()
|
offset: '5',
|
||||||
if (JSON.parse(data).state == '1') {
|
pos: '3'
|
||||||
that.base64D = decodeURI(JSON.parse(data).sign)
|
}).then(data => {
|
||||||
that.appntSign.signStateD = '1'
|
this.$toast.clear()
|
||||||
if (that.appntSign.signStateD == '1') {
|
if (JSON.parse(data).state == '1') {
|
||||||
this.isDisabledComplite = false
|
that.base64D = decodeURI(JSON.parse(data).sign)
|
||||||
this.isSignD = true
|
that.appntSign.signStateD = '1'
|
||||||
} else {
|
if (that.appntSign.signStateD == '1') {
|
||||||
this.isDisabledComplite = true
|
this.isDisabledComplite = false
|
||||||
this.isSignD = false
|
this.isSignD = true
|
||||||
|
} else {
|
||||||
|
this.isDisabledComplite = true
|
||||||
|
this.isSignD = false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
})
|
}
|
||||||
|
},
|
||||||
|
//微信空签
|
||||||
|
toAirSign(status, keyword, offset, originStatus) {
|
||||||
|
console.log('offset == ', offset)
|
||||||
|
localStorage.setItem(
|
||||||
|
'signInfo',
|
||||||
|
JSON.stringify({
|
||||||
|
originStatus: originStatus,
|
||||||
|
idNo: localStorage.idNoD,
|
||||||
|
name: localStorage.idNameD,
|
||||||
|
type: '1',
|
||||||
|
keyword: keyword,
|
||||||
|
status: status,
|
||||||
|
offset: offset,
|
||||||
|
originUrl: location.href
|
||||||
|
})
|
||||||
|
)
|
||||||
|
window.location.href = this.$mainUrl + '/sign/index.html'
|
||||||
},
|
},
|
||||||
goNext() {
|
goNext() {
|
||||||
let that = this
|
let that = this
|
||||||
if (this.isSign && this.isReSign == '0') {
|
// if (this.isSign && this.isReSign == '0') {
|
||||||
let data = {
|
let data = {
|
||||||
// userModel: {
|
// userModel: {
|
||||||
// mobile: '13000000000'
|
// mobile: '13000000000'
|
||||||
// },
|
// },
|
||||||
baseEncryp: that.base64,
|
baseEncryp: that.base64,
|
||||||
otherBaseEncryp: that.base64D,
|
otherBaseEncryp: that.base64D,
|
||||||
// baseEncryp: '123456',
|
// baseEncryp: '123456',
|
||||||
ebizAgreementDto: that.appntSign
|
ebizAgreementDto: that.appntSign
|
||||||
}
|
|
||||||
that.$toast.loading({
|
|
||||||
duration: 0, // 持续展示 toast
|
|
||||||
forbidClick: true, // 禁用背景点击
|
|
||||||
loadingType: 'spinner',
|
|
||||||
message: '加载中……'
|
|
||||||
})
|
|
||||||
signAgreement(data).then(res => {
|
|
||||||
that.$toast.clear()
|
|
||||||
if (res.result == '0') {
|
|
||||||
this.$jump({
|
|
||||||
flag: 'h5',
|
|
||||||
extra: {
|
|
||||||
url: location.origin + `/#/agentEenter/LetterOfKnow`
|
|
||||||
},
|
|
||||||
routerInfo: {
|
|
||||||
path: `/agentEenter/LetterOfKnow`
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
this.$toast(res.resultMessage)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
if (this.isReSign == '1') {
|
|
||||||
// 您已签名
|
|
||||||
this.$toast('您已签名')
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
that.$toast.loading({
|
||||||
|
duration: 0, // 持续展示 toast
|
||||||
|
forbidClick: true, // 禁用背景点击
|
||||||
|
loadingType: 'spinner',
|
||||||
|
message: '加载中……'
|
||||||
|
})
|
||||||
|
signAgreement(data).then(res => {
|
||||||
|
that.$toast.clear()
|
||||||
|
if (res.result == '0') {
|
||||||
|
let path = !this.isWeixin ? `/agentEenter/${that.nextPagePath}?code=${that.code}` : '/agentEenter/signContract'
|
||||||
|
this.$jump({
|
||||||
|
flag: 'h5',
|
||||||
|
extra: {
|
||||||
|
url: location.origin + '/#' + path
|
||||||
|
},
|
||||||
|
routerInfo: {
|
||||||
|
path: path
|
||||||
|
}
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
// }
|
||||||
|
// else {
|
||||||
|
// if (this.isReSign == '1') {
|
||||||
|
// // 您已签名
|
||||||
|
// this.$toast('您已签名')
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
// this.$jump({
|
// this.$jump({
|
||||||
// flag: 'h5',
|
// flag: 'h5',
|
||||||
|
|||||||
Reference in New Issue
Block a user