package com.bonus.sgzb.base.api.domain;

import com.bonus.sgzb.common.core.annotation.Excel;
import com.bonus.sgzb.common.core.web.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.List;

/**
 * 数据字典对象 sys_dic
 *
 * @author bonus
 * @date 2023-12-11
 */
public class SysDic extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * $column.columnComment
     */
    private Long id;

    /**
     * 父id
     */
    private Long pId;

    /**
     * 编码
     */
    private String code;

    /**
     * 字典名称
     */
    @Excel(name = "单位类型")
    private String name;

    /**
     * 描述
     */
    private String description;

    /**
     * 值
     */
    private String value;

    /**
     * 排序
     */
    private String sort;

    /**
     * 层级
     */
    private String level;

    /**
     * o/null: 默认,需要鉴权, 1: 跳过鉴权
     */
    private Integer skipPermission;

    /**
     * 状态
     */
    @Excel(name = "状态", readConverterExp = "0=启用,1=不启用,2=删除")
    private String status;

    /**
     * 创建人
     */
    private String creator;

    /** 导出选中列表 */
    private List<Long> dataCondition;

    public List<Long> getDataCondition() {
        return dataCondition;
    }

    public void setDataCondition(List<Long> dataCondition) {
        this.dataCondition = dataCondition;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setpId(Long pId) {
        this.pId = pId;
    }

    public Long getpId() {
        return pId;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getCode() {
        return code;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getDescription() {
        return description;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public String getValue() {
        return value;
    }

    public void setSort(String sort) {
        this.sort = sort;
    }

    public String getSort() {
        return sort;
    }

    public void setLevel(String level) {
        this.level = level;
    }

    public String getLevel() {
        return level;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getStatus() {
        return status;
    }

    public void setCreator(String creator) {
        this.creator = creator;
    }

    public String getCreator() {
        return creator;
    }

    public Integer getSkipPermission() {
        return skipPermission;
    }

    public void setSkipPermission(Integer skipPermission) {
        this.skipPermission = skipPermission;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("pId", getpId())
                .append("code", getCode())
                .append("name", getName())
                .append("description", getDescription())
                .append("value", getValue())
                .append("sort", getSort())
                .append("level", getLevel())
                .append("status", getStatus())
                .append("createTime", getCreateTime())
                .append("creator", getCreator())
                .toString();
    }
}
