Commit c97855ec authored by linxin's avatar linxin

add

parent 32c69236
...@@ -442,9 +442,10 @@ export default { ...@@ -442,9 +442,10 @@ export default {
let url = process.env.ocrPath + '/baidu/ocr/face' let url = process.env.ocrPath + '/baidu/ocr/face'
hlsUtil.baiduOcrFace(obj, url, function (res) { hlsUtil.baiduOcrFace(obj, url, function (res) {
hlsPopup.hideLoading() hlsPopup.hideLoading()
if (res.success) { if (res.success && res.result.result.score) {
vm.save_picture(vm.faceListUpload) vm.save_picture(vm.faceListUpload)
let identifyScore = res.result.result.score.toFixed(0) let identifyScore = res.result.result.score.toFixed(0)
if (identifyScore >= 50) {
hlsPopup.showPopup({ hlsPopup.showPopup({
title: '提示', title: '提示',
content: `识别分数为${identifyScore},请进行活体检测`, content: `识别分数为${identifyScore},请进行活体检测`,
...@@ -456,6 +457,9 @@ export default { ...@@ -456,6 +457,9 @@ export default {
} else { } else {
hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人') hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人')
} }
} else {
hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人')
}
}) })
}, },
goBodyCheck (confirm_id) { goBodyCheck (confirm_id) {
......
...@@ -701,9 +701,10 @@ export default { ...@@ -701,9 +701,10 @@ export default {
let url = process.env.ocrPath + '/baidu/ocr/face' let url = process.env.ocrPath + '/baidu/ocr/face'
hlsUtil.baiduOcrFace(obj, url, function (res) { hlsUtil.baiduOcrFace(obj, url, function (res) {
hlsPopup.hideLoading() hlsPopup.hideLoading()
if (res.success) { if (res.success && res.result.result.score) {
vm.save_picture(vm.faceListUpload) vm.save_picture(vm.faceListUpload)
let identifyScore = res.result.result.score.toFixed(0) let identifyScore = res.result.result.score.toFixed(0)
if (identifyScore > 50) {
hlsPopup.showPopup({ hlsPopup.showPopup({
title: '提示', title: '提示',
content: `识别分数为${identifyScore},请进行活体检测`, content: `识别分数为${identifyScore},请进行活体检测`,
...@@ -715,6 +716,9 @@ export default { ...@@ -715,6 +716,9 @@ export default {
} else { } else {
hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人') hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人')
} }
} else {
hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人')
}
}) })
/* vm.save_picture(vm.faceListUpload) /* vm.save_picture(vm.faceListUpload)
let identifyScore = 90 let identifyScore = 90
......
...@@ -519,9 +519,10 @@ export default { ...@@ -519,9 +519,10 @@ export default {
let url = process.env.ocrPath + '/baidu/ocr/face' let url = process.env.ocrPath + '/baidu/ocr/face'
vm.hlsUtil.baiduOcrFace(obj, url, function (res) { vm.hlsUtil.baiduOcrFace(obj, url, function (res) {
vm.hlsPopup.hideLoading() vm.hlsPopup.hideLoading()
if (res.success) { if (res.success && res.result.result.score) {
vm.save_picture(vm.faceListUpload) vm.save_picture(vm.faceListUpload)
let identifyScore = res.result.result.score.toFixed(0) let identifyScore = res.result.result.score.toFixed(0)
if (identifyScore >= 50) {
vm.hlsPopup.showPopup({ vm.hlsPopup.showPopup({
title: '提示', title: '提示',
content: `识别分数为${identifyScore},请进行活体检测`, content: `识别分数为${identifyScore},请进行活体检测`,
...@@ -533,6 +534,9 @@ export default { ...@@ -533,6 +534,9 @@ export default {
} else { } else {
vm.hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人') vm.hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人')
} }
} else {
vm.hlsPopup.showLongCenter('比对失败,请保证和绑定时是同一个人')
}
}) })
}, },
......
...@@ -59,7 +59,7 @@ export default { ...@@ -59,7 +59,7 @@ export default {
position: 'middle', position: 'middle',
}) */ }) */
} }
}, 60000) }, 120000)
}, },
/** /**
* 隐藏 * 隐藏
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment