package com.yc.ship.module.miniapplet.controller.admin.problem.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 ProblemRespVO {

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

    @Schema(description = "问题类型ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1729")
//    @ExcelProperty("问题类型ID")
    private Long typeId;

    @Schema(description = "系统类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "1729")
    private Integer systemType;

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

    @Schema(description = "标题")
    @ExcelProperty("标题")
    private String title;

    @Schema(description = "文章内容")
    @ExcelProperty("文章内容")
    private String content;

    @Schema(description = "文章简介", example = "你猜")
    @ExcelProperty("文章简介")
    private String remark;

    @Schema(description = "关键字")
    @ExcelProperty("关键字")
    private String keyword;

    @Schema(description = "封面图")
    @ExcelProperty("封面图")
    private String cover;

    @Schema(description = "视频")
    @ExcelProperty("视频")
    private String video;

    @Schema(description = "发布状态 0未发布 1已发布", example = "1")
    @ExcelProperty(value = "发布状态 0未发布 1已发布", converter = DictConvert.class)
    @DictFormat("release_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Integer releaseStatus;

    @Schema(description = "发布时间")
    @ExcelProperty("发布时间")
    private LocalDateTime releaseTime;

    @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;

}
