From d3d59e8e457ab525c67e917a12c73b35196b10a8 Mon Sep 17 00:00:00 2001 From: shijie <648688341@qq.com> Date: Mon, 1 Mar 2021 09:58:31 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B4=A6=E5=8F=B7=E6=A0=A1=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/msdw/tms/entity/UserInfoEntity.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/msdw/tms/entity/UserInfoEntity.java b/src/main/java/com/msdw/tms/entity/UserInfoEntity.java index a0f2a63..095478d 100644 --- a/src/main/java/com/msdw/tms/entity/UserInfoEntity.java +++ b/src/main/java/com/msdw/tms/entity/UserInfoEntity.java @@ -17,7 +17,8 @@ public class UserInfoEntity { //用户姓名 private String userName; //用户账号 - @Pattern(regexp = "/^[1-9]([0-9]{1,5})?$/", message = "账号只能为数字!") + //@Pattern(regexp = "/^[1-9]([0-9]{1,5})?$/", message = "账号只能为数字!") + @Pattern(regexp = "^[0-9a-zA-Z]*$",message = "账号只能为数字或字母!") private String account; //用户密码 private String password;