package cn.iocoder.yudao.module.bpm.controller.admin.oa.vo.imprest;

import cn.iocoder.yudao.module.bpm.controller.admin.oa.vo.BpmOABaseRespVO;
import cn.iocoder.yudao.module.bpm.controller.admin.upload.UploadUserFile;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;

import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY;

/**
 * @author 符溶馨
 */
@Schema(description = "管理后台 - 备用金申请  请求Request VO")
@Data
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
public class BpmOAImprestRespVO extends BpmOABaseRespVO {

    @Schema(description = "费用类型 参见 bpm_oa_imprest_type 枚举", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "费用类型不能为空")
    private String type;

    @Schema(description = "费用事由", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "费用事由不能为空")
    private String reason;

    @Schema(description = "费用金额", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "费用金额不能为空")
    private BigDecimal amount;

    @Schema(description = "使用日期", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "使用日期不能为空")
    @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
    private LocalDate date;

    @Schema(description = "报销流程编号", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
    private Integer reimbursementId;

    @Schema(description = "报销状态", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "报销状态不能为空")
    private Integer status;

    @Schema(description = "上传文件", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
    private List<UploadUserFile> fileItems;
}
