5 changed files with 254 additions and 15 deletions
-
26chenhai-admin/src/main/java/com/chenhai/web/controller/auth/MultiAuthController.java
-
5chenhai-common/src/main/java/com/chenhai/common/constant/Constants.java
-
58chenhai-common/src/main/java/com/chenhai/common/core/domain/model/VetRegisterBody.java
-
13chenhai-framework/src/main/java/com/chenhai/framework/security/provider/PhoneAuthenticationProvider.java
-
151chenhai-framework/src/main/java/com/chenhai/framework/web/service/SysLoginService.java
@ -0,0 +1,58 @@ |
|||
package com.chenhai.common.core.domain.model; |
|||
|
|||
import jakarta.validation.constraints.NotBlank; |
|||
import jakarta.validation.constraints.Pattern; |
|||
import jakarta.validation.constraints.Size; |
|||
|
|||
/** |
|||
* 兽医PC端注册请求 |
|||
*/ |
|||
public class VetRegisterBody { |
|||
|
|||
@NotBlank(message = "手机号不能为空") |
|||
@Pattern(regexp = "^1[3-9]\\d{9}$", message = "手机号格式不正确") |
|||
private String phone; |
|||
|
|||
@NotBlank(message = "密码不能为空") |
|||
@Size(min = 6, max = 20, message = "密码长度6-20位") |
|||
private String password; |
|||
|
|||
@NotBlank(message = "确认密码不能为空") |
|||
private String confirmPassword; |
|||
|
|||
// 客户端类型固定为 vet-pc |
|||
private String clientType = "vet-pc"; |
|||
|
|||
// getters and setters |
|||
public String getPhone() { |
|||
return phone; |
|||
} |
|||
|
|||
public void setPhone(String phone) { |
|||
this.phone = phone; |
|||
} |
|||
|
|||
public String getPassword() { |
|||
return password; |
|||
} |
|||
|
|||
public void setPassword(String password) { |
|||
this.password = password; |
|||
} |
|||
|
|||
public String getConfirmPassword() { |
|||
return confirmPassword; |
|||
} |
|||
|
|||
public void setConfirmPassword(String confirmPassword) { |
|||
this.confirmPassword = confirmPassword; |
|||
} |
|||
|
|||
public String getClientType() { |
|||
return clientType; |
|||
} |
|||
|
|||
public void setClientType(String clientType) { |
|||
this.clientType = clientType; |
|||
} |
|||
} |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue