diff --git a/mobile/src/locale/en.json b/mobile/src/locale/en.json index 12505a46d6..a7b72f12c3 100644 --- a/mobile/src/locale/en.json +++ b/mobile/src/locale/en.json @@ -30,7 +30,8 @@ "passwordPlaceholder": "Please Input Password:", "loginbtn": "Login", "pwdFmtError": "Password Must More Than 6 Characters", - "uOrpwdError": "Invalid Account Or Password" + "uOrpwdError": "Invalid Account Or Password", + "accFmtError": "Account Must More Than 1 Characters" }, "home": { "tab1": "My Favorites", diff --git a/mobile/src/locale/zh-Hans.json b/mobile/src/locale/zh-Hans.json index 780d06d6d6..afaed12e0f 100644 --- a/mobile/src/locale/zh-Hans.json +++ b/mobile/src/locale/zh-Hans.json @@ -29,7 +29,8 @@ "password": "密码:", "passwordPlaceholder": "请输入密码", "loginbtn": "登录", - "pwdFmtError": "密码最短为6个字符", + "pwdFmtError": "密码最短为1个字符", + "accFmtError": "账号最短为1个字符", "uOrpwdError": "无效账号或密码" }, "home": { diff --git a/mobile/src/locale/zh-Hant.json b/mobile/src/locale/zh-Hant.json index e2ca5b6406..a3b8f5f97c 100644 --- a/mobile/src/locale/zh-Hant.json +++ b/mobile/src/locale/zh-Hant.json @@ -31,7 +31,8 @@ "passwordPlaceholder": "請輸入密碼", "loginbtn": "登錄", "pwdFmtError": "密碼最短為6個字符", - "uOrpwdError": "無效賬號或密碼" + "uOrpwdError": "無效賬號或密碼", + "accFmtError": "帳號最短為1個字符" }, "home": { "tab1": "我的收藏", diff --git a/mobile/src/pages/login/index.vue b/mobile/src/pages/login/index.vue index b3a741575b..5b10f91ac3 100644 --- a/mobile/src/pages/login/index.vue +++ b/mobile/src/pages/login/index.vue @@ -67,17 +67,17 @@ async loginByPwd() { - if (this.username.length < 3) { + if (this.username.length < 1) { uni.showToast({ icon: 'none', - title: '账号最短为 3 个字符' + title: this.$t('login.accFmtError') }); return; } - if (this.password.length < 6) { + if (this.password.length < 1) { uni.showToast({ icon: 'none', - title: this.$t('login.pwdFmtError') + title: this.$t('login.passwordPlaceholder') }); return; }