package com.casic.missiles.dto.system;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.ContentRowHeight;
import com.alibaba.excel.annotation.write.style.ContentStyle;
import com.alibaba.excel.annotation.write.style.HeadRowHeight;
import com.alibaba.excel.enums.poi.BorderStyleEnum;
import com.baomidou.mybatisplus.annotation.TableField;
import com.casic.missiles.annotation.DictCodeField;
import com.casic.missiles.constants.MeterDictCode;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @author cz
 * @date 2023-04-03
 */
@Data
@ApiModel("文件列表")
@ColumnWidth(30)
@HeadRowHeight(15)
@ContentRowHeight(20)
@ContentStyle(borderLeft = BorderStyleEnum.THIN, borderBottom = BorderStyleEnum.THIN, borderTop = BorderStyleEnum.THIN, borderRight = BorderStyleEnum.THIN)
@ExcelIgnoreUnannotated
public class DownloadListResponse {

    private Long id;

    @ApiModelProperty("下载编号")
    @ExcelProperty(value = "文件编号", order = 0)
    private String downloadNo;

    @ApiModelProperty("业务模块名称")
    @ExcelProperty(value = "业务模块名称", order = 1)
    private String moduleName;

    @ApiModelProperty("业务类型")
    @DictCodeField(message = "业务类型描述不合法", cacheName = MeterDictCode.BUSINESS_DOWNLOAD_TYPE)
    private String businessDownloadType;

    @TableField(exist = false)
    @ExcelProperty(value = "业务类型", order =2 )
    private String businessDownloadTypeName;

    @ApiModelProperty("minio存储文件名")
    @ExcelProperty(value = "minio存储文件名", order = 3)
    private String minioFileName;

    @ApiModelProperty("文件名称")
    @ExcelProperty(value = "文件名称", order = 4)
    private String fileName;

    @ApiModelProperty("文件类型")
    @DictCodeField(message = "文件类型描述不合法", cacheName = MeterDictCode.CONFIG_FILE_TYPE)
    private String fileType;

    @ExcelProperty(value = "文件类型", order = 5)
    private String fileTypeName;

    @ApiModelProperty("App版本类型")
    private String versionName;

    @ApiModelProperty("描述备注")
    @ExcelProperty(value = "描述备注", order = 6)
    private String descn;

    @ApiModelProperty("创建人id")
    private Long createUser;

    @ApiModelProperty("更新人id")
    private Long updateUser;

    @ApiModelProperty("创建时间")
    @ExcelProperty(value = "创建时间", order = 7)
    private String createTime;

    @ApiModelProperty("更新时间")
    @ExcelProperty(value = "更新时间", order = 8)
    private String updateTime;

}
