|
@@ -5,6 +5,7 @@ import io.swagger.annotations.ApiModelProperty;
|
|
|
import lombok.Data;
|
|
|
|
|
|
import javax.validation.constraints.NotEmpty;
|
|
|
+import javax.validation.constraints.Pattern;
|
|
|
import java.io.Serializable;
|
|
|
|
|
|
/**
|
|
@@ -26,6 +27,7 @@ public class CreateUserReq implements Serializable {
|
|
|
@ApiModelProperty(value = "邮箱")
|
|
|
private String email;
|
|
|
|
|
|
+ @Pattern(regexp = "^1[0-9]{10}$", message = "手机格式不正确,请重新输入")
|
|
|
@ApiModelProperty(value = "手机号")
|
|
|
private String phone;
|
|
|
|