|
@@ -136,40 +136,40 @@ export default {
|
|
|
this.isUploading = false
|
|
|
return
|
|
|
} else {
|
|
|
- if (this.commitment_electr_signature) {
|
|
|
- uni.request({
|
|
|
- url: this.commitment_electr_signature, //临时路径
|
|
|
- responseType: 'arraybuffer', //设置返回的数据格式为arraybuffer
|
|
|
- success: res => {
|
|
|
- const base64 = "data:image/jpeg;base64," + uni.arrayBufferToBase64(res.data)
|
|
|
- console.log('sfs签名转成base64', base64)
|
|
|
- this.baseAddress = base64
|
|
|
- // return
|
|
|
- this.$http({
|
|
|
- url: '/apply/signReport',
|
|
|
- method: 'post',
|
|
|
- data: {
|
|
|
- signImageStr: this.baseAddress,
|
|
|
- subscribeId: this.subscribeId,
|
|
|
- }
|
|
|
- }).then((res) => {
|
|
|
- console.log('res', res)
|
|
|
- if (res.data.data == 200) {
|
|
|
- this.$u.toast('签署成功')
|
|
|
- uni.navigateBack()
|
|
|
- } else {
|
|
|
- this.$u.toast(res.data.msg)
|
|
|
- }
|
|
|
- }).catch((err) => {
|
|
|
- this.$u.toast('签署失败,请重新签署')
|
|
|
- })
|
|
|
- },
|
|
|
- fail: err => {
|
|
|
- console.log(err)
|
|
|
- }
|
|
|
- })
|
|
|
- this.isUploading = false
|
|
|
- }
|
|
|
+ uni.request({
|
|
|
+ url: this.commitment_electr_signature, //临时路径
|
|
|
+ responseType: 'arraybuffer', //设置返回的数据格式为arraybuffer
|
|
|
+ success: res => {
|
|
|
+ const base64 = "data:image/jpeg;base64," + uni.arrayBufferToBase64(res.data)
|
|
|
+ console.log('sfs签名转成base64', base64)
|
|
|
+ this.baseAddress = base64
|
|
|
+ this.$http({
|
|
|
+ url: '/apply/signReport',
|
|
|
+ method: 'post',
|
|
|
+ data: {
|
|
|
+ signImageStr: this.baseAddress,
|
|
|
+ subscribeId: this.subscribeId,
|
|
|
+ }
|
|
|
+ }).then((res) => {
|
|
|
+ console.log('res', res)
|
|
|
+ if (res.data.data == 200) {
|
|
|
+ this.$u.toast('签署成功')
|
|
|
+ uni.navigateBack()
|
|
|
+ } else {
|
|
|
+ this.$u.toast(res.data.msg)
|
|
|
+ }
|
|
|
+ this.isUploading = false
|
|
|
+ }).catch((err) => {
|
|
|
+ this.$u.toast('签署失败,请重新签署')
|
|
|
+ this.isUploading = false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ fail: err => {
|
|
|
+ console.log(err)
|
|
|
+ this.isUploading = false
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
}
|
|
|
},
|
|
|
},
|