识别身份证

This commit is contained in:
老叶
2022-06-07 16:32:28 +08:00
parent f45fc5893f
commit 22d52a2da7
7 changed files with 55 additions and 18 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
const env = "d";
const env = "p";
const version = 1,
+3 -1
View File
@@ -118,7 +118,9 @@ Page({
})
//上传图片-保存店铺海报 - 作废
// wx.showLoading();
// wx.showLoading({
// title: '上传中',
// })
// wx.uploadFile({
// url:_.config.api.upImg,
// filePath:res.tempFilePaths[0],
+3 -1
View File
@@ -340,7 +340,9 @@ Page({
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
+21 -7
View File
@@ -214,7 +214,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -265,7 +267,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -316,7 +320,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -367,7 +373,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -409,7 +417,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -451,7 +461,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res1) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
let ins_img=that.data.ins_img
for (let i = 0; i < res1.tempFilePaths.length; i++) {
//上传图片
@@ -513,7 +525,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res1) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
let other_img=that.data.other_img
for (let i = 0; i < res1.tempFilePaths.length; i++) {
//上传图片
+6 -2
View File
@@ -139,7 +139,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -174,7 +176,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '上传中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
+7 -2
View File
@@ -246,7 +246,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '识别中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -256,11 +258,11 @@ Page({
},
success: (resp) => {
resp.data = JSON.parse(resp.data);
wx.hideLoading();
if (resp.data.code == 200) {
let params = {};
params['img'] = resp.data.data.url;
_.apiQuery.getAppIdcardInfo(params).then(res2 => {
wx.hideLoading();
that.setData({
owner_cardid:res2.data.IdNum,
owner_name:res2.data.Name,
@@ -269,6 +271,9 @@ Page({
})
}
},
fail: res => {
wx.hideLoading();
}
})
},
fail: res => {
+14 -4
View File
@@ -1180,7 +1180,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '识别中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -1190,11 +1192,11 @@ Page({
},
success: (resp) => {
resp.data = JSON.parse(resp.data);
wx.hideLoading();
if (resp.data.code == 200) {
let params = {};
params['img'] = resp.data.data.url;
_.apiQuery.getAppIdcardInfo(params).then(res2 => {
wx.hideLoading();
that.setData({
cardid:res2.data.IdNum,
name:res2.data.Name,
@@ -1203,6 +1205,9 @@ Page({
})
}
},
fail: res => {
wx.hideLoading();
}
})
},
fail: res => {
@@ -1222,7 +1227,9 @@ Page({
sizeType: ['original', 'compressed'], // 可以指定是原图还是压缩图,默认二者都有
sourceType: ['album', 'camera'], // 可以指定来源是相册还是相机,默认二者都有
success(res) {
wx.showLoading();
wx.showLoading({
title: '识别中',
})
wx.uploadFile({
url:_.config.api.upImg,
filePath:res.tempFilePaths[0],
@@ -1232,11 +1239,11 @@ Page({
},
success: (resp) => {
resp.data = JSON.parse(resp.data);
wx.hideLoading();
if (resp.data.code == 200) {
let params = {};
params['img'] = resp.data.data.url;
_.apiQuery.getAppIdcardInfo(params).then(res2 => {
wx.hideLoading();
that.setData({
owner_cardid:res2.data.IdNum,
owner_name:res2.data.Name,
@@ -1245,6 +1252,9 @@ Page({
})
}
},
fail: res => {
wx.hideLoading();
}
})
},
fail: res => {