package org.xyzh.common.dto.sys;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.xyzh.common.dto.BaseDTO;
import com.alibaba.fastjson2.JSONObject;

/**
 * @description    系统配置DTO
 * @filename    TbSysConfigDTO.java
 * @author    yslg
 * @copyright yslg
 * @since 2025-11-04
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Schema(description = "系统配置DTO")
public class TbSysConfigDTO extends BaseDTO {
    // optsn、creator、updater、deptPath、remark、createTime、updateTime、deleteTime、deleted 继承自BaseDTO

    @Schema(description = "配置ID")
    private String configId;

    @Schema(description = "配置键")
    private String key;

    @Schema(description = "配置名称")
    private String name;

    @Schema(description = "配置值")
    private String value;

    @Schema(description = "数据类型(String, Integer, Boolean, Float, Double)")
    private String configType;

    @Schema(description = "配置渲染类型(select, input, textarea, checkbox, radio, switch)")
    private String renderType;

    @Schema(description = "配置描述")
    private String description;

    @Schema(description = "正则表达式校验规则(JSON)")
    private JSONObject re;

    @Schema(description = "可选项(JSON)，render_type为select、checkbox、radio时使用")
    private JSONObject options;

    @Schema(description = "配置组")
    private String group;

    @Schema(description = "模块id")
    private String moduleId;

    @Schema(description = "配置顺序")
    private Integer orderNum;

    @Schema(description = "配置状态 0:启用 1:禁用", defaultValue = "0")
    private Integer status = 0;

}