package com.sy.coinage.sys.req;

import com.sy.coinage.core.interceptor.Update;
import io.swagger.annotations.ApiModelProperty;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

@Data
public class AdminDictReq {

    /**
     * 自增主键 -10
     */
    @ApiModelProperty(value = "自增主键，修改必填")
    @NotNull(message = "自增主键不能为空", groups = {Update.class})
    @Range(min = 1, groups = {Update.class})
    private Integer id;

    @ApiModelProperty(value = "排序")
    private Integer sorted;
    /**
     * 上级id
     */
    @ApiModelProperty(value = "上级id")
    private Integer pid;

    @ApiModelProperty(value = "字典名称")
    @NotBlank(message = "字典名称不能为空")
    private String name;

    /**
     * 字典值
     */
    @ApiModelProperty(value = "字典值")
    private String val;

    /**
     * 字典标识
     */
    @ApiModelProperty(value = "字典标识")
    private String tag;

    @ApiModelProperty(value = "租户id")
    @NotNull(message = "租户id不能为空")
    private Integer tenantId;

}
