package cn.com.tenlion.configtable.pojo.dtos.configtableoperation;

import ink.wgink.module.dictionary.pojo.dtos.DataDTO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.models.auth.In;

import java.util.ArrayList;
import java.util.List;

/**
 *
 * @ClassName: ConfigTableOperationDTO
 * @Description: 崔宝铖
 * @Author: CodeFactory
 * @Date: 2021-06-24 10:59:30
 * @Version: 3.0
 **/
@ApiModel
public class ConfigTableOperationDTO {

    @ApiModelProperty(name = "name", value = "字段名")
    private String name;
    @ApiModelProperty(name = "comment", value = "注释")
    private String comment;
    @ApiModelProperty(name = "dataType", value = "数据类型")
    private String dataType = "1";
    @ApiModelProperty(name = "maxLength", value = "表单描述")
    private Integer maxLength = 0;
    @ApiModelProperty(name = "columnType", value = "字段类型")
    private String columnType;
    @ApiModelProperty(name = "value", value = "数据库值")
    private Object value;
    @ApiModelProperty(name = "order", value = "排序")
    private Integer order = 0;
    @ApiModelProperty(name = "must", value = "是否为必填项")
    private boolean must = false;
    @ApiModelProperty(name = "displayList", value = "是否在列表显示")
    private boolean displayList = false;
    @ApiModelProperty(name = "dataMode", value = "展示方式(此为固定约定值)")
    private String dataMode;
    @ApiModelProperty(name = "dictionariesList", value = "数据字典集合,当dataType为8(单选),9(多选)的时候使用")
    private List<DataDTO> dictionariesList;
    @ApiModelProperty(name = "dictionaries", value = "数据字典ID")
    private String dictionaries;
    @ApiModelProperty(name = "maxCount", value = "数量限制")
    private Integer maxCount = maxLength;
    @ApiModelProperty(name = "defaultValue", value = "默认值")
    private String defaultValue;
    @ApiModelProperty(name = "placeholder", value = "提示语")
    private String placeholder;
    @ApiModelProperty(name = "rowCol", value = "行占比")
    private Integer rowCol;
    @ApiModelProperty(name = "row", value = "合并行")
    private boolean row;
    @ApiModelProperty(name = "configJson", value = "附加配置")
    private String configJson;

    public boolean getRow() {
        return row;
    }

    public void setRow(boolean row) {
        this.row = row;
    }

    public String getConfigJson() {
        return configJson == null ? "" : configJson;
    }

    public void setConfigJson(String configJson) {
        this.configJson = configJson;
    }

    public String getDefaultValue() {
        return defaultValue == null ? "" : defaultValue;
    }

    public void setDefaultValue(String defaultValue) {
        this.defaultValue = defaultValue;
    }

    public String getPlaceholder() {
        return placeholder == null ? "" : placeholder;
    }

    public void setPlaceholder(String placeholder) {
        this.placeholder = placeholder;
    }

    public Integer getRowCol() {
        return rowCol;
    }

    public void setRowCol(Integer rowCol) {
        this.rowCol = rowCol;
    }

    public boolean getDisplayList() {
        return displayList;
    }

    public void setDisplayList(boolean displayList) {
        this.displayList = displayList;
    }

    public String getDataMode() {
        return dataMode == null ? "" : dataMode;
    }

    public void setDataMode(String dataMode) {
        this.dataMode = dataMode;
    }

    public List<DataDTO> getDictionariesList() {
        if (dictionariesList == null) {
            return new ArrayList<>();
        }
        return dictionariesList;
    }

    public void setDictionariesList(List<DataDTO> dictionariesList) {
        this.dictionariesList = dictionariesList;
    }

    public String getDictionaries() {
        return dictionaries == null ? "" : dictionaries;
    }

    public void setDictionaries(String dictionaries) {
        this.dictionaries = dictionaries;
    }

    public Integer getMaxCount() {
        return maxCount;
    }

    public void setMaxCount(Integer maxCount) {
        this.maxCount = maxCount;
    }

    public boolean getMust() {
        return must;
    }

    public void setMust(boolean must) {
        this.must = must;
    }

    public Integer getOrder() {
        return order;
    }

    public void setOrder(Integer order) {
        this.order = order;
    }

    public Object getValue() {
        return value == null ? "" : value;
    }

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

    public String getName() {
        return name == null ? "" : name;
    }

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

    public String getComment() {
        return comment == null ? "" : comment;
    }

    public void setComment(String comment) {
        this.comment = comment;
    }

    public String getDataType() {
        return dataType == null ? "" : dataType;
    }

    public void setDataType(String dataType) {
        this.dataType = dataType;
    }

    public Integer getMaxLength() {
        return maxLength;
    }

    public void setMaxLength(Integer maxLength) {
        this.maxLength = maxLength;
    }

    public String getColumnType() {
        return columnType == null ? "" : columnType;
    }

    public void setColumnType(String columnType) {
        this.columnType = columnType;
    }

}
