package com.chushang.system.entity.po;

import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.*;
import com.chushang.common.excel.utils.ExcelUtils;
import com.chushang.common.mybatis.base.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serial;
import java.io.Serializable;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("sys_dict_data")
public class SysDictData extends BaseEntity {
    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 字典编码
     */
    @TableId(value = "dict_code", type = IdType.ASSIGN_ID)
    @ExcelProperty(value = "字典编码", index = 0)
    private Long dictCode;

    /**
     * 字典排序
     */
    @ExcelProperty(value = "字典排序", index = 1)
    private Integer dictSort;

    /**
     * 字典标签
     */
    @ExcelProperty(value = "字典标签", index = 2)
    private String dictLabel;

    /**
     * 字典键值
     */
    @ExcelProperty(value = "字典键值", index = 3)
    private String dictValue;

    /**
     * 字典类型
     */
    @ExcelProperty(value = "字典键值", index = 4)
    private String dictType;

    /**
     * 样式属性（其他样式扩展）
     */
    @ExcelProperty(value = "样式属性（其他样式扩展）", index = 5)
    private String cssClass;

    /**
     * 表格字典样式
     */
    @ExcelProperty(value = "表格字典样式", index = 6)
    private String listClass;

    /**
     * 是否默认（Y是 N否）
     */
    @ExcelProperty(value = "是否默认", index = 7)
    private String isDefault;

    /**
     * 状态（1正常 0停用）
     * true 正常, false 停用
     */
    @ExcelProperty(value = "状态", index = 8)
    private Boolean status;

    /**
     * 创建人
     */
    @TableField(
            value = "create_by",
            updateStrategy = FieldStrategy.NEVER
    )
    protected String createBy;
    /**
     * 修改人
     */
    @TableField(
            value = "update_by",
            insertStrategy = FieldStrategy.NEVER
    )
    protected String updateBy;

}
