|
@ -34,7 +34,7 @@ |
|
|
|
|
|
|
|
|
<view class="human-face-desc" |
|
|
<view class="human-face-desc" |
|
|
v-else> |
|
|
v-else> |
|
|
{{ tipsText }}{{ tempImg }} |
|
|
|
|
|
|
|
|
{{ tipsText }} |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<!-- 说明 --> |
|
|
<!-- 说明 --> |
|
@ -57,9 +57,17 @@ |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- 实名认证 --> |
|
|
<div class="btn" |
|
|
<div class="btn" |
|
|
@click="handleTakePhotoClick" |
|
|
@click="handleTakePhotoClick" |
|
|
v-if="tipsText == '请拍照'"> |
|
|
|
|
|
|
|
|
v-if="tipsText == '请拍照' && type == 'auth'"> |
|
|
|
|
|
立即核验 |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="btn" |
|
|
|
|
|
@click="handleTakePhotoClick" |
|
|
|
|
|
v-else-if="tipsText == '请拍照'"> |
|
|
<uv-upload |
|
|
<uv-upload |
|
|
multiple |
|
|
multiple |
|
|
:maxCount="1" |
|
|
:maxCount="1" |
|
@ -99,12 +107,17 @@ |
|
|
cameraEngine: null, // 相机引擎 |
|
|
cameraEngine: null, // 相机引擎 |
|
|
devicePosition: true, // 摄像头朝向 |
|
|
devicePosition: true, // 摄像头朝向 |
|
|
isAuthCamera: true, // 是否拥有相机权限 |
|
|
isAuthCamera: true, // 是否拥有相机权限 |
|
|
|
|
|
|
|
|
|
|
|
type : '', |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
computed: { |
|
|
computed: { |
|
|
...mapState(['teamList', 'userInfo']), |
|
|
|
|
|
|
|
|
...mapState(['teamList', 'userInfo', 'authInfo']), |
|
|
}, |
|
|
}, |
|
|
onLoad() { |
|
|
|
|
|
|
|
|
onLoad(args) { |
|
|
|
|
|
if(args.type){ |
|
|
|
|
|
this.type = args.type |
|
|
|
|
|
} |
|
|
this.initData() |
|
|
this.initData() |
|
|
}, |
|
|
}, |
|
|
onShow() { |
|
|
onShow() { |
|
@ -189,6 +202,11 @@ |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
setTimeout(uni.navigateBack, 1000, -1) |
|
|
setTimeout(uni.navigateBack, 1000, -1) |
|
|
|
|
|
}else{ |
|
|
|
|
|
this.$nextTick(() => { |
|
|
|
|
|
this.form.image = '' |
|
|
|
|
|
this.tempImg = '' |
|
|
|
|
|
}) |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
@ -287,7 +305,39 @@ |
|
|
tempImagePath |
|
|
tempImagePath |
|
|
}) => { |
|
|
}) => { |
|
|
this.tempImg = tempImagePath |
|
|
this.tempImg = tempImagePath |
|
|
console.log("=======tempImg:", this.tempImg) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 上传图片 |
|
|
|
|
|
this.$Oss.ossUpload(tempImagePath).then(url => { |
|
|
|
|
|
|
|
|
|
|
|
// 实名认证,上传人脸 |
|
|
|
|
|
if(this.type == 'auth'){ |
|
|
|
|
|
let form = { |
|
|
|
|
|
...this.authInfo, |
|
|
|
|
|
pic : url |
|
|
|
|
|
} |
|
|
|
|
|
this.$api('authApply', form, res => { |
|
|
|
|
|
if(res.code == 200){ |
|
|
|
|
|
setTimeout(uni.reLaunch, 1000, { |
|
|
|
|
|
url: '/pages/index/index' |
|
|
|
|
|
}) |
|
|
|
|
|
}else{ |
|
|
|
|
|
setTimeout(uni.navigateBack, 1000, -1) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
this.form.image = url |
|
|
|
|
|
if(this.form.lat){ |
|
|
|
|
|
this.submit() |
|
|
|
|
|
}else{ |
|
|
|
|
|
uni.showLoading({ |
|
|
|
|
|
title: '定位中...' |
|
|
|
|
|
}) |
|
|
|
|
|
this.isLocationSubmit = true |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
}) |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|