package com.yc.ship.module.miniapplet.controller.admin.problemtype.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.yc.ship.framework.excel.core.annotations.DictFormat;
import com.yc.ship.framework.excel.core.convert.DictConvert;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

@Schema(description = "管理后台 - 问题类型 Response VO")
@Data
@ExcelIgnoreUnannotated
public class ProblemTypeRespVO {

    @Schema(description = "问题类型主键ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "7385")
//    @ExcelProperty("问题类型主键ID")
    private Long id;

    @Schema(description = "问题名称", example = "张三")
    @ExcelProperty("问题名称")
    private String name;

    @Schema(description = "问题编码")
    @ExcelProperty("问题编码")
    private String code;

    @Schema(description = "父级问题类型", example = "22809")
//    @ExcelProperty("父级问题类型")
    private Long parentId;

    @Schema(description = "父级问题类型", example = "22809")
    @ExcelProperty("父级问题类型")
    private String parentName;

    @Schema(description = "问题Icon图标")
    @ExcelProperty("问题Icon图标")
    private String logo;

    @Schema(description = "备注", example = "随便")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "启用状态 0否 1是")
    @ExcelProperty(value = "启用状态 0否 1是", converter = DictConvert.class)
    @DictFormat("use_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Integer isUse;

    @Schema(description = "排序号")
    @ExcelProperty("排序号")
    private Integer sortNum;

    @Schema(description = "创建时间")
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

}
