Tang %!s(int64=4) %!d(string=hai) anos
pai
achega
b85729f797
Modificáronse 53 ficheiros con 1906 adicións e 192 borrados
  1. 6 39
      common/api.js
  2. 12 0
      common/httpList/face.js
  3. 13 0
      common/httpList/userInfo.js
  4. 13 5
      common/request.js
  5. 1 29
      package-lock.json
  6. 13 1
      pages.json
  7. 6 3
      pages/login/login.vue
  8. 22 0
      pages2/faceRecognition/face.vue
  9. 192 114
      pages2/wd/info.vue
  10. BIN=BIN
      static/banner.png
  11. BIN=BIN
      static/verify_mpsdk/images/hint-shibieNative.png
  12. BIN=BIN
      static/verify_mpsdk/images/ico-came.png
  13. BIN=BIN
      static/verify_mpsdk/images/ico-cameNative.png
  14. BIN=BIN
      static/verify_mpsdk/images/ico-suc.png
  15. BIN=BIN
      static/verify_mpsdk/images/ico-sucNative.png
  16. BIN=BIN
      static/verify_mpsdk/images/shibiebgNative.png
  17. 2 1
      store/index.js
  18. 0 0
      wxcomponents/verify_mpsdk/config.js
  19. BIN=BIN
      wxcomponents/verify_mpsdk/images/hint-shibieNative.png
  20. BIN=BIN
      wxcomponents/verify_mpsdk/images/ico-came.png
  21. BIN=BIN
      wxcomponents/verify_mpsdk/images/ico-cameNative.png
  22. BIN=BIN
      wxcomponents/verify_mpsdk/images/ico-suc.png
  23. BIN=BIN
      wxcomponents/verify_mpsdk/images/ico-sucNative.png
  24. BIN=BIN
      wxcomponents/verify_mpsdk/images/shibiebgNative.png
  25. 1219 0
      wxcomponents/verify_mpsdk/index/index.js
  26. 4 0
      wxcomponents/verify_mpsdk/index/index.json
  27. 42 0
      wxcomponents/verify_mpsdk/index/index.wxml
  28. 204 0
      wxcomponents/verify_mpsdk/index/index.wxss
  29. 0 0
      wxcomponents/verify_mpsdk/main.js
  30. 1 0
      wxcomponents/verify_mpsdk/templates/errorToast/errorToast.wxml
  31. 1 0
      wxcomponents/verify_mpsdk/templates/errorToast/errorToast.wxss
  32. 0 0
      wxcomponents/verify_mpsdk/templates/failpage/failpage.wxml
  33. 0 0
      wxcomponents/verify_mpsdk/templates/index/index.wxml
  34. 0 0
      wxcomponents/verify_mpsdk/templates/livingbody/livingbody.wxml
  35. 0 0
      wxcomponents/verify_mpsdk/templates/livingbody/livingbody.wxss
  36. 0 0
      wxcomponents/verify_mpsdk/templates/navTip/navTip.wxml
  37. 1 0
      wxcomponents/verify_mpsdk/templates/navTip/navTip.wxss
  38. 1 0
      wxcomponents/verify_mpsdk/templates/notice/notice.wxml
  39. 1 0
      wxcomponents/verify_mpsdk/templates/notice/notice.wxss
  40. 142 0
      wxcomponents/verify_mpsdk/templates/ocr/ocr.wxml
  41. 0 0
      wxcomponents/verify_mpsdk/templates/ocr/ocr.wxss
  42. 1 0
      wxcomponents/verify_mpsdk/templates/riskTip/riskTip.wxml
  43. 1 0
      wxcomponents/verify_mpsdk/templates/riskTip/riskTip.wxss
  44. 1 0
      wxcomponents/verify_mpsdk/templates/showAuthToast/showAuthToast.wxml
  45. 1 0
      wxcomponents/verify_mpsdk/templates/showAuthToast/showAuthToast.wxss
  46. 1 0
      wxcomponents/verify_mpsdk/templates/sms/sms.wxml
  47. 1 0
      wxcomponents/verify_mpsdk/templates/sms/sms.wxss
  48. 1 0
      wxcomponents/verify_mpsdk/templates/success/success.wxml
  49. 1 0
      wxcomponents/verify_mpsdk/templates/success/success.wxss
  50. 1 0
      wxcomponents/verify_mpsdk/utils/extend.js
  51. 1 0
      wxcomponents/verify_mpsdk/utils/regenerator-runtime/path.js
  52. 0 0
      wxcomponents/verify_mpsdk/utils/regenerator-runtime/runtime.js
  53. 0 0
      wxcomponents/verify_mpsdk/utils/util.js

+ 6 - 39
common/api.js

@@ -1,51 +1,18 @@
-// const http = (options) => {
-// 	return new Promise((resolve, reject) => {
-// 	let realmName = options.prefix == false?'':'http://127.0.0.1:8088/';  
-// 		uni.showLoading({
-// 			title: '加载中....',
-// 			mask: true
-// 		})
-// 		uni.request({
-// 			method: options.method,
-// 			url: realmName+options.url,
-// 			data: options.data,
-// 			header: options.header,
-// 			success: (res) => {
-// 				resolve(res.data)
-// 			},
-// 			fail: (err) => {
-// 				reject(err.data)
-// 				// let code = err.data.code;
-// 				// switch (code) {
-// 				// 	case 1000:
-// 				// 		break;
-// 				// }
-// 			},
-// 			complete: () => {
-// 				uni.hideLoading();
-// 			}
-// 		})	
-// 	})
-// }
-
-// export default http
 import login from './httpList/login.js'
 import polyvVideo from './httpList/polyvVideo.js'
 import course from './httpList/course.js'
-<<<<<<< HEAD
 import oss from './httpList/oss.js'
-=======
 import bank from './httpList/bank.js'
 import note from './httpList/note.js'
->>>>>>> 19adad0d3b563f01c63edb1267920e3c4ea473bf
+import face from './httpList/face.js'
+import userInfo from './httpList/userInfo.js'
 export default {
 	...login,
 	...polyvVideo,
 	...course,
-<<<<<<< HEAD
-	...oss
-=======
+	...oss,
 	...bank,
-	...note
->>>>>>> 19adad0d3b563f01c63edb1267920e3c4ea473bf
+	...note,
+	...face,
+	...userInfo
 }

+ 12 - 0
common/httpList/face.js

@@ -0,0 +1,12 @@
+import {
+	myRequest
+} from '../request.js'
+export default {
+	//人脸核身
+	faceBizToken() {
+		return myRequest({
+			url: '/face/certification/BizToken',
+			method: 'get',
+		})
+	},
+}

+ 13 - 0
common/httpList/userInfo.js

@@ -0,0 +1,13 @@
+import {
+	myRequest
+} from '../request.js'
+export default {
+	//修改客户端用户
+	appuserInfo(data) {
+		return myRequest({
+			url: '/app/user/edit',
+			method: 'post',
+			data: data,
+		})
+	},
+}

+ 13 - 5
common/request.js

@@ -1,4 +1,4 @@
-const BASE_URL = 'http://127.0.0.1:8088'
+const BASE_URL = 'http://192.168.0.222:8088'
 import store from '@/store/index.js'
 import api from './api.js'
 var num = 1
@@ -25,7 +25,8 @@ export const myRequest = (options) => {
 			},
 			fail: (err) => {
 				uni.showToast({
-					title: "请求接口失败"
+					title: "请求接口失败",
+					icon: 'none'
 				})
 				reject(JSON.stringify(err))
 			}
