From 58b4600144358595317a82a6000b7d1ee5e1acae Mon Sep 17 00:00:00 2001 From: RuoYi Date: Fri, 25 Jun 2021 17:41:40 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E6=88=B7=E4=BF=A1=E6=81=AF=E9=95=BF?= =?UTF-8?q?=E5=BA=A6=E6=A0=A1=E9=AA=8C=E9=99=90=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/views/system/user/index.vue | 14 +++++++++----- .../src/views/system/user/profile/userInfo.vue | 2 +- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/ruoyi-ui/src/views/system/user/index.vue b/ruoyi-ui/src/views/system/user/index.vue index 2aa9a08f8..4a10bf2ae 100644 --- a/ruoyi-ui/src/views/system/user/index.vue +++ b/ruoyi-ui/src/views/system/user/index.vue @@ -209,7 +209,7 @@ - + @@ -233,12 +233,12 @@ - + - + @@ -437,7 +437,8 @@ export default { { required: true, message: "用户昵称不能为空", trigger: "blur" } ], password: [ - { required: true, message: "用户密码不能为空", trigger: "blur" } + { required: true, message: "用户密码不能为空", trigger: "blur" }, + { min: 5, max: 20, message: '用户密码长度必须介于 5 和 20 之间', trigger: 'blur' } ], email: [ { @@ -589,7 +590,10 @@ export default { handleResetPwd(row) { this.$prompt('请输入"' + row.userName + '"的新密码', "提示", { confirmButtonText: "确定", - cancelButtonText: "取消" + cancelButtonText: "取消", + closeOnClickModal: false, + inputPattern: /^.{5,20}$/, + inputErrorMessage: "用户密码长度必须介于 5 和 20 之间", }).then(({ value }) => { resetUserPwd(row.userId, value).then(response => { this.msgSuccess("修改成功,新密码是:" + value); diff --git a/ruoyi-ui/src/views/system/user/profile/userInfo.vue b/ruoyi-ui/src/views/system/user/profile/userInfo.vue index d52137dc8..621a1a3a9 100644 --- a/ruoyi-ui/src/views/system/user/profile/userInfo.vue +++ b/ruoyi-ui/src/views/system/user/profile/userInfo.vue @@ -1,7 +1,7 @@