package cn.ey.biz.module.system.controller.admin.delegation.vo;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

/**
 * 代理人代理单元 Base VO，提供给添加、修改、详细的子 VO 使用
 * 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
 */
@Data
public class UserDelegationUnitBaseVO {

    @ApiModelProperty(value = "应用ID", example = "timesheet", required = true)
    @Size(max = 30, message = "应用ID长度不能超过30个字符")
    private String appId;

    @ApiModelProperty(value = "用户ID",example = "1", required = true)
    private Long userId;

    @ApiModelProperty(value = "用户姓名", example = "Peter(131).Du", notes = "姓名内容组合")
    private String userName;

    @ApiModelProperty(value = "代理人GPN", example = "XE030018616", required = true)
    @Size(max = 16, message = "代理人GPN长度不能超过16个字符")
    private String gpn;

    @ApiModelProperty(value = "代理人email", example = "xxx@ey.com")
    @Size(max = 50, message = "email长度不能超过50个字符")
    private String email;

    @ApiModelProperty(value = "分类", required = true, example = "01-rank/02-mu/03-smu/04-OU", notes = "参见 DelegationEnum 枚举类")
    @NotBlank(message = "分类不能为空")
    @Size(max = 30, message = "分类长度不能超过30个字符")
    private String type;

    @ApiModelProperty(value = "关系描述value json值", example = "[[\"1\",\"10\"],[\"2\",\"20\"]]", notes = "选中代理单元value json值")
    private String relation;


}
