package cn.iocoder.yudao.module.project.vo;

import cn.iocoder.yudao.common.RepairDictConstants;
import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 用于导出维修项目的VO
 *
 * @author 小李
 * @date 17:03 2024/12/2
**/
@Data
@ExcelIgnoreUnannotated
public class ProjectExportVO {

    @ExcelProperty("名称")
    private String name;

    @ExcelProperty("成本")
    private Long cost;

    @ExcelProperty("规格")
    private String spec;

    @ExcelProperty("售价")
    private BigDecimal price;

    @ExcelProperty("编码")
    private String code;

    @ExcelProperty(value = "单位", converter = DictConvert.class)
    @DictFormat(RepairDictConstants.REPAIR_UNIT)
    private String unit;

    @ExcelProperty("分类")
    private String type;

    @ExcelProperty("工时")
    private String manHour;

    @ExcelProperty("备注")
    private String remark;

    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;
}
