package com.aiotagro.cattletrade.business.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * <p>
 * 岗位管理表
 * </p>
 *
 * @author admin
 * @since 2024-12-07
 */
@Getter
@Setter
@TableName("sys_role")
public class SysRole implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 岗位名称
     */
    @TableField("name")
    private String name;

    /**
     * 岗位描述
     */
    @TableField("description")
    private String description;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @TableField("create_time")
    private Date createTime;

    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @TableField("update_time")
    private Date updateTime;

    /**
     * 是否删除 0-未删除  1-已删除
     */
    @TableLogic("is_delete")
    private Integer isDelete;

    /**
     * 菜单id
     */
    @TableField(exist = false)
    private List<Integer> menuIds;

    /**
     * 菜单
     */
    @TableField(exist = false)
    private List<SysMenu> menuList;
}
