66 lines
2.0 KiB
Java
66 lines
2.0 KiB
Java
package tech.riemann.ims.entity.acl;
|
|
|
|
import org.nutz.dao.entity.annotation.ColDefine;
|
|
import org.nutz.dao.entity.annotation.Column;
|
|
import org.nutz.dao.entity.annotation.Comment;
|
|
import org.nutz.dao.entity.annotation.Table;
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableField;
|
|
import com.baomidou.mybatisplus.annotation.TableName;
|
|
|
|
import io.swagger.v3.oas.annotations.media.Schema;
|
|
import io.swagger.v3.oas.annotations.media.Schema.RequiredMode;
|
|
import lombok.AllArgsConstructor;
|
|
import lombok.Data;
|
|
import lombok.EqualsAndHashCode;
|
|
import lombok.NoArgsConstructor;
|
|
import lombok.experimental.FieldNameConstants;
|
|
import lombok.experimental.SuperBuilder;
|
|
import tech.riemann.ims.entity.IdBaseEntity;
|
|
|
|
import java.io.Serial;
|
|
|
|
/**
|
|
* 角色
|
|
*
|
|
* @author Kerbores(kerbores@gmail.com)
|
|
*
|
|
* @since 2024-07-22 13:56:54
|
|
*/
|
|
@Data
|
|
@SuperBuilder
|
|
@NoArgsConstructor
|
|
@AllArgsConstructor
|
|
@FieldNameConstants
|
|
@EqualsAndHashCode(callSuper = true)
|
|
@TableName(value = "t_role", autoResultMap = true)
|
|
@Table("t_role")
|
|
@Comment("角色")
|
|
@Schema(name = "Role", description = "角色")
|
|
public class Role extends IdBaseEntity {
|
|
|
|
@Serial
|
|
private static final long serialVersionUID = 1L;
|
|
|
|
@Schema(description = "角色key,英文,用来做业务", requiredMode = RequiredMode.REQUIRED)
|
|
@TableField("r_key")
|
|
@Column("r_key")
|
|
@Comment("角色key,英文,用来做业务")
|
|
@ColDefine(notNull = true, width = 128, precision = 0)
|
|
private String key;
|
|
|
|
@Schema(description = "角色名称,中文用来做标识", requiredMode = RequiredMode.NOT_REQUIRED)
|
|
@TableField("r_name")
|
|
@Column("r_name")
|
|
@Comment("角色名称,中文用来做标识")
|
|
@ColDefine(notNull = false, width = 128, precision = 0)
|
|
private String name;
|
|
|
|
@Schema(description = "角色描述", requiredMode = RequiredMode.NOT_REQUIRED)
|
|
@TableField("r_description")
|
|
@Column("r_description")
|
|
@Comment("角色描述")
|
|
@ColDefine(notNull = false, width = 128, precision = 0)
|
|
private String description;
|
|
}
|