zhang 1 rok pred
rodič
commit
6c29cb4919

+ 3 - 4
.gitignore

@@ -1,5 +1,4 @@
-/unpackage/dist
-/unpackage/chart
-/unpackage
-/.hbuilderx
+/unpackage/dist
+/unpackage/chart
+/.hbuilderx
 /node_modules

+ 123 - 123
components/input-password/input-password.vue

@@ -1,124 +1,124 @@
-<template>
-	<view class="page">
-		<view>
-			<view class="pay-title">
-				<text>{{$t('enter.b3')}}</text>
-			</view>
-			<view class="pay-password">
-				<view class="list" v-for="item in 6">
-					<text v-show="passwordArr.length >= item">●</text>
-				</view>
-			</view>
-			<navigator url="/pages/user/set/transaction">
-				<view class="hint">
-					<text>忘记支付密码?</text>
-				</view>
-			</navigator>
-		</view>
-		<cc-defineKeyboard ref="CodeKeyboard" passwrdType="pay" @KeyInfo="KeyInfo" :viewShow="true"></cc-defineKeyboard>
-	</view>
-</template>
-
-<script>
-	export default {
-		data() {
-			return {
-				passwordArr: []
-			};
-		},
-		mounted() {
-			this.$refs.CodeKeyboard.show();
-		},
-		// 关闭循环
-		methods: {
-			// 点击触发支付事件
-			KeyInfo(val) {
-				console.log(val);
-				let arr = this.passwordArr;
-				if (val.index >= 6) {
-					return;
-				}
-				// 判断是否输入的是删除键
-				if (val.keyCode === 8) {
-					// 删除最后一位
-					arr.splice(val.index + 1, 1)
-				}
-				// 判断是否输入的是取消案件
-				else if (val.keyCode == 190) {
-					this.colsePayPassword();
-					// 输入.无效
-				} else {
-					arr.push(val.key);
-				}
-				// 开始交易
-				if (arr.length == 6) {
-					this.$emit('commit',this.passwordArr.join(''))
-					//初始化对象
-					this.passwordArr = [];
-				}
-			},
-		},
-	};
-</script>
-
-<style lang="scss">
-	$base: orangered; // 基础颜色
-
-	.page {
-		width: 100%;
-		background-color: #FFFFFF;
-
-		.pay-title {
-			display: flex;
-			align-items: center;
-			justify-content: center;
-			width: 100%;
-			height: 200rpx;
-
-			text {
-				font-size: 28rpx;
-				color: #555555;
-			}
-		}
-
-		.pay-password {
-			display: flex;
-			align-items: center;
-			width: 90%;
-			height: 80rpx;
-			margin: 20rpx auto;
-			border: 2rpx solid $base;
-
-			.list {
-				color: #555555;
-				display: flex;
-				align-items: center;
-				justify-content: center;
-				width: 16.666%;
-				height: 100%;
-				border-right: 2rpx solid #EEEEEE;
-
-				text {
-					font-size: 32rpx;
-				}
-			}
-
-			.list:nth-child(6) {
-				border-right: none;
-			}
-		}
-
-		.hint {
-			display: flex;
-			align-items: center;
-			justify-content: center;
-			width: 100%;
-			height: 100rpx;
-
-			text {
-				font-size: 28rpx;
-				color: $base;
-			}
-		}
-	}
+<template>
+	<view class="page">
+		<view>
+			<view class="pay-title">
+				<text>{{$t('enter.b3')}}</text>
+			</view>
+			<view class="pay-password">
+				<view class="list" v-for="item in 6">
+					<text v-show="passwordArr.length >= item">●</text>
+				</view>
+			</view>
+			<navigator url="/pages/user/set/transaction">
+				<view class="hint">
+					<text>{{$t('login.b8')}}</text>
+				</view>
+			</navigator>
+		</view>
+		<cc-defineKeyboard ref="CodeKeyboard" passwrdType="pay" @KeyInfo="KeyInfo" :viewShow="true"></cc-defineKeyboard>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				passwordArr: []
+			};
+		},
+		mounted() {
+			this.$refs.CodeKeyboard.show();
+		},
+		// 关闭循环
+		methods: {
+			// 点击触发支付事件
+			KeyInfo(val) {
+				console.log(val);
+				let arr = this.passwordArr;
+				if (val.index >= 6) {
+					return;
+				}
+				// 判断是否输入的是删除键
+				if (val.keyCode === 8) {
+					// 删除最后一位
+					arr.splice(val.index + 1, 1)
+				}
+				// 判断是否输入的是取消案件
+				else if (val.keyCode == 190) {
+					this.colsePayPassword();
+					// 输入.无效
+				} else {
+					arr.push(val.key);
+				}
+				// 开始交易
+				if (arr.length == 6) {
+					this.$emit('commit',this.passwordArr.join(''))
+					//初始化对象
+					this.passwordArr = [];
+				}
+			},
+		},
+	};
+</script>
+
+<style lang="scss">
+	$base: orangered; // 基础颜色
+
+	.page {
+		width: 100%;
+		background-color: #FFFFFF;
+
+		.pay-title {
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			width: 100%;
+			height: 200rpx;
+
+			text {
+				font-size: 28rpx;
+				color: #555555;
+			}
+		}
+
+		.pay-password {
+			display: flex;
+			align-items: center;
+			width: 90%;
+			height: 80rpx;
+			margin: 20rpx auto;
+			border: 2rpx solid $base;
+
+			.list {
+				color: #555555;
+				display: flex;
+				align-items: center;
+				justify-content: center;
+				width: 16.666%;
+				height: 100%;
+				border-right: 2rpx solid #EEEEEE;
+
+				text {
+					font-size: 32rpx;
+				}
+			}
+
+			.list:nth-child(6) {
+				border-right: none;
+			}
+		}
+
+		.hint {
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			width: 100%;
+			height: 100rpx;
+
+			text {
+				font-size: 28rpx;
+				color: $base;
+			}
+		}
+	}
 </style>

