PDF 优化
This commit is contained in:
parent
7934c43ecd
commit
d3a2ea6340
|
|
@ -153,30 +153,32 @@ export default {
|
||||||
// 拍照录入
|
// 拍照录入
|
||||||
openPhotograph() {
|
openPhotograph() {
|
||||||
this.isHide = true
|
this.isHide = true
|
||||||
uni.chooseImage({
|
setTimeout(() => {
|
||||||
count: 1,
|
uni.chooseImage({
|
||||||
sizeType: ['compressed'],
|
count: 1,
|
||||||
sourceType: ['camera'],
|
sizeType: ['compressed'],
|
||||||
success: res => {
|
sourceType: ['camera'],
|
||||||
let url = ''
|
success: res => {
|
||||||
console.log('🚀 ~ res-拍照:', res)
|
let url = ''
|
||||||
this.imgToBase64(res.tempFilePaths[0]).then(base64 => {
|
console.log('🚀 ~ res-拍照:', res)
|
||||||
url = base64
|
this.imgToBase64(res.tempFilePaths[0]).then(base64 => {
|
||||||
console.log('🚀 ~ this.imgToBase64 ~ base64:', url)
|
url = base64
|
||||||
this.getFaceRecognition({ userId: uni.getStorageSync('userId'), img: url })
|
console.log('🚀 ~ this.imgToBase64 ~ base64:', url)
|
||||||
})
|
this.getFaceRecognition({ userId: uni.getStorageSync('userId'), img: url })
|
||||||
},
|
})
|
||||||
fail(err) {
|
},
|
||||||
console.log('🚀 ~ openFaceScan ~ 人脸识别失败', err)
|
fail(err) {
|
||||||
uni.showToast({
|
console.log('🚀 ~ openFaceScan ~ 人脸识别失败', err)
|
||||||
title: '人脸识别失败',
|
uni.showToast({
|
||||||
icon: ''
|
title: '人脸识别失败',
|
||||||
})
|
icon: ''
|
||||||
setTimeout(() => {
|
})
|
||||||
this.updStudyDuration()
|
setTimeout(() => {
|
||||||
}, 1000)
|
this.updStudyDuration()
|
||||||
}
|
}, 1000)
|
||||||
})
|
}
|
||||||
|
})
|
||||||
|
}, 500)
|
||||||
},
|
},
|
||||||
imgToBase64(data) {
|
imgToBase64(data) {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue