zyx 2 gadi atpakaļ
vecāks
revīzija
e70b24a5c3
2 mainītis faili ar 8 papildinājumiem un 12 dzēšanām
  1. 5 10
      pages/public/register.vue
  2. 3 2
      pages/user/set/password.vue

+ 5 - 10
pages/public/register.vue

@@ -158,10 +158,6 @@
 						return;
 					}
 				}
-				// if (!/(^1[3|4|5|7|8][0-9]{9}$)/.test(this.account)) {
-				// 	obj.$api.msg('请输入正确的手机号');
-				// 	return;
-				// }
 				if (obj.password == '') {
 					obj.$api.msg(obj.$t("reg.a9"));
 					return;
@@ -172,7 +168,6 @@
 				}
 
 				register({
-					// account: obj.account, //账号
 					account: obj.account, //账号
 					captcha: obj.captcha, //验证码
 					password: obj.password, //密码
@@ -180,15 +175,15 @@
 					spread: this.spread //上级推广人
 				}).then(function(e) {
 					uni.showToast({
-						title: this.$t("reg.c5"),
+						title: obj.$t("reg.c5"),
 						duration: 2000,
 						position: 'top'
 					});
 					uni.showModal({
-						title: this.$t("enter.a7"),
-						content: this.$t("login.c3"),
-						cancelText: this.$t("zy.b4"),
-						confirmText: this.$t("zy.b3"),
+						title: obj.$t("enter.a7"),
+						content: obj.$t("login.c3"),
+						cancelText: obj.$t("zy.b4"),
+						confirmText: obj.$t("zy.b3"),
 						success: res => {
 							if(res.confirm){
 								uni.navigateTo({

+ 3 - 2
pages/user/set/password.vue

@@ -63,7 +63,8 @@ export default {
 			if (!/(^1[3|4|5|7|8][0-9]{9}$)/.test(this.account)) {
 				this.$api.msg(obj.$t("safe.b8"));
 				return;
-			}
+			} 
+			
 			// 判断是否在倒计时
 			if (obj.countDown > 0) {
 				return false;
@@ -82,7 +83,7 @@ export default {
 						console.log(err);
 					});
 			}
-		},
+		},
 		confirm(e) {
 			this.loding = true;
 			registerReset({