+ 3 - 1
libs/i18n/lang/cn.json

@@ -506,7 +506,9 @@
 		"b4": "请输入邀请码",
 		"b5": "发送验证码",
 		"b6": "请输入验证码",
-		"b7": "确定要退出登录吗?"
+		"b7": "确定要退出登录吗?",
+		"b8": "忘记支付密码?",
+		"b9": "请输入正确的邮箱地址"
 	}
 	
 }

+ 3 - 1
libs/i18n/lang/en.json

@@ -596,6 +596,8 @@
 		"b4": "Please enter a invitation code",
 		"b5": "Send code",
 		"b6": "Please enter code",
-		"b7": "Are you sure you want to log out"
+		"b7": "Are you sure you want to log out",
+		"b8": "Forgot payment password?",
+		"b9": "Please enter the correct email address"
 	}
 }

+ 3 - 1
libs/i18n/lang/tw.json

@@ -593,6 +593,8 @@
 		"b4": "請輸入邀請碼",
 		"b5": "发送驗證碼",
 		"b6": "請輸入驗證碼",
-		"b7": "確定要退出登錄嗎?"
+		"b7": "確定要退出登錄嗎?",
+		"b8": "忘記支付密碼?",
+		"b9": "請輸入正確的郵箱地址"
 	}
 }

+ 6 - 6
pages/public/register.vue

@@ -108,17 +108,17 @@
 			register() {
 				let obj = this;
 				if (obj.account == '') {
-					obj.$api.msg('请输入手机号/邮箱');
+					obj.$api.msg(obj.$t("login.a1"));
 					return;
 				}
 				if (this.isPhone) {
 				      if (!/^1[3|4|5|7|8][0-9]{9}$/.test(this.account)) {
-				        this.$api.msg('请输入正确的手机号');
+				        this.$api.msg(obj.$t("safe.b8"));
 				        return;
 				      }
 				    } else {
 				      if (!/^[\w-]+(\.[\w-]+)*@([\w-]+\.)+[a-zA-Z]{2,7}$/.test(this.account)) {
-				        this.$api.msg('请输入正确的邮箱地址');
+				        this.$api.msg(obj.$t("login.b9"));
 				        return;
 				      }
 				    }
@@ -127,11 +127,11 @@
 				// 	return;
 				// }
 				if (obj.password == '') {
-					obj.$api.msg('请输入密码');
+					obj.$api.msg(obj.$t("reg.a9"));
 					return;
 				}
 				if (obj.trade_password == '') {
-					obj.$api.msg('请输入交易密码');
+					obj.$api.msg(obj.$t("login.b3"));
 					return;
 				}
 
@@ -144,7 +144,7 @@
 					spread: this.spread //上级推广人
 				}).then(function(e) {
 					uni.showToast({
-						title: '注册成功',
+						title: this.$t("reg.c5"),
 						duration: 2000,
 						position: 'top'
 					});

+ 7 - 7
uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json

@@ -1,7 +1,7 @@
-{
-	"uni-popup.cancel": "取消",
-	"uni-popup.ok": "确定",
-	"uni-popup.placeholder": "请输入",
-		"uni-popup.title": "提示",
-		"uni-popup.shareTitle": "分享到"
-}
+{
+	"uni-popup.cancel": "取消",
+	"uni-popup.ok": "确定",
+	"uni-popup.placeholder": "请输入",
+		"uni-popup.title": "提示",
+		"uni-popup.shareTitle": "分享到"
+}