@@ -43,9 +44,16 @@ export const myRequest = (options) => {
 		const res = await myRequest(datas)
 		if (res.data.code === 200) {
 			uni.setStorageSync('token', res.data.data.token)
-			let onset = await myRequest(response)
-			console.log(datas)
-			return onset
+			var userInfo = {
+				url: '/getInfo',
+				method: 'get',
+			}
+			const resUser = await myRequest(userInfo)
+			if (resUser.data.code === 200) {
+				uni.setStorageSync('userInfo', res.data.data)
+				let onset = await myRequest(response)
+				return onset
+			}
 		} else {
 			uni.removeStorageSync('union_id')
 			uni.showToast({

+ 1 - 29
package-lock.json

@@ -1,36 +1,8 @@
 {
   "name": "zz-applet",
   "version": "1.0.0",
-  "lockfileVersion": 2,
+  "lockfileVersion": 1,
   "requires": true,
-  "packages": {
-    "": {
-      "name": "zz-applet",
-      "version": "1.0.0",
-      "license": "ISC",
-      "dependencies": {
-        "jweixin-module": "^1.6.0",
-        "tki-qrcode": "^0.1.6",
-        "uview-ui": "^1.8.3"
-      },
-      "devDependencies": {}
-    },
-    "node_modules/jweixin-module": {
-      "version": "1.6.0",
-      "resolved": "https://registry.npmjs.org/jweixin-module/-/jweixin-module-1.6.0.tgz",
-      "integrity": "sha512-dGk9cf+ipipHmtzYmKZs5B2toX+p4hLyllGLF6xuC8t+B05oYxd8fYoaRz0T30U2n3RUv8a4iwvjhA+OcYz52w=="
-    },
-    "node_modules/tki-qrcode": {
-      "version": "0.1.6",
-      "resolved": "https://registry.npmjs.org/tki-qrcode/-/tki-qrcode-0.1.6.tgz",
-      "integrity": "sha512-EnnlS8psowC7PsW3MDYcxvJYkuklX3WAZ/BYanR4TdBHTu74GfjTBX8Y16REP+AeDENiVtBPh4jtTRL2P736hQ=="
-    },
-    "node_modules/uview-ui": {
-      "version": "1.8.3",
-      "resolved": "https://registry.npmjs.org/uview-ui/-/uview-ui-1.8.3.tgz",
-      "integrity": "sha512-DqKc+qRrOZLPcyfWv4b0HspSS9n1Cd6BbgKiYEv9rjTAnWoqJV7rXsvWqZdr5iKGP5EMNbNS741GLNw4sIHbpw=="
-    }
-  },
   "dependencies": {
     "jweixin-module": {
       "version": "1.6.0",

+ 13 - 1
pages.json

@@ -215,6 +215,15 @@
 					"bounce": "none"
 				}
 			}
+		},{
+			"path": "faceRecognition/face",
+			"style": {
+				"navigationBarTitleText": "人脸识别",
+				"app-plus": {
+					"titleNView": false, //禁用原生导航栏 
+					"bounce": "none"
+				}
+			}
 		}],
 		"plugins": {
 			"polyv-player": {
@@ -227,7 +236,10 @@
 		"navigationBarTextStyle": "black",
 		"navigationBarTitleText": "WeChat",
 		"navigationBarBackgroundColor": "#F8F8F8",
-		"backgroundColor": "#F8F8F8"
+		"backgroundColor": "#F8F8F8",
+		"usingComponents": {
+		  "verify-mpsdk": "/wxcomponents/verify_mpsdk/index/index"
+		}
 	},
 	"tabBar": {
 		"color": "#636A75",

+ 6 - 3
pages/login/login.vue

@@ -26,17 +26,20 @@ export default {
 				};
 				that.$api.login(datas).then(
 					res => {
-						console.log(res.data.code,666)
 						if (res.data.code == 200) {
+							that.$api.getInfo().then(resdata => {
+								that.$store.state.userInfo = resdata.data.data;
+							});
 							uni.setStorageSync('union_id', res.data.data.union_id);
 							uni.setStorageSync('token', res.data.data.token);
+
 							uni.navigateBack();
-						}else{
+						} else {
 							uni.showModal({
 								title: '提示',
 								content: res.data.msg,
 								showCancel: false
-							}); 
+							});
 						}
 					},
 					err => {

+ 22 - 0
pages2/faceRecognition/face.vue

@@ -0,0 +1,22 @@
+<template>
+	<view class="face"><verify-mpsdk ref="verifyMpsdk"></verify-mpsdk></view>
+</template>
+
+<script>
+export default {
+	data() {
+		return {};
+	},
+	onLoad(i) {
+		this.$refs.verifyMpsdk.onLoad(i);
+	},
+	onShow() {},
+	methods: {}
+};
+</script>
+
+<style scope>
+page {
+	background: #ffffff;
+}
+</style>

+ 192 - 114
pages2/wd/info.vue

@@ -1,52 +1,54 @@
 <template>
 	<view style="padding: 30rpx;">
-		<view style="position: relative;">
+		<view style="display: flex;align-items: center;justify-content: space-between;">
 			<view class="tip">
 				请填写真实信息,以便我们后续为您提供完善的
 				<br />
 				个人职业成长定制服务!
 			</view>
-			<view class="btn" style="position: absolute;right: 20rpx;top: 0;">编辑</view>
+			<view style="display: flex;align-items: center;">
+				<view class="btn" v-if="form.certified === 0" style="margin-right: 5rpx;" @click="certification">认证</view> 
+				<view class="btn">编辑</view>
+			</view>
 		</view>
 		<view class="form">
 			<u-form :model="form" ref="uForm">
-				<u-form-item label="姓名"><u-input v-model="form.name" /></u-form-item>
-				<u-form-item label="手机号码" :label-width="auto"><u-input v-model="form.tel" /></u-form-item>
-				<u-form-item label="身份证号" :label-width="auto"><u-input v-model="form.id" /></u-form-item>
-				<u-form-item label="性别">
-					<picker @change="bindPickerChangeSex" :value="index_sex" :range="array_sex">
-						<view class="picker">{{ array_sex[index_sex] }}</view>
+				<u-form-item label="姓名" prop="realname"><u-input v-model="form.realname" /></u-form-item>
+				<u-form-item label="手机号码" prop="telphone" :label-width="auto"><u-input v-model="form.telphone" /></u-form-item>
+				<u-form-item label="身份证号" prop="idCard" :label-width="auto"><u-input v-model="form.idCard" /></u-form-item>
+				<u-form-item label="性别" prop="sex">
+					<picker @change="bindPickerChangeSex" :value="form.sex" :range="array_sex">
+						<view class="picker">{{ array_sex[form.sex] }}</view>
 					</picker>
 				</u-form-item>
-				<u-form-item label="邮箱" :label-width="auto"><u-input v-model="form.email" /></u-form-item>
-				<u-form-item label="出生日期" prop="birth" :label-width="auto">
-					<picker mode="date" :value="form.date" @change="bindDateChange">
-						<view class="picker">{{ form.date }}</view>
+				<u-form-item label="邮箱" prop="email" :label-width="auto"><u-input v-model="form.email" /></u-form-item>
+				<u-form-item label="出生日期" prop="userBirth" :label-width="auto">
+					<picker mode="date" :value="form.userBirth" @change="bindDateChange">
+						<view class="picker">{{ form.userBirth }}</view>
 					</picker>
 				</u-form-item>
-				<u-form-item label="身份"></u-form-item>
-				<u-form-item label="户籍" prop="xz">
+				<!-- <u-form-item label="身份"></u-form-item> -->
+				<u-form-item label="户籍">
 					<pick-regions :defaultRegion="defaultRegionCode" @getRegion="handleGetRegion">
-						<view class="picker">{{ form.region1[0] }} {{ form.region1[1] }} {{ form.region1[2] }}</view>
+						<view class="picker">{{ form.houseProvince }} {{ form.houseCity }} {{ form.houseDistrict }}</view>
 					</pick-regions>
 				</u-form-item>
-				<u-form-item label="婚姻状况" :label-width="auto">
-					<picker @change="bindPickerChangeMarry" :value="index_marry" :range="array_marry">
-						<view class="picker">{{ array_marry[index_marry] }}</view>
+				<u-form-item label="婚姻状况" prop="marry" :label-width="auto">
+					<picker @change="bindPickerChangeMarry" :value="form.marry" :range="array_marry">
+						<view class="picker">{{ array_marry[form.marry] }}</view>
 					</picker>
 				</u-form-item>
-				<u-form-item label="所在城市" prop="xz" :label-width="auto">
+				<u-form-item label="所在城市" :label-width="auto">
 					<pick-regions :defaultRegion="defaultRegionCode" @getRegion="handleGetRegion2">
-						<view class="picker">{{ form.region2[0] }} {{ form.region2[1] }} {{ form.region2[2] }}</view>
+						<view class="picker">{{ form.province }} {{ form.city }} {{ form.district }}</view>
 					</pick-regions>
 				</u-form-item>
-				<u-form-item label="政治面貌" :label-width="auto">
-					<picker @change="bindPickerChangePolitic" :value="index_politic" :range="array_politic">
-						<view class="picker">{{ array_politic[index_politic] }}</view>
+				<u-form-item label="政治面貌" :label-width="auto" prop="politic">
+					<picker @change="bindPickerChangePolitic" :value="form.politic" :range="array_politic">
+						<view class="picker">{{ array_politic[form.politic] }}</view>
 					</picker>
 				</u-form-item>
-				<u-form-item label="一寸头像" :label-width="auto" label-position="top">
-<<<<<<< HEAD
+				<u-form-item label="一寸头像" prop="fileList" :label-width="auto" label-position="top">
 					<u-upload
 						:auto-upload="false"
 						custom-btn="true"
@@ -59,51 +61,13 @@
 						@on-list-change="changePhotoListHeader"
 					>
 						<template v-slot:addBtn>
-=======
-					<u-upload :auto-upload="false" custom-btn="true" :action="action"  :file-list="fileList" width="120" height ="169" size-type="['compressed']" max-count="1">
-						<template v-slot:addBtn >
->>>>>>> 19adad0d3b563f01c63edb1267920e3c4ea473bf
-							<image src="/static/info_1.png" style="width: 120rpx; height: 169rpx;"></image>
-						</template>
-					</u-upload>
-				</u-form-item>
-				<u-form-item label="身份证人像面" :label-width="auto" label-position="top">
-					<u-upload
-						:auto-upload="false"
-						custom-btn="true"
-						:action="action"
-						:file-list="fileList1"
-						width="120"
-						height="82"
-						size-type="['compressed']"
-						max-count="1"
-						@on-list-change="changePhotoListZ"
-					>
-						<template v-slot:addBtn>
-							<image src="/static/info_2.png" style="width: 120rpx; height: 82rpx;"></image>
-						</template>
-					</u-upload>
-				</u-form-item>
-				<u-form-item label="身份证国徽面" :label-width="auto" label-position="top">
-					<u-upload
-						:auto-upload="false"
-						custom-btn="true"
-						:action="action"
-						:file-list="fileList2"
-						width="120"
-						height="82"
-						size-type="['compressed']"
-						max-count="1"
-						@on-list-change="changePhotoListF"
-					>
-						<template v-slot:addBtn>
-							<image src="/static/info_3.png" style="width: 120rpx; height: 82rpx;"></image>
+							<image :src="form.oneInchPhotos ? $method.splitImgHost('/' + form.oneInchPhotos) : '/static/info_1.png'" style="width: 120rpx; height: 169rpx;"></image>
 						</template>
 					</u-upload>
 				</u-form-item>
 			</u-form>
 		</view>
-		<u-button type="success" @click="submitForm">提交</u-button>
+		<u-button type="success" @click="resultForm">提交</u-button>
 	</view>
 </template>
 
@@ -111,109 +75,220 @@
 export default {
 	data() {
 		return {
+			BizToken: '',
 			action: '33',
 			fileList: [],
-			fileList1: [],
-			fileList2: [],
 			defaultRegionCode: '440112',
 			form: {
-				date: '1990-01-01',
-				region1: ['广东省', '广州市', '天河区'],
-				region2: ['广东省', '广州市', '天河区']
+				realname: '',
+				telphone: '',
+				idCard: '',
+				email: '',
+				sex: 0,
+				marry: 0,
+				politic: 0,
+				userBirth: '1990-01-01',
+				houseProvince: '', //户籍省
+				houseCity: '', //户籍市
+				houseDistrict: '', //户籍区
+				province: '', //城市省
+				city: '', //市
+				district: '', //区
+				// region1: ['广东省', '广州市', '天河区'],
+				// region2: ['广东省', '广州市', '天河区'],
+				oneInchPhotos: ''
 			},
-			index_sex: 0,
+			// index_sex: 0,
 			array_sex: ['男', '女'],
-			index_marry: 0,
 			array_marry: ['未婚', '已婚'],
-			index_politic: 0,
-			array_politic: ['群众', '团员', '党员']
+			array_politic: ['群众', '团员', '党员'],
+			rules: {
+				realname: [
+					{
+						required: true,
+						message: '请输入姓名',
+						trigger: ['blur', 'change']
+					}
+				],
+				telphone: [
+					{
+						required: true,
+						message: '请输入手机号码',
+						// 可以单个或者同时写两个触发验证方式
+						trigger: 'blur'
+					}
+				],
+				idCard: [
+					{
+						required: true,
+						message: '请输入身份证号码',
+						// 可以单个或者同时写两个触发验证方式
+						trigger: 'blur'
+					}
+				]
+			}
 		};
 	},
-	onLoad(option) {},
-	onShow() {},
+	onReady() {
+		this.$refs.uForm.setRules(this.rules);
+	},
+	onLoad(option) {
+		const Verify = require('@/wxcomponents/verify_mpsdk/main.js');
+		Verify.init();
+		this.getUserInfos();
+	},
+	mounted() {
+		console.log(this.$method.splitImgHost('/' + this.form.oneInchPhotos));
+	},
 	methods: {
+		getUserInfos() {
+			this.$api.getInfo().then(res => {
+				this.form = res.data.data;
+			});
+		},
 		changePhotoListHeader(lists, name) {
 			this.fileList = lists;
 		},
-		changePhotoListZ(lists, name) {
-			this.fileList1 = lists;
+		resultForm() {
+			this.$refs.uForm.validate(valid => {
+				if (valid) {
+					this.submitForm();
+				} else {
+					console.log('验证失败');
+				}
+			});
 		},
-		changePhotoListF(lists, name) {
-			this.fileList2 = lists;
+		async certification() {
+			var self = this;
+			const faceBiz = await self.$api.faceBizToken();
+			self.BizToken = faceBiz.data.data.bizToken;
+			wx.startVerify({
+				data: {
+					token: self.BizToken
+				},
+				success: result => {
+					setTimeout(() => {
+						self.getUserInfos()
+					}, 500);
+				},
+				fail: err => {
+					setTimeout(() => {
+						uni.showModal({
+							title: '提示',
+							content: err,
+							showCancel: false
+						});
+					}, 500);
+				}
+			});
 		},
 		async submitForm() {
-			
-			console.log(this.form)
-			const file1 = await this.uploadFile(this.fileList, 0);
-			// const file2 = await this.uploadFile(this.fileList1, 1);
-			// const file3 = await this.uploadFile(this.fileList2, 1);
+			var self = this;
+			if (this.fileList.length > 0) {
+				const waitUpload = await this.uploadFile(this.fileList, 0);
+			}
+			var data = {
+				userId: this.form.userId,
+				email: this.form.email,
+				houseProvince: this.form.houseProvince, //户籍省份
+				idCard: this.form.idCard,
+				houseCity: this.form.houseCity,
+				houseDistrict: this.form.houseDistrict,
+				province: this.form.province, //城市省份
+				city: this.form.city, //城市
+				district: this.form.district, //区
+				realname: this.form.realname, //姓名
+				sex: this.form.sex, //性别
+				telphone: this.form.telphone, //手机号
+				userBirth: this.form.userBirth, //出生日期
+				marry: this.form.marry, //结婚状态
+				politic: this.form.politic, //政治面貌
+				oneInchPhotos: this.form.oneInchPhotos //一寸照
+			};
+			this.$api.appuserInfo(data).then(res => {
+				if (res.data.code === 200) {
+					uni.showToast({
+						title: '提交成功',
+						icon: 'none'
+					});
+					self.getUserInfos();
+				}
+			});
 		},
 		uploadFile(options, int) {
-			var self = this;
 			return new Promise((resolve, reject) => {
+				var self = this;
 				var data = {
 					imageStatus: int
 				};
 				this.$api.aliyunpolicy(data).then(res => {
 					var ossToken = res.data.data.resultContent;
-					console.log(ossToken)
 					uni.uploadFile({
 						url: ossToken.host,
 						name: 'file',
 						filePath: options[0].file.path,
 						fileType: 'image',
 						header: {
-							AuthorizationToken: 'WX ' + this.$store.state.token
-						}, 
+							AuthorizationToken: 'WX ' + self.$store.state.token
+						},
 						formData: {
 							key: ossToken.dir,
 							OSSAccessKeyId: ossToken.accessid,
 							policy: ossToken.policy,
 							Signature: ossToken.signature,
 							callback: ossToken.callback,
-							success_action_status: 200,
+							success_action_status: 200
 						},
-						success: (result)=>{
-							console.log(result);
-							resolve()
+						success: result => {
+							if (result.statusCode === 200) {
+								self.form.oneInchPhotos = ossToken.dir;
+								resolve();
+							} else {
+								uni.showToast({
+									title: '一寸头像上传失败',
+									icon: 'none'
+								});
+								return;
+							}
 						},
-						fail: (error)=>{
-							console.log(error)
+						fail: error => {
+							uni.showToast({
+								title: '上传接口报错',
+								icon: 'none'
+							});
+							return;
 						}
 					});
 				});
-				resolve();
 			});
 		},
 		bindPickerChangeSex(e) {
-			this.index_sex = e.detail.value;
+			this.form.sex = e.detail.value;
 		},
 		bindPickerChangePolitic(e) {
-			this.index_politic = e.detail.value;
+			this.form.politic = e.detail.value;
 		},
 		bindPickerChangeMarry(e) {
-			this.index_marry = e.detail.value;
+			this.form.marry = e.detail.value;
 		},
+		//城市
 		handleGetRegion2(region) {
-			let array = [];
-			array.push(region[0].name);
-			array.push(region[1].name);
-			array.push(region[2].name);
-			this.form.region2 = array;
+			this.form.province = region[0].name;
+			this.form.city = region[1].name;
+			this.form.district = region[2].name;
 		},
-		// 获取选择的地区
+		// 籍贯获取选择的地区
 		handleGetRegion(region) {
-			let array = [];
-			array.push(region[0].name);
-			array.push(region[1].name);
-			array.push(region[2].name);
-			this.form.region1 = array;
+			this.form.houseProvince = region[0].name;
+			this.form.houseCity = region[1].name;
+			this.form.houseDistrict = region[2].name;
 		},
 		bindDateChange(e) {
-			this.form.date = e.detail.value;
-			var year = this.date.substr(0, 4);
-			var month = this.date.substr(5, 2);
-			var day = this.date.substr(8, 2);
+			console.log(e.detail.value);
+			this.form.userBirth = e.detail.value;
+			// var year = this.form.userBirth.substr(0, 4);
+			// var month = this.userBirth.substr(5, 2);
+			// var day = this.userBirth.substr(8, 2);
 		},
 		actionSheetCallback(index) {
 			uni.hideKeyboard();
@@ -224,6 +299,9 @@ export default {
 </script>
 
 <style scope>
+.u-form-item__message.data-v-5e7216f1 {
+	padding: 0px !important;
+}
 .picker {
 	text-align: right;
 }

BIN=BIN
static/banner.png


BIN=BIN
static/verify_mpsdk/images/hint-shibieNative.png


BIN=BIN
static/verify_mpsdk/images/ico-came.png


BIN=BIN
static/verify_mpsdk/images/ico-cameNative.png


BIN=BIN
static/verify_mpsdk/images/ico-suc.png


BIN=BIN
static/verify_mpsdk/images/ico-sucNative.png


BIN=BIN
static/verify_mpsdk/images/shibiebgNative.png


+ 2 - 1
store/index.js

@@ -7,7 +7,8 @@ const store = new Vuex.Store({
         login: true,  
         token: '',  
         avatarUrl: '',  
-        userName: ''  
+        userName: '',
+		userInfo:{}
     },  
     mutations: {  
         login(state, provider) {  

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/config.js


BIN=BIN
wxcomponents/verify_mpsdk/images/hint-shibieNative.png


BIN=BIN
wxcomponents/verify_mpsdk/images/ico-came.png


BIN=BIN
wxcomponents/verify_mpsdk/images/ico-cameNative.png


BIN=BIN
wxcomponents/verify_mpsdk/images/ico-suc.png


BIN=BIN
wxcomponents/verify_mpsdk/images/ico-sucNative.png


BIN=BIN
wxcomponents/verify_mpsdk/images/shibiebgNative.png


+ 1219 - 0
wxcomponents/verify_mpsdk/index/index.js

@@ -0,0 +1,1219 @@
+const regeneratorRuntime = require("../utils/regenerator-runtime/runtime"),
+	util = require("../utils/util");
+var sysFailInfo = require("../config").sysFailInfo,
+	BASE_URL = "";
+const main = require("../main");
+var tokenExceptionArr = [14, 15],
+	idExceptionArr = [2002, 2003, 2006],
+	ctx = "";
+Page({
+	data: {
+		curPage: 1,
+		cmsConfig: {},
+		skipConfig: {},
+		bizData: {},
+		token: "",
+		preClickBtnTime: 0,
+		isNotCamera: !0,
+		iKnowFuncs: [],
+		index_rule: !1,
+		show_about_dlg: !1,
+		indexChecked: !0,
+		indexDisableBtn: !1,
+		show_auth_panel: !1,
+		authInfo: "",
+		isInfinityDisplay: !1,
+		notice: {
+			titie: "",
+			content: ""
+		},
+		sms: {
+			isForbiddenSmsBtn: !0,
+			hintError: "",
+			isEnableSendSms: !1,
+			is60sGap: !1,
+			sendSmsTtitle: "获取验证码",
+			gapSec: 60,
+			phoneNum: "",
+			verifyCode: ""
+		},
+		ocr: {
+			isShowTakePhoto: !1,
+			isShowResult: !1,
+			isShowGuide: !0,
+			isShowPhotoPreView: !1,
+			isPhotoFromCamera: !1,
+			isFrontIdCard: !0,
+			hintError: "",
+			hintErrorResult: "",
+			isForbiddenManualBtn: !0,
+			isForbiddenResultBtn: !1,
+			idcard: "",
+			idname: "",
+			idaddress: "",
+			tempImagePath: "",
+			ocrTitle: "请拍摄身份证人像面",
+			verifycamFullScreen: "verifycamFullScreen",
+			isToolsShow: !0,
+			isEditTheOcrIsManualInput: !1,
+			isInfinityDisplayOcrTitle: "",
+			isInfinityDisplayOcrBottom: "",
+			isInfinityDisplayOcrMiddle: "",
+			frontMediaKey: "",
+			backendMediaKey: ""
+		},
+		livingbody: {
+			isShowGuide: !0,
+			isShowCamera: !1,
+			isShowProcess: !1,
+			isShowDialog: !1,
+			livingbodyNumber: "",
+			isNotPrepareOk: !0,
+			getCodeErrMsg: "",
+			livingbodyTitle: "请保持正脸对准框内",
+			isPrepare: !0,
+			curNumberStatus: ["verifyCurrentNumber", "", "", ""],
+			curNumber: ["·", "·", "·", "·"],
+			isActionSeqNormal: "",
+			livingbodyActionText: "",
+			livingbodySilentText: "",
+			uploadProcess: 0,
+			showTestVideo: !1,
+			video_preview: "",
+			video_src: "",
+			isInfinityDisplayHTTitle: "",
+			isInfinityDisplayHTBottom: "",
+			isInfinityDisplayHTMiddle: "",
+			isInfinityDisplayHTActionPre: "",
+			isInfinityDisplayHTNumberPre: "",
+			isInfinityDisplayHTActionHint: "",
+			isInfinityDisplayHTNumberHint: ""
+		},
+		failPage: {
+			is_modal_showing: !1
+		},
+		successPage: {},
+		failInfo: {}
+	},
+	onLoad: function(i) {
+		if (console.log(i), this.setData({
+				cmsConfig: wx.verify_CMSConfig,
+				token: wx.verify_TOKEN,
+				bizData: wx.verify_BizData
+			}), console.log("this.data.cmsConfig =", this.data.cmsConfig), console.log(
+				`this.data.token = ${this.data.token}`), console.log(
+				`wx.verifyBaseUrl = ${wx.verifyBaseUrl}`), console.log(this.data.cmsConfig.page.ocr
+			.backend), BASE_URL = wx.verifyBaseUrl, wx.setNavigationBarTitle({
+				title: this.data.cmsConfig.justForJumpVer.title,
+				success: function() {
+					console.log("setNavigationBarTitle success!")
+				},
+				fail: function(i) {
+					console.log("setNavigationBarTitle failure!"), console.log(i)
+				}
+			}), "true" === i.isNotice) return console.log("is notice"), this.setData({
+			curPage: 7
+		}), void this.getTheNotice();
+		console.log("is not notice"), this.data.cmsConfig.isGetUserLocation && this.getUserLocation(), wx
+			.getSystemInfo({
+				success: i => {
+					console.log(i);
+					var o = i.screenHeight / i.screenWidth >= 2;
+					i.screenHeight > 700 && o && this.setData({
+						isInfinityDisplay: !0,
+						"ocr.isInfinityDisplayOcrBottom": "isInfinityDisplayOcrBottom",
+						"ocr.isInfinityDisplayOcrMiddle": "isInfinityDisplayOcrMiddle",
+						"ocr.isInfinityDisplayOcrTitle": "isInfinityDisplayOcrTitle",
+						"livingbody.isInfinityDisplayHTBottom": "isInfinityDisplayHTBottom",
+						"livingbody.isInfinityDisplayHTMiddle": "isInfinityDisplayHTMiddle",
+						"livingbody.isInfinityDisplayHTTitle": "isInfinityDisplayHTTitle",
+						"livingbody.isInfinityDisplayHTActionPre": "isInfinityDisplayHTActionPre",
+						"livingbody.isInfinityDisplayHTNumberPre": "isInfinityDisplayHTNumberPre",
+						"livingbody.isInfinityDisplayHTActionHint": "isInfinityDisplayHTActionHint",
+						"livingbody.isInfinityDisplayHTNumberHint": "isInfinityDisplayHTNumberHint"
+					})
+				}
+			})
+	},
+	getTheNotice() {
+		var i = {
+			url: BASE_URL + "notices.php",
+			data: {
+				appid: this.data.bizData.appid
+			}
+		};
+		util.request(i, i => {
+			if (console.log(i), 0 === i.ErrorCode) {
+				var o = JSON.parse(i.Data);
+				this.setData({
+					"notice.content": o[0].content,
+					"notice.title": o[0].title
+				})
+			} else wx.showModal({
+				title: "提示",
+				content: "获取公告信息失败," + i.ErrorMsg,
+				confirmText: "重试",
+				showCancel: !1,
+				confirmColor: "#2d72f1",
+				success: i => {
+					i.confirm && this.getTheNotice()
+				}
+			})
+		})
+	},
+	onReady: function() {},
+	onShow: function() {
+		this.data.show_auth_panel && setTimeout(() => {
+			this.isAuthOk()
+		}, 500)
+	},
+	onHide: function() {},
+	onUnload: function() {},
+	onPullDownRefresh: function() {},
+	onReachBottom: function() {},
+	onShareAppMessage: function() {},
+	showErrorToast: function(i) {
+		if (console.log("showErrorToast", i), 3 === this.data.curPage) {
+			if (this.data.ocr.isShowResult) return void this.setData({
+				"ocr.hintErrorResult": i.error_msg
+			});
+			this.data.ocr.isShowTakePhoto && 101 !== i.ErrorCode && -107 !== i.ErrorCode && this.data
+				.iKnowFuncs.push(() => {
+					this.reTakePhoto()
+				})
+		}
+		this.setData({
+			showErrorMsg: !0,
+			err: i
+		})
+	},
+	switchDialog: function() {
+		if (this.setData({
+				showErrorMsg: !this.data.showErrorMsg
+			}), 1 === this.data.iKnowFuncs.length) {
+			this.data.iKnowFuncs.pop()()
+		}
+	},
+	checkNetWork: function(i) {
+		var o = this;
+		wx.getNetworkType({
+			success: function(e) {
+				"none" !== e.networkType ? i() : (console.log("Network is none"), o
+					.showErrorToast({
+						ErrorCode: 101,
+						ErrorMsg: "网络异常,请稍后重试"
+					}))
+			},
+			fail: function(i) {
+				console.log("Get Network exception"), o.showErrorToast({
+					ErrorCode: 101,
+					ErrorMsg: "网络异常,请稍后重试"
+				})
+			}
+		})
+	},
+	checkRecordNetworkOk: function(i, o) {
+		wx.getNetworkType({
+			success: function(e) {
+				"none" !== e.networkType ? (console.log("network is OK"), i(e.networkType)) : (
+					console.log("Network is none"), o({
+						ErrorCode: 101,
+						ErrorMsg: "网络异常,请稍后再试"
+					}))
+			},
+			fail: function(i) {
+				console.log("Get Network exception"), o({
+					ErrorCode: 101,
+					ErrorMsg: "网络异常,请稍后再试"
+				})
+			}
+		})
+	},
+	returnAllCheckNetWork(i) {
+		wx.getNetworkType({
+			success: function(o) {
+				i(o.networkType)
+			},
+			fail: function(o) {
+				i("none")
+			}
+		})
+	},
+	isNotAllowClick: function() {
+		var i = +new Date;
+		return i - this.data.preClickBtnTime < 1e3 ? (console.log("Click button gap < 1s, not allow exec"),
+			!0) : (this.data.preClickBtnTime = i, console.log("Click button gap > 1s, allow exec"), !1)
+	},
+	exitVerify(i) {
+		i.BizToken = this.data.token, i.ErrorCode = 0, this.data.bizData.endPath ? wx.verifySuccessFunc(i) : wx
+			.navigateBack({
+				success: function(o) {
+					wx.verifySuccessFunc(i)
+				}
+			})
+	},
+	exitVerifyFail(i) {
+		i.BizToken = this.data.token, this.data.bizData.endPath ? -999 === i.ErrorCode ? wx.navigateBack({
+			success: () => {}
+		}) : (console.log("exitVerifyFail: this.data.bizData.endPath", this.data.bizData.endPath), wx
+			.verifyFailureFunc(i)) : wx.navigateBack({
+			success: () => {
+				-999 !== i.ErrorCode && wx.verifyFailureFunc(i)
+			}
+		})
+	},
+	switchIndexRule: function() {
+		this.setData({
+			index_rule: !this.data.index_rule
+		})
+	},
+	switchAboutDlg: function() {
+		this.setData({
+			show_about_dlg: !this.data.show_about_dlg
+		})
+	},
+	checkboxChange(i) {
+		this.setData({
+			indexDisableBtn: !this.data.indexDisableBtn
+		})
+	},
+	getUserLocation: function() {
+		var i = this;
+		wx.getLocation({
+			type: "wgs84",
+			success: function(o) {
+				console.log("Get the location success!", o);
+				var e = {
+					url: BASE_URL + `/api/auth/saveLocation?BizToken=${i.data.token}`,
+					data: {
+						Longitude: o.longitude,
+						Latitude: o.latitude
+					}
+				};
+				util.request(e, function(o) {
+					if (0 === o.ErrorCode) console.log("Report location success!");
+					else {
+						if (console.log(o.ErrorCode), tokenExceptionArr.includes(o
+								.ErrorCode)) return void i.exitVerifyFail({
+							ErrorCode: o.ErrorCode,
+							ErrorMsg: o.ErrorMsg
+						});
+						i.showErrorToast(o)
+					}
+				})
+			},
+			fail: function(i) {
+				console.log("Get location failure!"), console.log(i)
+			}
+		})
+	},
+	startNativeVerify: function() {
+		console.log("直接调用微信原生接口");
+		let i = this.data.cmsConfig,
+			o = i.Common.WxVerifyTypeIsVideo,
+			e = i.Common.WxCheckAliveType;
+		util.startNativeVerify(o, e, BASE_URL, this.data.token, this.exitVerifyFail, i => {
+			let o = {
+				BizToken: this.data.token,
+				ErrorCode: i.ErrorCode,
+				ErrorMsg: i.ErrorMsg
+			};
+			0 === i.ErrorCode ? this.exitVerify(o) : this.exitVerifyFail(o)
+		})
+	},
+	indexToNext: async function() {
+		if (!this.isNotAllowClick()) {
+			var i = this;
+			this.checkNetWork(function() {
+				var o = i.data.cmsConfig;
+				if (!i.data.cmsConfig.Common.IsWxNative || i.data.cmsConfig.Common.Flow.includes(
+						"Ocr")) {
+					var e = 2;
+					o.isHideSmsPage && (e = o.isHideOcrPage ? 4 : 3), i.setData({
+							curPage: e
+						}), (4 === e || 3 === e && !i.data.cmsConfig.page.ocr.isManualInput) && i
+						.preLivingbodyExec()
+				} else i.startNativeVerify()
+			})
+		}
+	},
+	phoneNumChanged(i) {
+		this.setData({
+			"sms.hintError": ""
+		});
+		var o = i.detail.value;
+		this.data.sms.phoneNum = o;
+		var e = util.validate(o, "sms_phone");
+		console.log(`isPhoneOk: ${e}`), e && !this.data.sms.is60sGap && this.setData({
+			"sms.isEnableSendSms": !0
+		}), e || this.setData({
+			"sms.isEnableSendSms": !1
+		});
+		var t = util.validate(this.data.sms.verifyCode, "sms_verifyCode");
+		e && t ? this.setData({
+			"sms.isForbiddenSmsBtn": !1
+		}) : this.setData({
+			"sms.isForbiddenSmsBtn": !0
+		}), console.log(`isEnableSendSms: ${this.data.sms.isEnableSendSms}`)
+	},
+	sendVerifyCodeReq: function() {
+		if (!this.isNotAllowClick()) {
+			var i = this;
+			this.checkNetWork(function() {
+				let o = {
+					url: `${BASE_URL}/api/common/sendSmsCode?BizToken=${i.data.token}`,
+					data: {
+						PhoneNum: i.data.sms.phoneNum
+					}
+				};
+				wx.showLoading({
+					title: "短信发送中...",
+					mask: !0
+				}), util.request(o, function(o) {
+					if (wx.hideLoading(), 0 === o.ErrorCode) {
+						i.setData({
+							"sms.is60sGap": !0,
+							"sms.isEnableSendSms": !1,
+							"sms.sendSmsTtitle": "重新发送"
+						});
+						var e = setInterval(function() {
+							i.data.sms.gapSec <= 1 && (clearInterval(e), i.setData({
+								"sms.is60sGap": !1,
+								"sms.gapSec": 60
+							}), util.validate(i.data.sms.phoneNum,
+								"sms_phone") && i.setData({
+								"sms.isEnableSendSms": !0
+							})), i.setData({
+								"sms.gapSec": i.data.sms.gapSec - 1
+							})
+						}, 1e3)
+					} else {
+						if (tokenExceptionArr.includes(o.ErrorCode)) return void i
+							.exitVerifyFail(o);
+						i.setData({
+							"sms.hintError": o.ErrorMsg
+						})
+					}
+				})
+			})
+		}
+	},
+	verifyCodeChanged(i) {
+		this.setData({
+			"sms.hintError": ""
+		}), this.data.sms.verifyCode = i.detail.value;
+		var o = util.validate(this.data.sms.verifyCode, "sms_verifyCode");
+		util.validate(this.data.sms.phoneNum, "sms_phone") && o ? this.setData({
+			"sms.isForbiddenSmsBtn": !1
+		}) : this.setData({
+			"sms.isForbiddenSmsBtn": !0
+		})
+	},
+	smsToNext() {
+		if (!this.isNotAllowClick()) {
+			var i = this;
+			this.checkNetWork(function() {
+				console.log(i.data.sms.phoneNum + " | " + i.data.sms.verifyCode);
+				let o = {
+					url: `${BASE_URL}/api/common/verifySmsCode?BizToken=${i.data.token}`,
+					data: {
+						PhoneNum: i.data.sms.phoneNum,
+						VerifyCode: i.data.sms.verifyCode
+					}
+				};
+				wx.showLoading({
+					title: "加载中...",
+					mask: !0
+				}), util.request(o, function(o) {
+					if (wx.hideLoading(), 0 === o.ErrorCode) {
+						var e = i.data.cmsConfig;
+						if (e.isJustSms) i.exitVerify({});
+						else {
+							var t = 3;
+							e.isHideOcrPage && (t = 4), i.setData({
+								curPage: t
+							}), (4 === t || 3 === t && !i.data.cmsConfig.page.ocr
+								.isManualInput) && i.preLivingbodyExec()
+						}
+					} else {
+						if (tokenExceptionArr.includes(o.ErrorCode)) return void i
+							.exitVerifyFail(o);
+						i.setData({
+							"sms.hintError": o.ErrorMsg
+						})
+					}
+				})
+			})
+		}
+	},
+	idcartManualInputChanged(i) {
+		var o = i.detail.value;
+		this.data.ocr.idcard = o, this.manualInputChanged()
+	},
+	idnameManualInputChanged(i) {
+		var o = i.detail.value;
+		this.data.ocr.idname = o, this.manualInputChanged()
+	},
+	manualInputChanged(i) {
+		this.setData({
+			"ocr.hintError": ""
+		});
+		var o = util.validate(this.data.ocr.idcard, "idcard"),
+			e = util.validate(this.data.ocr.idname, "idname"),
+			t = !0;
+		o || 18 !== this.data.ocr.idcard.length ? o && (e && (t = !1), this.setData({
+			"ocr.isForbiddenManualBtn": t
+		})) : this.setData({
+			"ocr.hintError": "身份证号有误,请确认后重新输入"
+		})
+	},
+	manualInputGoNext() {
+		this.ocrCommonInputGoNext(!0)
+	},
+	ocrCommonInputGoNext(i) {
+		var o = this;
+		this.checkNetWork(function() {
+			o.data.cmsConfig;
+			wx.showLoading({
+				title: "校验身份信息中...",
+				mask: !0
+			});
+			let e = 0;
+			"android" === wx.verifySysInfo.platform && (e = 300), setTimeout(() => {
+				var e = {
+					url: `${BASE_URL}/api/ocr/updateidinfo?BizToken=${o.data.token}`,
+					data: {
+						Name: o.data.ocr.idname,
+						IdCard: o.data.ocr.idcard
+					}
+				};
+				o.data.ocr.idaddress && (e.data.Address = o.data.ocr.idaddress), util.request(e,
+					function(e) {
+						if (wx.hideLoading(), 0 !== e.ErrorCode) {
+							if (tokenExceptionArr.includes(e.ErrorCode)) return void o
+								.exitVerifyFail(e);
+							let t = {
+								"ocr.hintError": e.ErrorMsg
+							};
+							return i || (t = {
+								"ocr.hintErrorResult": e.ErrorMsg
+							}), void o.setData(t)
+						}
+						o.ocrGoNext(i)
+					})
+			}, e)
+		})
+	},
+	ocrGoNext(i) {
+		var o = this;
+		if (o.data.cmsConfig.page.ocr.isCheckIDInfo) {
+			let e = {
+				url: `${BASE_URL}/api/ocr/checkidinfo?BizToken=${this.data.token}`,
+				data: {
+					Name: this.data.ocr.idname,
+					IdCard: this.data.ocr.idcard
+				}
+			};
+			util.request(e, e => {
+				if (0 !== e.ErrorCode) {
+					if (tokenExceptionArr.includes(e.ErrorCode)) return void o.exitVerifyFail(e);
+					let t = {
+						"ocr.hintError": e.ErrorMsg
+					};
+					return console.log(e.ErrorMsg), i || (t = {
+						"ocr.hintErrorResult": e.ErrorMsg
+					}), void o.setData(t)
+				}
+				this.ocrGoNextEnd()
+			})
+		} else this.ocrGoNextEnd()
+	},
+	ocrGoNextEnd() {
+		if (this.data.cmsConfig.isJustOcr) this.exitVerify({
+			id_name: this.data.ocr.idname,
+			id_number: this.data.ocr.idcard,
+			id_address: this.data.ocr.idaddress
+		});
+		else {
+			if (this.data.cmsConfig.Common.IsWxNative) return void this.startNativeVerify();
+			this.setData({
+				curPage: 4
+			}), this.preLivingbodyExec()
+		}
+	},
+	manualInputTakePhone() {
+		this.setData({
+			"cmsConfig.page.ocr.isManualInput": !1,
+			"ocr.isEditTheOcrIsManualInput": !0
+		})
+	},
+	btnclick: function() {
+		var i = this.data.cmsConfig.page.ocr.backend;
+		console.log(i)
+	},
+	ocrStartTakePhoto() {
+		var i = this;
+		this.checkNetWork(function() {
+			i.setData({
+				"ocr.isShowTakePhoto": !0,
+				isNotCamera: !1
+			})
+		})
+	},
+	takePhotoWithCamera() {
+		var i = this;
+		wx.createCameraContext().takePhoto({
+			quality: "noraml",
+			success: o => {
+				console.log(o.tempImagePath), this.setData({
+					"ocr.tempImagePath": o.tempImagePath,
+					"ocr.isShowPhotoPreView": !0,
+					"ocr.ocrTitle": "照片预览",
+					"ocr.isPhotoFromCamera": !0
+				}), console.log(i.data.ocr.tempImagePath)
+			},
+			fail: i => {
+				wx.showToast({
+					title: "takePhoto function exception",
+					icon: "none"
+				})
+			}
+		})
+	},
+	chooseImg() {
+		var i = this;
+		wx.chooseImage({
+			count: 1,
+			sizeType: ["compressed"],
+			sourceType: ["album"],
+			success: function(o) {
+				var e = o.tempFilePaths;
+				i.setData({
+					"ocr.tempImagePath": e[0],
+					"ocr.isShowPhotoPreView": !0,
+					"ocr.ocrTitle": "照片预览",
+					"ocr.isPhotoFromCamera": !1
+				}), i.setData({
+					"ocr.isToolsShow": !1
+				}), i.setData({
+					"ocr.isToolsShow": !0
+				})
+			}
+		})
+	},
+	reTakePhoto() {
+		let i = this.data.ocr.isFrontIdCard ? "请拍摄身份证人像面" : "请拍摄身份证国徽面";
+		this.setData({
+			"ocr.tempImagePath": "",
+			"ocr.isShowPhotoPreView": !1,
+			"ocr.ocrTitle": i
+		})
+	},
+	startUploadAndOcr() {
+		var i = this;
+		this.checkNetWork(() => {
+			wx.showLoading({
+				title: "系统识别中",
+				mask: !0
+			});
+			let o = {
+				file: i.data.ocr.tempImagePath
+			};
+			console.log("upfile data", o), wx.uploadFile({
+				url: `${BASE_URL}/api/common/upLoadWxAppFile?BizToken=${i.data.token}`,
+				filePath: this.data.ocr.tempImagePath,
+				name: "file",
+				formData: o,
+				success: o => {
+					if (console.log("uploadFile | ", o), 200 === o.statusCode) {
+						let e = JSON.parse(o.data);
+						if (0 === e.ErrorCode) {
+							let o = {
+								url: `${BASE_URL}/api/ocr/ocrinfo?BizToken=${this.data.token}`,
+								data: {
+									MediaKey: e.Data.MediaKey,
+									PicType: this.data.ocr.isFrontIdCard ? 0 : 1
+								}
+							};
+							console.log("ocrinfo data", o), util.request(o, o => {
+								if (wx.hideLoading(), 0 === o.ErrorCode) {
+									if (this.data.ocr.isFrontIdCard && this
+									.setData({
+											"ocr.idcard": o.Data.id,
+											"ocr.idname": o.Data.name,
+											"ocr.idaddress": o.Data.address
+										}), this.data.ocr.isFrontIdCard && this.data
+										.cmsConfig.page.ocr.backend)
+									return void this.setData({
+											"ocr.tempImagePath": "",
+											"ocr.isShowPhotoPreView": !1,
+											"ocr.ocrTitle": "请拍摄身份证国徽面",
+											"ocr.isFrontIdCard": !1
+										});
+									this.setData({
+										"ocr.isShowResult": !0,
+										isNotCamera: !0,
+										"ocr.verifycamFullScreen": "verifycamFullScreen"
+									})
+								} else {
+									if (tokenExceptionArr.includes(o.ErrorCode))
+										return void i.exitVerifyFail(o);
+									this.showErrorToast(o)
+								}
+							})
+						} else wx.hideLoading(), this.showErrorToast({
+							ErrorCode: 101,
+							ErrorMsg: e.ErrorMsg
+						})
+					} else wx.hideLoading(), this.showErrorToast({
+						ErrorCode: 101,
+						ErrorMsg: "上传图片失败"
+					})
+				},
+				fail: i => {
+					console.log("upload img fail", i), wx.hideLoading(), this
+						.showErrorToast({
+							ErrorCode: 101,
+							ErrorMsg: "上传图片失败"
+						})
+				}
+			})
+		})
+	},
+	idnameInputChanged(i) {
+		this.data.ocr.idname = i.detail.value, this.ocrCommonInputCheck()
+	},
+	idcartInputChanged(i) {
+		this.data.ocr.idcard = i.detail.value, this.ocrCommonInputCheck()
+	},
+	idaddressInputChanged(i) {
+		this.data.ocr.idaddress = i.detail.value, this.ocrCommonInputCheck()
+	},
+	ocrCommonInputCheck() {
+		this.setData({
+			"ocr.hintErrorResult": ""
+		});
+		var i = util.validate(this.data.ocr.idcard, "idcard"),
+			o = util.validate(this.data.ocr.idname, "idname"),
+			e = util.validate(this.data.ocr.idaddress, "idaddress"),
+			t = !0;
+		i && o && (t = !1), this.data.cmsConfig.page.ocr.isAddress && !e && (t = !0), this.setData({
+			"ocr.isForbiddenResultBtn": t
+		})
+	},
+	ocrInputGoNext(i) {
+		if (util.validate(this.data.ocr.idcard, "idcard"))
+			if (util.validate(this.data.ocr.idname, "idname")) {
+				if (this.data.cmsConfig.page.ocr.isAddress)
+					if (!util.validate(this.data.ocr.idaddress, "idaddress")) return void this.setData({
+						"ocr.hintErrorResult": "住址格式错误"
+					});
+				console.log("go next"), this.ocrCommonInputGoNext(!1)
+			} else this.setData({
+				"ocr.hintErrorResult": "姓名格式错误"
+			});
+		else this.setData({
+			"ocr.hintErrorResult": "身份证号格式错误"
+		})
+	},
+	switchLivingbodyDialog(i) {
+		this.setData({
+			"livingbody.isShowDialog": !this.data.livingbody.isShowDialog
+		})
+	},
+	preLivingbodyExec() {
+		var i = this;
+		if (4 !== this.data.curPage || 0 !== this.data.cmsConfig.livingbodyType && 1 !== this.data.cmsConfig
+			.livingbodyType) i.getAuth();
+		else {
+			let o = {
+				url: `${BASE_URL}/api/liveness/lipcode?BizToken=${i.data.token}`,
+				data: {}
+			};
+			1 === i.data.cmsConfig.livingbodyType && (o.url =
+				`${BASE_URL}/api/liveness/actioncode?BizToken=${i.data.token}`), util.request(o, o => {
+				if (0 === o.ErrorCode) {
+					console.log("Got the LipCode:" + o.Data.LipCode), console.log(
+						"Got the ActionCode:" + o.Data.ActionCode);
+					var e = {
+						"livingbody.livingbodyNumber": o.Data.LipCode
+					};
+					1 === i.data.cmsConfig.livingbodyType && (e = {
+						"livingbody.isActionSeqNormal": "21" === o.Data.ActionCode.join("")
+					}), this.setData(e), i.getAuth()
+				} else {
+					if (tokenExceptionArr.includes(o.ErrorCode)) return void i.exitVerifyFail(o);
+					this.setData({
+						"livingbody.getCodeErrMsg": o.ErrorMsg
+					}), i.getAuth()
+				}
+			})
+		}
+	},
+	getAuth: function() {
+		let i = this;
+		wx.authorize({
+			scope: "scope.camera",
+			success() {},
+			fail: function() {
+				console.log("您未允许使用摄像头权限")
+			},
+			complete: function() {
+				4 === i.data.curPage ? wx.authorize({
+					scope: "scope.record",
+					success() {},
+					fail: function() {
+						console.log("您未允许使用录音权限")
+					},
+					complete: function() {
+						console.log("开始判断是否有权限"), i.isAuthOk()
+					}
+				}) : i.isAuthOk()
+			}
+		})
+	},
+	isAuthOk: function() {
+		var i = this;
+		wx.getSetting({
+			success(o) {
+				console.log("获取授权信息成功");
+				var e = o.authSetting["scope.record"],
+					t = o.authSetting["scope.camera"];
+				if (4 === i.data.curPage)
+					if (e && t) i.setData({
+						show_auth_panel: !1,
+						authInfo: "摄像头、录音功能都已授权"
+					}), i.authOkToDo(), console.log("摄像头、录音功能都已授权");
+					else {
+						var a = "";
+						t || (a = "摄像头 "), e || (a += "录音功能"), a += "还未授权", console.log(a), i
+							.setData({
+								show_auth_panel: !0,
+								authInfo: a
+							})
+					}
+				else t ? i.setData({
+					show_auth_panel: !1,
+					authInfo: "摄像头已授权"
+				}) : i.setData({
+					show_auth_panel: !0,
+					authInfo: "摄像头未授权"
+				})
+			},
+			fail: function(i) {
+				console.log("获取收取信息失败", i)
+			}
+		})
+	},
+	authOkToDo() {
+		console.log(this.data.livingbody.livingbodyNumber, this.data.cmsConfig.livingbodyType), 0 === this.data
+			.cmsConfig.livingbodyType && "" === this.data.livingbody.livingbodyNumber || 1 === this.data
+			.cmsConfig.livingbodyType && "" === this.data.livingbody.isActionSeqNormal ? this
+			.theLivingBodyNumberMustBeOk() : (this.livingbodyAutoShowDialog(), this.setData({
+				"livingbody.isNotPrepareOk": !1
+			}))
+	},
+	theLivingBodyNumberMustBeOk() {
+		var i = this;
+		wx.showModal({
+			title: "提示",
+			content: "获取code失败," + i.data.livingbody.getCodeErrMsg,
+			showCancel: !1,
+			confirmText: "重新获取",
+			confirmColor: "#2d72f1",
+			success: function(o) {
+				if (o.confirm) {
+					console.log("开始重新获取"), wx.showLoading({
+						title: "重新获取中...",
+						mask: !0
+					});
+					let o = {
+						url: `${BASE_URL}/api/liveness/lipcode?BizToken=${i.data.token}`,
+						data: {}
+					};
+					1 === i.data.cmsConfig.livingbodyType && (o.url =
+							`${BASE_URL}/api/liveness/actioncode?BizToken=${i.data.token}`), util
+						.request(o, o => {
+							if (wx.hideLoading(), 0 === o.ErrorCode) console.log(
+									"Got the LipCode:" + o.Data.LipCode), console.log(
+									"Got the ActionCode:" + o.Data.ActionCode), i
+								.livingbodyAutoShowDialog(), 1 === i.data.cmsConfig
+								.livingbodyType ? i.setData({
+									"livingbody.isActionSeqNormal": "21" === o.Data
+										.ActionCode.join(""),
+									"livingbody.isNotPrepareOk": !1
+								}) : i.setData({
+									"livingbody.livingbodyNumber": o.Data.LipCode,
+									"livingbody.isNotPrepareOk": !1
+								});
+							else {
+								if (tokenExceptionArr.includes(o.ErrorCode)) return void i
+									.exitVerifyFail(o);
+								i.setData({
+									"livingbody.getCodeErrMsg": o.ErrorMsg
+								}), i.theLivingBodyNumberMustBeOk()
+							}
+						})
+				}
+			}
+		})
+	},
+	livingbodyAutoShowDialog() {
+		let i = wx.getStorageSync("isAlreadyShowVideoRule");
+		console.log("isAlreadyShowVideoRule:" + i), i || (this.setData({
+			"livingbody.isShowDialog": !this.data.livingbody.isShowDialog
+		}), wx.setStorage({
+			key: "isAlreadyShowVideoRule",
+			data: "true"
+		}))
+	},
+	livingbodyStartToRecord() {
+		this.checkNetWork(() => {
+			console.log("go"), this.setData({
+				"livingbody.isShowCamera": !0,
+				isNotCamera: !1
+			}), setTimeout(() => {
+				this.checkRecordNetworkOk(() => {
+					ctx = wx.createCameraContext(), console.log("start startRecord", +
+						new Date), ctx.startRecord({
+						success: i => {
+							console.log("startRecord success", +new Date);
+							let o = this.data.cmsConfig.livingbodyType,
+								e = {
+									"livingbody.isPrepare": !1
+								},
+								t = 0,
+								a = 1200,
+								s = 1e3,
+								r = this.data.livingbody.livingbodyNumber +
+								"",
+								n = ["", "", "", ""],
+								d = ["·", "·", "·", "·"],
+								l = this.data.cmsConfig.page.livingbody
+								.silentRecordTime - 1;
+							if (0 === o) d[t] = r[t], n[t] =
+								"verifyCurrentNumber", e[
+									"livingbody.livingbodyTitle"] =
+								"请大声朗读以下数字", e[
+								"livingbody.curNumberStatus"] = n, e[
+									"livingbody.curNumber"] = d, s = 1500;
+							else if (1 === o) {
+								let i = this.data.livingbody
+									.isActionSeqNormal;
+								e["livingbody.livingbodyTitle"] = "请做以下动作",
+									e["livingbody.livingbodyActionText"] =
+									i ? "眨眨眼" : "张张嘴", a = 2e3
+							} else e["livingbody.livingbodySilentText"] = l,
+								a = 1e3;
+							this.setData(e);
+							let c = setInterval(() => {
+								if (0 === o) {
+									if (3 === t)
+									return clearInterval(c),
+										void this
+										.stopRecordAndProcess(s);
+									d[++t] = r[t], n[t] =
+										"verifyCurrentNumber", this
+										.setData({
+											"livingbody.curNumberStatus": n,
+											"livingbody.curNumber": d
+										})
+								} else if (1 === o) {
+									if (1 === t)
+									return clearInterval(c),
+										void this
+										.stopRecordAndProcess(s);
+									t++, this.setData({
+										"livingbody.livingbodyActionText": this
+											.data.livingbody
+											.isActionSeqNormal ?
+											"张张嘴" : "眨眨眼"
+									})
+								} else {
+									if (0 === l)
+									return clearInterval(c),
+										void this
+										.stopRecordAndProcess(s);
+									l--, this.setData({
+										"livingbody.livingbodySilentText": l
+									})
+								}
+							}, a)
+						},
+						fail: i => {
+							this.setData({
+								"livingbody.isShowGuide": !0,
+								"livingbody.isShowCamera": !1,
+								isNotCamera: !0,
+								"livingbody.isPrepare": !0
+							}), console.log("start record fail", +
+								new Date, i), this.showErrorToast({
+								ErrorCode: -108,
+								ErrorMsg: `网络异常,${i.errMsg}`
+							})
+						},
+						timeoutCallback: i => {
+							console.log("timeoutCallback", i), this
+						.setData({
+								"livingbody.isShowGuide": !0,
+								"livingbody.isShowCamera": !1,
+								isNotCamera: !0,
+								"livingbody.isPrepare": !0
+							}), this.showErrorToast({
+								ErrorCode: -108,
+								ErrorMsg: "startRecord timeoutCallback, 请重试!"
+							})
+						}
+					})
+				}, i => {
+					this.setData({
+						"livingbody.isShowGuide": !0,
+						"livingbody.isShowCamera": !1,
+						isNotCamera: !0
+					}), this.showErrorToast(i)
+				})
+			}, 2e3)
+		})
+	},
+	stopRecordAndProcess(i) {
+		console.log("start stopRecord", +new Date), setTimeout(() => {
+			console.log("stopTimeGap" + i), console.log(ctx.stopRecord), ctx.stopRecord({
+				success: i => {
+					console.log("stopRecord success", +new Date, i), wx.getFileInfo({
+						filePath: i.tempVideoPath,
+						success: o => {
+							var e = Math.round(o.size / 1024);
+							e > 30720 ? (this.setData({
+								"livingbody.isShowGuide": !0,
+								"livingbody.isShowCamera": !1,
+								isNotCamera: !0,
+								"livingbody.isPrepare": !0
+							}), this.showErrorToast({
+								ErrorCode: -108,
+								ErrorMsg: "视频大小超过限制"
+							})) : this.processTheVideo(i.tempVideoPath, e +
+								"K")
+						},
+						fail: i => {
+							this.setData({
+								"livingbody.isShowGuide": !0,
+								"livingbody.isShowCamera": !1,
+								isNotCamera: !0,
+								"livingbody.isPrepare": !0
+							}), this.showErrorToast({
+								ErrorCode: -108,
+								ErrorMsg: `getFileInfo异常,${i.errMsg}`
+							})
+						}
+					})
+				},
+				fail: i => {
+					this.setData({
+						"livingbody.isShowGuide": !0,
+						"livingbody.isShowCamera": !1,
+						isNotCamera: !0,
+						"livingbody.isPrepare": !0
+					}), this.showErrorToast({
+						ErrorCode: -108,
+						ErrorMsg: `stopRecord异常,${i.errMsg}`
+					})
+				},
+				complete(i) {
+					console.log("complete", i)
+				}
+			})
+		}, i)
+	},
+	processTheVideo(i, o) {
+		this.checkRecordNetworkOk(e => {
+			this.goToProcessPage(i, o)
+		}, e => {
+			this.setData({
+				"livingbody.isShowGuide": !0,
+				"livingbody.isShowCamera": !1,
+				isNotCamera: !0,
+				"livingbody.isPrepare": !0
+			}), wx.showModal({
+				title: "提示",
+				content: "网络异常,请检查网络后重试",
+				confirmText: "重试",
+				confirmColor: "#2d72f1",
+				success: e => {
+					e.confirm && this.processTheVideo(i, o)
+				}
+			})
+		})
+	},
+	goToProcessPage(i, o) {
+		this.setData({
+			"livingbody.isShowGuide": !1,
+			"livingbody.isShowCamera": !1,
+			"livingbody.isShowProcess": !0,
+			isNotCamera: !0,
+			"livingbody.isPrepare": !0
+		});
+		let e = {
+			url: `${BASE_URL}/api/common/upLoadWxAppFile?BizToken=${this.data.token}`,
+			filePath: i,
+			data: {
+				file: i
+			}
+		};
+		this.uploadTheVideo(e, o)
+	},
+	uploadTheVideo(i, o) {
+		this.returnAllCheckNetWork(e => {
+			"wifi" !== e && "none" !== e ? wx.showModal({
+				title: "提示",
+				content: `视频大约${o},在移动网络环境下上传会产生手机流量,确认继续?`,
+				confirmText: "继续",
+				confirmColor: "#2d72f1",
+				success: e => {
+					e.confirm ? this.uploadTheVideoMain(i, o) : this.setData({
+						"livingbody.isShowGuide": !0,
+						"livingbody.isShowCamera": !1,
+						"livingbody.isShowProcess": !1,
+						isNotCamera: !0,
+						"livingbody.isPrepare": !0
+					})
+				}
+			}) : this.uploadTheVideoMain(i, o)
+		})
+	},
+	uploadTheVideoMain(i, o) {
+		util.uploadFile.call(this, i, e => {
+			if (console.log("上传视频成功"), console.log(e), 0 === e.ErrorCode) console.log("uploadSuccess"),
+				console.log(e.Data.Data.MediaKey), this.livingbodyVerify(e.Data.Data.MediaKey);
+			else {
+				var t = "网络异常,上传视频失败";
+				101 !== e.ErrorCode && (t = e.ErrorMsg), wx.showModal({
+					title: "提示",
+					content: t,
+					showCancel: !1,
+					confirmText: "重试",
+					confirmColor: "#2d72f1",
+					success: e => {
+						e.confirm && this.uploadTheVideo(i, o)
+					}
+				})
+			}
+		})
+	},
+	livingbodyVerify(i) {
+		let o = this.data.cmsConfig.livingbodyType,
+			e = "/api/liveness/lipliveness";
+		1 === o ? e = "/api/liveness/actionliveness" : 2 === o && (e = "/api/liveness/silentliveness");
+		let t = {
+			url: `${BASE_URL}${e}?BizToken=${this.data.token}`,
+			data: {
+				MediaKey: i
+			}
+		};
+		console.log(t), util.request(t, o => {
+			if (console.log(o), 0 === o.ErrorCode) this.data.cmsConfig.page.success.isAutoSkip ? this
+				.exitVerify({}) : this.setData({
+					curPage: 6
+				});
+			else if (-107 === o.ErrorCode || 101 === o.ErrorCode) wx.showModal({
+				title: "提示",
+				content: o.error_msg,
+				showCancel: !1,
+				confirmText: "重试",
+				confirmColor: "#2d72f1",
+				success: o => {
+					o.confirm && this.livingbodyVerify(i)
+				}
+			});
+			else if (tokenExceptionArr.includes(o.ErrorCode)) this.exitVerifyFail(o);
+			else {
+				void 0 === o.ErrorCode && (o.ErrorCode = "9999", sysFailInfo[9999].tips1 = o.Data);
+				var e = o.ErrorCode + "",
+					t = {};
+				(t = this.data.cmsConfig.failInfo && this.data.cmsConfig.failInfo[e] ? this.data
+					.cmsConfig.failInfo[e] : sysFailInfo[e] ? sysFailInfo[e] : {
+						img: "",
+						msg: o.ErrorMsg,
+						error_code: o.ErrorCode
+					}).Data = o.Data || {}, console.log("failInfo: ", t), this.setData({
+					failInfo: t,
+					curPage: 5
+				})
+			}
+		})
+	},
+	failReVerify() {
+		if (console.log(this.data.failInfo), "无效请求" !== this.data.failInfo.msg && 14 !== this.data.failInfo
+			.error_code) {
+			var i = 4;
+			if (idExceptionArr.includes(this.data.failInfo.error_code)) {
+				if (this.data.cmsConfig.isHideOcrPage) return void this.exitVerifyFail({
+					Token: this.data.token,
+					ErrorCode: this.data.failInfo.error_code,
+					ErrorMsg: this.data.failInfo.msg
+				});
+				i = 3, this.setData({
+					"ocr.isShowTakePhoto": !1,
+					"ocr.isShowResult": !1,
+					"ocr.isShowGuide": !0,
+					"ocr.isShowPhotoPreView": !1,
+					"ocr.isPhotoFromCamera": !1,
+					"ocr.isFrontIdCard": !0,
+					"ocr.hintError": "",
+					"ocr.hintErrorResult": "",
+					"ocr.isForbiddenManualBtn": !0,
+					"ocr.isForbiddenResultBtn": !1,
+					"ocr.idcard": "",
+					"ocr.idname": "",
+					"ocr.idaddress": "",
+					"ocr.tempImagePath": "",
+					"ocr.ocrTitle": "请拍摄身份证人像面",
+					"ocr.isToolsShow": !0
+				}), this.data.ocr.isEditTheOcrIsManualInput && this.setData({
+					"cmsConfig.page.ocr.isManualInput": !0
+				})
+			}
+			this.setData({
+				curPage: i,
+				"livingbody.isShowGuide": !0,
+				"livingbody.isShowCamera": !1,
+				"livingbody.isShowProcess": !1,
+				"livingbody.isShowDialog": !1,
+				"livingbody.livingbodyNumber": "",
+				"livingbody.isNotPrepareOk": !0,
+				"livingbody.getCodeErrMsg": "",
+				"livingbody.livingbodyTitle": "请保持正脸对准框内",
+				"livingbody.isPrepare": !0,
+				"livingbody.curNumberStatus": ["verifyCurrentNumber", "", "", ""],
+				"livingbody.curNumber": ["·", "·", "·", "·"],
+				"livingbody.isActionSeqNormal": !0,
+				"livingbody.livingbodyActionText": "",
+				"livingbody.livingbodySilentText": "",
+				"livingbody.uploadProcess": 0
+			}), this.preLivingbodyExec()
+		} else {
+			this.exitVerifyFail({
+				ErrorCode: 14,
+				ErrorMsg: "由于活体验证时出现网络异常,导致无效请求,需要您重新验证,验证时请保持网络畅通!"
+			})
+		}
+	},
+	successGoToNext() {
+		this.exitVerify({})
+	},
+	verifyBackToIndex() {
+		var i = {};
+		i.Token = this.data.token, i.ErrorCode = -999, i.ErrorMsg = "返回首页成功,如多次验证不通过,可将当前页面截图提供给相关工作人员排查问题 " +
+			this.data.bizData.appid + " | " + i.token, this.exitVerifyFail(i)
+	},
+	switchfailModal() {
+		this.setData({
+			"failInfo.is_modal_showing": !this.data.failInfo.is_modal_showing
+		})
+	},
+	ocrCameraError: function(i) {
+		console.log("ocrCameraError", i)
+	},
+	bindstop: function(i) {
+		console.log(i)
+	}
+});

+ 4 - 0
wxcomponents/verify_mpsdk/index/index.json

@@ -0,0 +1,4 @@
+{
+  "disableScroll": true,
+  "component": true
+}

+ 42 - 0
wxcomponents/verify_mpsdk/index/index.wxml

@@ -0,0 +1,42 @@
+
+<!--verify_mpsdk/index/index.wxml-->
+<import src="../templates/index/index.wxml"></import>
+<import src="../templates/sms/sms.wxml"></import>
+<import src="../templates/ocr/ocr.wxml"></import>
+<import src="../templates/livingbody/livingbody.wxml"></import>
+<import src="../templates/failpage/failpage.wxml"></import>
+<import src="../templates/success/success.wxml"></import>
+<import src="../templates/notice/notice.wxml"></import>
+<import src="../templates/errorToast/errorToast.wxml"></import>
+<import src="../templates/showAuthToast/showAuthToast.wxml"></import>
+<import src="..//templates/navTip/navTip.wxml"></import>
+
+<view id="fix-full-page">
+  <!-- index -->
+  <template is="verifyIndex" wx:if="{{curPage === 1}}" data="{{...cmsConfig,index_rule,show_about_dlg,indexChecked,indexDisableBtn}}"></template>
+  <!-- notice page -->
+  <template is="verifyNotice" wx:if="{{curPage === 7}}" data="{{...cmsConfig,notice}}"></template>
+
+  <view wx:if="{{curPage !== 1 && curPage !== 7}}">
+    <template is="navTip" data="{{...cmsConfig,...cmsConfig.skipConfig,curPage}}" wx:if="{{isNotCamera}}"></template>
+    <!-- sms -->
+    <template is="verifySms" wx:if="{{curPage === 2}}" data="{{...cmsConfig,sms}}"></template>
+
+    <!-- ocr -->
+    <template is="verifyOcr" wx:if="{{curPage === 3}}" data="{{...cmsConfig,ocr,isInfinityDisplay}}"></template>
+
+    <!-- living body -->
+    <template is="verifyLivingBody" wx:if="{{curPage === 4}}" data="{{...cmsConfig,livingbody,isInfinityDisplay}}"></template>
+
+    <!-- fail page -->
+    <template is="verifyFailPage" wx:if="{{curPage === 5}}" data="{{...cmsConfig,failInfo}}"></template>
+
+    <!-- success page -->
+    <template is="verifySuccessPage" wx:if="{{curPage === 6}}" data="{{...cmsConfig}}"></template>
+
+  </view>
+</view>
+
+<template is="error_template" wx:if="{{showErrorMsg}}" data="{{...cmsConfig,...err}}"></template>
+
+<template is="auth_template"  data="{{...cmsConfig,authInfo}}" wx:if="{{show_auth_panel}}"></template>

+ 204 - 0
wxcomponents/verify_mpsdk/index/index.wxss

@@ -0,0 +1,204 @@
+/* verify_mpsdk/index/index.wxss */
+
+@import "../templates/navTip/navTip.wxss";
+@import "../templates/errorToast/errorToast.wxss";
+@import "../templates/sms/sms.wxss";
+@import "../templates/ocr/ocr.wxss";
+@import "../templates/livingbody/livingbody.wxss";
+@import "../templates/showAuthToast/showAuthToast.wxss";
+@import "../templates/success/success.wxss";
+@import "../templates/notice/notice.wxss";
+@import "../templates/riskTip/riskTip.wxss";
+
+#fix-full-page {
+  position:fixed;top:0;bottom:0;left:0;right:0;
+  width:100%;height:100%;
+}
+
+#fix-full-page button[disabled] {
+  background:#B3B3B3;
+  color: rgba(255,255,255,.6);
+}
+
+.verify-gray-container {
+ background-color:#F8F8F8;
+}
+
+.verify-absolute-bg {
+  position:absolute;top:0;bottom:0;width:100%;
+}
+.verify-white-bg {
+  background:#fff;
+}
+
+.hint-error {
+  padding:10px;
+  color:#ef4b46;
+  font-size:14px;
+  height: 19px;
+}
+
+.full-weight-height {
+  width:100%;
+  height:100%;
+}
+
+#index-top {
+  height: 650rpx;width: 750rpx;
+  text-align: center;
+  color: white;
+  background: url(http://beta.gtimg.com/GodIdent/huiyan/img/index-bg.png) no-repeat 0 0 / 100% 100%;
+}
+
+#index-topNative {
+  height: 650rpx;width: 750rpx;
+  text-align: center;
+  color: white;
+  background: url(https://s.beta.gtimg.com/GodIdent/huiyan-h5/images-wx/index-bg.png) no-repeat 0 0 / 100% 100%;
+}
+
+.color-grey {
+  color: #a3a3a3 !important;
+}
+.color-black {
+  color: #000 !important;
+}
+.color-green {
+  /* color: #18ae17 !important; */
+  color: #04be02 !important;
+}
+
+.index-hint {
+  font-size: 12px;
+}
+
+.index-title {
+  font-size: 56rpx;
+}
+
+#index-top-1st {
+  padding-top: 320rpx;
+}
+
+#index-top-2nd {
+  padding-top: 20rpx;
+}
+
+.index-btn {
+  margin: 30rpx 30rpx 10rpx 30rpx;
+}
+
+.index-btn button{
+  background-color:#2d72f1;
+  color:white;
+}
+
+.index-btnNative {
+  margin: 30rpx 30rpx 10rpx 30rpx;
+}
+
+.index-btnNative button{
+  /* background-color:#2d72f1; */
+  color:white;
+}
+
+.index-btnNative button[disabled] {
+  color:rgba(255, 255, 255, 0.6) !important;
+}
+.index-btnNative button[disabled][type=primary] {
+  background-color:#9ED99D !important;
+}
+
+
+.weui-dialog.protocol .weui-dialog__bd{
+    text-align:left;
+    max-height:300px;
+    overflow-y:auto;
+}
+
+.line {
+    height: 2rpx;
+    background: #888;
+    margin: 20rpx;
+}
+
+.index-protocol {
+  display:inline-flex;align-items:center;
+  /* height:20px; */
+  margin-left: 30rpx;
+  font-size: 12px;
+}
+
+.index-protocol-left {
+  display:inline-flex;
+  color:#989898;
+}
+
+.index-protocol checkbox {
+  zoom:0.6;
+  width:35px;
+  /* height:20px; */
+  margin-top:2px;
+}
+
+#index-protocol-right {
+  margin-left:5px;
+  color:#007aff;
+}
+
+.index-risk-tip {
+  margin: 40rpx 30rpx 0;
+}
+
+.verify-footer {
+  position:absolute;bottom:0;
+  width:100%;
+  padding:30rpx 0;
+  text-align:center;
+}
+.verify-footer-logo {
+  height:16px;
+}
+.verify-footer-logo  image {
+  width:88px;height:17px;
+}
+
+#index-footer-about {
+  font-size:10px;
+  color:#989898;
+  margin-top:8rpx;
+  border-bottom:thin solid #2473e9;
+}
+
+/* btn hover class, must add !important in mp */
+.btn-hover {
+  /* background: rgba(45,114,241) !important; */
+  background: rgb(11, 89, 235) !important;
+}
+.btn-hoverNative {
+  /* #1AAD19 */
+  background: rgba(26,173,25,.8) !important;
+}
+
+.verifyFailWarn {
+  display:flex;flex-direction:row; align-items:center;justify-content:center;
+  margin-bottom:5px;padding:0 20px;
+  text-align:center;font-weight:400;font-size:17px;
+}
+
+.verifyFailTop {
+  width:100%;margin:126rpx 0 50rpx 0;
+  text-align:center;
+}
+
+.page-body-link{
+   font-size:14px;
+   color:#007fff;
+   text-align: center;
+   margin-top: 15px;
+ }
+
+ .verifycamFullScreen {
+   position:absolute;top:0;bottom:0;
+   width:100%;
+ }

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/main.js


+ 1 - 0
wxcomponents/verify_mpsdk/templates/errorToast/errorToast.wxml

@@ -0,0 +1 @@
+<template name="error_template"><view class="js_dialog" id="iosDialog1"><view class="weui-mask"></view><view class="weui-dialog style2 rule"><view class="weui-icon_area"><view class="iconbg"></view><icon class="icon-box-img" type="warn" size="75"></icon></view><view class="weui-dialog__hd" wx:if="{{error_msg !== 'OCR识别失败' && error_msg !== '证件日期识别失败'}}"><strong class="weui-dialog__title">{{ErrorMsg}}</strong></view><view class="weui-dialog__hd" wx:else style="margin-bottom:0"><strong class="weui-dialog__title">{{ErrorMsg}}</strong><view><label style="color:#989898;" wx:if="{{error_msg == 'OCR识别失败'}}">请根据规范重新拍摄</label> <label style="color:#989898;" wx:if="{{error_msg == '证件日期识别失败'}}">请按规范重新拍摄</label><image src="https://s.beta.gtimg.com/GodIdent/huiyan-ui-new/images-wx/ocr-fail.png" style="width:100%;height:150px;margin:50rpx 0;"></image></view></view><view class="weui-dialog__ft"><view bindtap="switchDialog" class="{{Common.IsWxNative ? 'weui-dialog__btn weui-dialog__btn_primary color-green' : 'weui-dialog__btn weui-dialog__btn_primary'}}" hover-class="bg-gray">我知道了</view></view></view></view></template>

+ 1 - 0
wxcomponents/verify_mpsdk/templates/errorToast/errorToast.wxss

@@ -0,0 +1 @@
+.weui-mask { position: fixed; z-index: 1000; top: 0; right: 0; left: 0; bottom: 0; background: rgba(0, 0, 0, 0.8); } .weui-dialog { position: fixed; z-index: 5000; width:75%; max-width: 300px; top: 50%; left: 50%; -webkit-transform: translate(-50%, -50%); transform: translate(-50%, -50%); background-color: #FFFFFF; text-align: center; overflow:inherit; border-radius:5px; } .weui-dialog .weui-icon_area { position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%); font-size:0; } .weui-dialog__hd { padding: 1.3em 1.6em 0.5em; padding-top: 50px; margin-bottom: 20px; line-height: inherit; } .weui-dialog__ft { position: relative; line-height: 48px; font-size: 18px; border-top:.5px solid #ccc; } .weui-dialog__btn_primary { color: #2d72f1; } .weui-dialog .weui-icon_area .iconbg{ position: absolute; top: 10rpx; bottom:10rpx; left:10rpx; right:10rpx; background: #fff; border-radius:100%; } .weui-dialog.style2 .weui-icon_area .icon-box-img{ position: relative; } .weui-dialog__title { font-weight: 400; font-size: 18px; } .bg-gray { background: rgba(155,155,155,.1); }

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/templates/failpage/failpage.wxml


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/templates/index/index.wxml


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/templates/livingbody/livingbody.wxml


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/templates/livingbody/livingbody.wxss


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/templates/navTip/navTip.wxml


+ 1 - 0
wxcomponents/verify_mpsdk/templates/navTip/navTip.wxss

@@ -0,0 +1 @@
+#navTip { display:flex; align-items: center; flex-direction: row; padding:38rpx; font-size: 32rpx; background-color:#F4F4F4; /* border-bottom:.5px solid #ccc; */ } #navTipNative { display:flex; align-items: center; flex-direction: row; padding:38rpx; font-size: 32rpx; background-color:#F4F4F4; /* border-bottom:.5px solid #ccc; */ } #navTipNative .navActive { color: #04be02 } .navText { color:#888; font-size:12px; } .navActive { color: #0079ff; } .navLine { flex:1; width:auto; height:5px; margin: 0 10px; background:url("//3gimg.qq.com/prism_img/webapp_official/dist/ident_auth/dist/res/images/result-line-s.png") no-repeat center 0; background-size:contain; vertical-align:middle; }

+ 1 - 0
wxcomponents/verify_mpsdk/templates/notice/notice.wxml

@@ -0,0 +1 @@
+<template name="verifyNotice"><view wx:if="{{notice.title}}"><view class="verifyNotice-top-img" style="margin:155rpx auto 50rpx;"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/updating.png"></image></view><view class="verifyNotice-center"><view id="verifyNotice-center-hi" style="text-align:center; margin-bottom:8px;">{{notice.title}}</view><view id="verifyNotice-center-content" style="margin:15rpx auto;"><text decode="true">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{notice.content}}</text></view><view id="center-bottom" style="text-align: right;font-size:15px;margin-top:15px;">腾讯云智慧眼</view></view></view><view wx:else><view class="verifyNotice-top-img"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/updating.png"></image></view><view class="verifyNotice-center"><view id="verifyNotice-center-hi" style="font-size:17px;">尊敬的用户,您好!</view><view id="verifyNotice-center-content"><text decode="true">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{notice.content}}</text></view><view id="verifyNotice-center-bottom">腾讯云智慧眼</view></view></view><view class="verify-footer"><view class="verify-footer-logo" style="margin:6rpx 0;" wx:if="{{!page.index.isHideTipsLogo}}"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/hint-logo.png"></image></view></view></template>

+ 1 - 0
wxcomponents/verify_mpsdk/templates/notice/notice.wxss

@@ -0,0 +1 @@
+.verifyNotice-top-img { width:100%; margin:100rpx auto; text-align: center; } .verifyNotice-top-img image { width:155rpx;height:155rpx; } .verifyNotice-center { margin: 0 45rpx; } #verifyNotice-center-hi { /* font-size:36rpx; */ font-size:18px; } #verifyNotice-center-content { margin:45rpx auto; /* font-size:28rpx; */ /* color:#999; */ font-size:15px; color: rgb(153,153,153); } #verifyNotice-center-bottom { text-align: right; /* font-size:28rpx; */ font-size:15px; } .verifyNotice-page-foot { position: absolute;bottom:0; width:100%; text-align: center; }

+ 142 - 0
wxcomponents/verify_mpsdk/templates/ocr/ocr.wxml

@@ -0,0 +1,142 @@
+<import src="../riskTip/riskTip.wxml"></import><template name="verifyOcr">
+	<view class="verify-gray-container">
+		<view wx:if="{{!page.ocr.isManualInput && !ocr.isShowTakePhoto && !ocr.isShowResult}}" class="verify-white-bg">
+			<view id="ocr-top">
+				<view id="ocr-title">身份证识别</view>
+				<image
+					src="{{Common.IsWxNative ? '/static/verify_mpsdk/images/hint-shibieNative.png' : 'https://s.beta.gtimg.com/GodIdent/huiyan-ui-new/images-wx/hint-shibie-green.png'}}">
+				</image>
+				<view id="ocr-text"><text class="text" wx:if="{{page.ocr.backend}}">1. 拍摄身份证原件正反面</text><text
+						class="text" wx:else>1. 拍摄身份证原件正面</text><text class="text">2. 保证照片清晰文字可辨</text><text
+						class="text">3. 避免照片不全、遮挡、反光</text></view>
+				<view id="ocr-startbtn" class="{{Common.IsWxNative ? 'index-btnNative' : 'index-btn'}}"><button
+						type="primary" bindtap="ocrStartTakePhoto"
+						hover-class="{{Common.IsWxNative ? 'btn-hoverNative' : 'btn-hover'}}">开始识别</button></view>
+			</view>
+			<view class="ocr-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}"
+					data="{{riskTip: Common.RiskTip}}"></template></view>
+		</view>
+		<view wx:if="{{ocr.isShowTakePhoto && !ocr.isShowResult}}" class="verify-absolute-bg">
+			<view class="verify-absolute-bg" wx:if="{{!ocr.isShowPhotoPreView}}">
+				<view class="verify-ocr-title {{ocr.isInfinityDisplayOcrTitle}}">
+					<view class="{{Common.IsWxNative ? 'color-green' : ''}}">{{ocr.ocrTitle}}</view>
+					<view class="ocr-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}"
+							data="{{riskTip: Common.RiskTip, isCoverView: true}}"></template></view>
+				</view>
+				<camera device-position="back" flash="off" binderror="ocrCameraError"
+					class="verify-ocr-frameArea {{ocr.isInfinityDisplayOcrMiddle}}">
+					<cover-view class="vof-bg" wx:if="{{!ocr.isShowPhotoPreView}}">
+						<cover-image
+							src="{{Common.IsWxNative ? '/static/verify_mpsdk/images/shibiebgNative.png' : 'http://beta.gtimg.com/GodIdent/huiyan/img/shibiebg.png'}}"
+							class="full-weight-height"></cover-image>
+					</cover-view>
+					<cover-view wx:if="{{!ocr.isShowPhotoPreView && ocr.isFrontIdCard}}"
+						style="margin-top:80rpx;margin-left:350rpx;">
+						<cover-image src="http://beta.gtimg.com/GodIdent/huiyan/img/ico-head.png"
+							style="width:254rpx;height:285rpx;"></cover-image>
+					</cover-view>
+					<cover-view wx:if="{{!ocr.isShowPhotoPreView && !ocr.isFrontIdCard}}"
+						style="margin-top:80rpx;margin-left:90rpx;">
+						<cover-image src="http://beta.gtimg.com/GodIdent/huiyan/img/ico-guohui.png"
+							style="width:139rpx;height:144rpx:;"></cover-image>
+					</cover-view>
+				</camera>
+				<view class="verify-ocr-pre {{ocr.isInfinityDisplayOcrBottom}}">
+					<view class="verify-ocr-tools" wx:if="{{ocr.isToolsShow}}">
+						<view wx:if="{{page.ocr.sourceType > 0}}"
+							class="{{Common.IsWxNative ? 'vot-album color-green' : 'vot-album'}}" bindtap="chooseImg">相册
+						</view>
+						<view class="vot-middle">
+							<image
+								src="{{Common.IsWxNative ? '/static/verify_mpsdk/images/ico-cameNative.png' : '/static/verify_mpsdk/images/ico-came.png'}}"
+								wx:if="{{!ocr.isShowPhotoPreView}}" bindtap="takePhotoWithCamera"></image>
+						</view>
+					</view>
+				</view>
+			</view>
+			<view wx:if="{{ocr.isShowPhotoPreView}}">
+				<view class="verify-ocr-title" style="background:none">
+					<view class="{{Common.IsWxNative ? 'color-green' : ''}}">{{ocr.ocrTitle}}</view>
+					<view class="ocr-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}"
+							data="{{riskTip: Common.RiskTip}}"></template></view>
+				</view>
+				<image src="{{ocr.tempImagePath}}" mode="aspectFit" id="vof-preview"></image>
+				<view class="verify-ocr-pre">
+					<view class="verify-ocr-tools" wx:if="{{ocr.isToolsShow}}">
+						<view wx:if="{{page.ocr.sourceType > 0}}"
+							class="{{Common.IsWxNative ? 'vot-album color-green' : 'vot-album'}}" bindtap="chooseImg">相册
+						</view>
+						<view class="vot-middle">
+							<image
+								src="{{Common.IsWxNative ? '/static/verify_mpsdk/images/ico-sucNative.png' : '/static/verify_mpsdk/images/ico-suc.png'}}"
+								wx:if="{{ocr.isShowPhotoPreView}}" bindtap="startUploadAndOcr"></image>
+						</view>
+						<view wx:if="{{ocr.isShowPhotoPreView}}"
+							class="{{Common.IsWxNative ? 'vot-right color-green' : 'vot-right'}}" bindtap="reTakePhoto">
+							重拍</view>
+					</view>
+				</view>
+			</view>
+		</view>
+		<view wx:if="{{ocr.isShowResult}}">
+			<view class="ocr-result-title"
+				wx:if="{{!page.ocr.isIdnameAllowEdit && !page.ocr.isIdnumberAllowEdit && !page.ocr.isIdaddressAllowEdit}}">
+				请确认您的身份信息</view>
+			<view class="ocr-result-title" wx:else>请确认您的身份信息,若有误请手动修改</view>
+			<view id="sms-top">
+				<view class="sms-top-sec ocr-result-sec">
+					<view class="sms-input-title"><label>姓名</label></view>
+					<view class="sms-ts-input"><input type="text" bindinput="idnameInputChanged" placeholder="请输入姓名"
+							disabled="{{!page.ocr.isIdnameAllowEdit}}" value="{{ocr.idname}}" /></view>
+				</view>
+				<view class="sms-top-sec ocr-result-sec">
+					<view class="sms-input-title"><label>身份证</label></view>
+					<view class="sms-ts-input"><input type="idcard" bindinput="idcartInputChanged" maxlength="18"
+							placeholder="请输入身份证号" value="{{ocr.idcard}}" disabled="{{!page.ocr.isIdnumberAllowEdit}}" />
+					</view>
+				</view>
+				<view class="sms-top-sec ocr-result-sec" wx:if="{{page.ocr.isAddress}}">
+					<view class="sms-input-title"><label>住址</label></view>
+					<view class="sms-ts-input" style="padding:16rpx 0"><textarea type="text"
+							bindinput="idaddressInputChanged" placeholder="请输入住址" value="{{ocr.idaddress}}"
+							disabled="{{!page.ocr.isIdaddressAllowEdit}}" auto-height="true"
+							style="line-height:1.5em;min-height:1.5em;max-height:4.5em;width:100%;"
+							fixed="true"></textarea></view>
+				</view>
+			</view>
+			<view class="hint-error">{{ocr.hintErrorResult}}</view>
+			<view class="{{Common.IsWxNative ? 'index-btnNative' : 'index-btn'}}"><button type="primary"
+					bindtap="ocrInputGoNext" disabled="{{ocr.isForbiddenResultBtn}}"
+					hover-class="{{Common.IsWxNative ? 'btn-hoverNative' : 'btn-hover'}}">下一步</button></view>
+			<view class="ocr-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}"
+					data="{{riskTip: Common.RiskTip}}"></template></view>
+		</view>
+		<view wx:if="{{page.ocr.isManualInput}}">
+			<view id="sms-top">
+				<view id="sms-top-phone" class="sms-top-sec">
+					<view class="sms-ts-input"><input type="idcard" auto-focus="true"
+							bindinput="idcartManualInputChanged" maxlength="18" placeholder="请输入身份证号" /></view>
+					<view
+						class="{{Common.IsWxNative ? 'sms-ts-btn sms-ts-btn-enable color-green' : 'sms-ts-btn sms-ts-btn-enable'}}"
+						bindtap="manualInputTakePhone" wx:if="{{!page.ocr.isHideTakePhoto}}"
+						style="font-size:17px;margin-right:5px;">拍照</view>
+				</view>
+				<view class="sms-top-sec">
+					<view class="sms-ts-input"><input type="text" placeholder="请输入姓名"
+							bindinput="idnameManualInputChanged" /></view>
+				</view>
+			</view>
+			<view class="hint-error">{{ocr.hintError}}</view>
+			<view class="{{Common.IsWxNative ? 'index-btnNative' : 'index-btn'}}"><button type="primary"
+					bindtap="manualInputGoNext" disabled="{{ocr.isForbiddenManualBtn}}"
+					hover-class="{{Common.IsWxNative ? 'btn-hoverNative' : 'btn-hover'}}">下一步</button></view>
+			<view class="ocr-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}"
+					data="{{riskTip: Common.RiskTip}}"></template></view>
+		</view>
+		<view class="verify-footer" wx:if="{{!ocr.isShowTakePhoto || ocr.isShowResult}}">
+			<view class="verify-footer-logo" style="margin:6rpx 0;" wx:if="{{!page.index.isHideTipsLogo}}">
+				<image src="http://beta.gtimg.com/GodIdent/huiyan/img/hint-logo.png"></image>
+			</view>
+		</view>
+	</view>
+</template>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/templates/ocr/ocr.wxss


+ 1 - 0
wxcomponents/verify_mpsdk/templates/riskTip/riskTip.wxml

@@ -0,0 +1 @@
+<template name="riskTip"><cover-view wx:if="{{isCoverView}}" class="risk-tip">{{riskTip}}</cover-view><view wx:else class="risk-tip">{{riskTip}}</view></template>

+ 1 - 0
wxcomponents/verify_mpsdk/templates/riskTip/riskTip.wxss

@@ -0,0 +1 @@
+.risk-tip { color: #e86a2a; font-size: 24rpx; white-space: normal; text-align: left; }

+ 1 - 0
wxcomponents/verify_mpsdk/templates/showAuthToast/showAuthToast.wxml

@@ -0,0 +1 @@
+<template name="auth_template"><view class="auth-bg"></view><view class="auth-main"><view class="auth-info">{{authInfo}}</view><button open-type="openSetting" class="auth-btn-set"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/icon42_appwx_logo.png"></image>打开授权设置</button></view></template>

+ 1 - 0
wxcomponents/verify_mpsdk/templates/showAuthToast/showAuthToast.wxss

@@ -0,0 +1 @@
+.auth-bg { position:fixed;top:0;bottom:0;z-index:999; width:100%;background:rgba(0,0,0,.37); } .auth-main { position:absolute;top:250rpx;left:50%;z-index:1002; width:250px; margin-left:-140px;padding:15px; text-align:center;background:#fff; } .auth-info { padding:10px 0;font-size:13px; animation: upAndDown 1s linear infinite alternate; color:green; } /* @keyframes upAndDown { 0% {margin-left:-20px;} 100% {margin-left:20px;} } */ .auth-btn-set { display:flex;align-items:center; width:178px;height:45px; padding:0;margin:15px auto ; font-size:15px;color:#fff; background-color:rgb(0,190,42); } .auth-btn-set image { width:28px;height:28px;margin:0 6px 0 14px } .auth-btn-ok { display:flex;align-items:center;justify-content:center; width:178px;height:45px; padding:0;margin:10px auto; font-size:15px;color:#000;background-color:#ddd; }

+ 1 - 0
wxcomponents/verify_mpsdk/templates/sms/sms.wxml

@@ -0,0 +1 @@
+<import src="../riskTip/riskTip.wxml"></import><template name="verifySms"><view class="verify-gray-container"><view id="sms-top"><view id="sms-top-phone" class="sms-top-sec"><view class="sms-ts-img"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/icon-phonenum.png"></image></view><view class="sms-ts-input"><input type="number" auto-focus="true" name="phoneNum" bindinput="phoneNumChanged" maxlength="11" placeholder="请输入手机号码"/></view><view wx:if="{{sms.is60sGap}}"><view class="sms-ts-btn">重新发送 ({{sms.gapSec}}s)</view></view><view wx:else><view class="sms-ts-btn sms-ts-btn-enable" wx:if="{{sms.isEnableSendSms}}" bindtap="sendVerifyCodeReq">{{sms.sendSmsTtitle}}</view><view class="sms-ts-btn" wx:else>{{sms.sendSmsTtitle}}</view></view></view><view class="sms-top-sec"><view class="sms-ts-img"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/icon-yzm.png"></image></view><view class="sms-ts-input"><input type="number" name="verifyCode" maxlength="4" placeholder="请输入验证码" bindinput="verifyCodeChanged"/></view></view></view><view class="hint-error">{{sms.hintError}}</view><view class="index-btn"><button type="primary" bindtap="smsToNext" disabled="{{sms.isForbiddenSmsBtn}}" hover-class="btn-hover">下一步</button></view><view class="index-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}" data="{{riskTip: Common.RiskTip}}"></template></view><view class="verify-footer"><view class="verify-footer-logo" style="margin:6rpx 0;" wx:if="{{!page.index.isHideTipsLogo}}"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/hint-logo.png"></image></view></view></view></template>

+ 1 - 0
wxcomponents/verify_mpsdk/templates/sms/sms.wxss

@@ -0,0 +1 @@
+#sms-top { width:100%;background:#fff; } .sms-top-sec { display:flex;align-items:center; flex-direction:row; height:52px; padding:0 15px; } #sms-top-phone { border-bottom:1px solid rgb(228,228,228); } .sms-ts-img { display:flex;align-items:center; } .sms-ts-img image{ height:25px;width:20px; margin-right:16px; } .sms-ts-input { flex:1; } .sms-ts-btn { min-width:100px; text-align:right;font-size:14px; color:#888; padding: 10px 0; } .sms-ts-btn-enable { color: #2d72f1; }

+ 1 - 0
wxcomponents/verify_mpsdk/templates/success/success.wxml

@@ -0,0 +1 @@
+<import src="../riskTip/riskTip.wxml"></import><template name="verifySuccessPage"><view class="verifyResultTop"><icon type="success" size="75"></icon></view><view class="verifyResultSuccess">{{page.success.successTitle}}</view><view class="verifyResultHint">{{page.success.successTips}}</view><view class="verifyResultHint">{{page.success.successTips2}}</view><view class="index-btn" style="margin-top:135rpx"><button type="primary" bindtap="successGoToNext" hover-class="btn-hover" style="width:674rpx">下一步</button></view><view class="index-risk-tip"><template is="riskTip" wx:if="{{Common.RiskTip}}" data="{{riskTip: Common.RiskTip}}"></template></view><view class="verify-footer"><view class="verify-footer-logo" style="margin:6rpx 0;" wx:if="{{!page.index.isHideTipsLogo}}"><image src="http://beta.gtimg.com/GodIdent/huiyan/img/hint-logo.png"></image></view></view></template>

+ 1 - 0
wxcomponents/verify_mpsdk/templates/success/success.wxss

@@ -0,0 +1 @@
+.verifyResultTop{ width:100%;margin-top:160rpx;margin-bottom:60rpx;text-align:center; } .verifyResultSuccess { width:100%;text-align:center;font-weight:400;font-size:17px;margin-bottom:5px; } .verifyResultHint { text-align:center;font-size:14px;color:#999999; padding:0 20px; }

+ 1 - 0
wxcomponents/verify_mpsdk/utils/extend.js

@@ -0,0 +1 @@
+var getProto=Object.getPrototypeOf||function(t){return t.__proto__},hasOwn=Object.prototype.hasOwnProperty,fnToString=hasOwn.toString,ObjectFunctionString=fnToString.call(Object),isPlainObject=function(t){var n,o;return!(!t||"[object Object]"!==toString.call(t))&&(!(n=getProto(t))||"function"==typeof(o=hasOwn.call(n,"constructor")&&n.constructor)&&fnToString.call(o)===ObjectFunctionString)},isFunction=function(t){return"function"==typeof t},extend=function(){var t,n,o,r,e,i,c=arguments[0]||{},a=1,u=arguments.length,f=!1;for("boolean"==typeof c&&(f=c,c=arguments[a]||{},a++),"object"==typeof c||isFunction(c)||(c={}),a===u&&(c=this,a--);a<u;a++)if(null!=(t=arguments[a]))for(n in t)o=c[n],c!==(r=t[n])&&(f&&r&&(isPlainObject(r)||(e=Array.isArray(r)))?(e?(e=!1,i=o&&Array.isArray(o)?o:[]):i=o&&isPlainObject(o)?o:{},c[n]=extend(f,i,r)):void 0!==r&&(c[n]=r));return c};module.exports={extend:extend};

+ 1 - 0
wxcomponents/verify_mpsdk/utils/regenerator-runtime/path.js

@@ -0,0 +1 @@
+exports.path=require("path").join(__dirname,"runtime.js");

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/utils/regenerator-runtime/runtime.js


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
wxcomponents/verify_mpsdk/utils/util.js


Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio