洛阳学员端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

71 lines
1.9 KiB

<template>
<view class="pageBgImg pad">
<view class="status_bar"></view>
<view class="" style="height: 100rpx;"></view>
<!-- <u-button @click="requestSingleFreshLocationFn">单次定位</u-button> -->
<u-button @click="getInitFaceVerifyFn">人脸核身</u-button>
<topInfo :carType="curObject.name" @changeSubject="changeSubject"></topInfo>
<subject1 v-if="curObject.id==1"></subject1>
<subject2 v-if="curObject.id==2"></subject2>
<subject3 v-if="curObject.id==3"></subject3>
<subject4 v-if="curObject.id==4"></subject4>
</view>
</template>
<script>
import topInfo from './comp/topInfo.vue'
import subject1 from './comp/subject1.vue'
import subject2 from './comp/subject2.vue'
import subject3 from './comp/subject3.vue'
import subject4 from './comp/subject4.vue'
// import { requestSingleFreshLocation } from '@/common/js/qqLatLng.js'
import { getInitFaceVerify } from '@/config/api.js'
export default {
components: { topInfo, subject1, subject2,subject3,subject4 },
data() {
return {
curObject: {
name: '科目一',
id: 1
}
}
},
onLoad() {
// #ifdef MP-WEIXIN
// initEid();
// #endif
// const verifyPlugin = uni.requireNativePlugin('AP-FaceDetectModule');
// var metaInfo = verifyPlugin.getMetaInfo();
// console.log('插件在?')
// console.log(verifyPlugin)
},
onShow() {
this.getInitFaceVerifyFn()
},
methods: {
// 切换科目
changeSubject(val) {
console.log(val)
this.curObject = val
},
async getInitFaceVerifyFn() {
const res = await getInitFaceVerify()
console.log('人脸token')
console.log(res)
},
async requestSingleFreshLocationFn() {
let lanLng = await requestSingleFreshLocation()
if(lanLng.sourceProvider=='fake') {
this.$u.toast('不能执行该操作,禁止使用虚拟定位')
}
console.log(lanLng)
console.log('lanlng')
}
}
}
</script>
<style scoped lang="scss">
</style>