package cn.iocoder.yudao.module.system.api.user.dto;
|
|
import io.swagger.v3.oas.annotations.media.Schema;
|
import jakarta.validation.constraints.NotEmpty;
|
import jakarta.validation.constraints.NotNull;
|
import lombok.Data;
|
|
import java.util.Set;
|
|
/**
|
* Admin 用户创建 Request DTO
|
*/
|
@Schema(description = "管理后台 - 用户创建 Request DTO")
|
@Data
|
public class AdminUserCreateReqDTO {
|
|
@Schema(description = "用户账号", requiredMode = Schema.RequiredMode.REQUIRED, example = "zhangsan")
|
@NotEmpty(message = "用户账号不能为空")
|
private String username;
|
|
@Schema(description = "用户昵称", requiredMode = Schema.RequiredMode.REQUIRED, example = "张三")
|
@NotEmpty(message = "用户昵称不能为空")
|
private String nickname;
|
|
@Schema(description = "部门编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
|
@NotNull(message = "部门编号不能为空")
|
private Long deptId;
|
|
@Schema(description = "岗位编号数组", requiredMode = Schema.RequiredMode.REQUIRED, example = "[1]")
|
@NotNull(message = "岗位编号不能为空")
|
private Set<Long> postIds;
|
|
@Schema(description = "角色编号数组", example = "[1, 2]")
|
private Set<Long> roleIds;
|
|
@Schema(description = "手机号码", requiredMode = Schema.RequiredMode.REQUIRED, example = "15601691300")
|
@NotEmpty(message = "手机号码不能为空")
|
private String mobile;
|
|
@Schema(description = "密码", requiredMode = Schema.RequiredMode.REQUIRED, example = "123456")
|
@NotEmpty(message = "密码不能为空")
|
private String password;
|
|
@Schema(description = "用户性别", example = "1")
|
private Integer sex;
|
|
@Schema(description = "用户邮箱", example = "zhangsan@example.com")
|
private String email;
|
|
@Schema(description = "用户头像", example = "https://www.iocoder.cn/xxx.png")
|
private String avatar;
|
|
@Schema(description = "备注", example = "备注信息")
|
private String remark;
|
|
}
|