diff --git a/pages/index/index.vue b/pages/index/index.vue
index 94d323e..8957d35 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -19,7 +19,7 @@
diff --git a/pages/subPack/autonym/autonym.vue b/pages/subPack/autonym/autonym.vue
index e4af97a..c78fbc2 100644
--- a/pages/subPack/autonym/autonym.vue
+++ b/pages/subPack/autonym/autonym.vue
@@ -56,13 +56,20 @@
return
}
- this.$api('authApply', this.form, res => {
- if(res.code == 200){
- uni.reLaunch({
- url: '/pages/index/index'
- })
- }
+ this.$store.commit('setAuthInfo', this.form)
+
+ uni.navigateTo({
+ url: '/pages/subPack/human/human?type=auth'
})
+
+ // 实名认证
+ // this.$api('authApply', this.form, res => {
+ // if(res.code == 200){
+ // uni.reLaunch({
+ // url: '/pages/index/index'
+ // })
+ // }
+ // })
},
}
}
diff --git a/pages/subPack/human/human.vue b/pages/subPack/human/human.vue
index c2750ec..f52c2a5 100644
--- a/pages/subPack/human/human.vue
+++ b/pages/subPack/human/human.vue
@@ -34,7 +34,7 @@
- {{ tipsText }}{{ tempImg }}
+ {{ tipsText }}
@@ -57,9 +57,17 @@
+
+ v-if="tipsText == '请拍照' && type == 'auth'">
+ 立即核验
+
+
+
+
{
+ this.form.image = ''
+ this.tempImg = ''
+ })
}
})
},
@@ -287,7 +305,39 @@
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
+ }
+
+ })
}
})
},
diff --git a/store/store.js b/store/store.js
index 99d486c..f50ebc6 100644
--- a/store/store.js
+++ b/store/store.js
@@ -11,6 +11,7 @@ const store = new Vuex.Store({
configList: [], //配置列表
userInfo : {}, //用户信息
teamList : [],//团队列表
+ authInfo : {},//实名认证信息
},
getters: {
@@ -112,6 +113,9 @@ const store = new Vuex.Store({
}
})
},
+ setAuthInfo(state, data){
+ state.authInfo = data
+ },
},
actions: {},
})