package com.zt.plat.module.erp.controller.admin.erp.vo;

import com.alibaba.excel.annotation.ExcelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.time.LocalDateTime;

@Schema(description = "管理后台 - ERP物料数据新增/修改 Request VO")
@Data
public class ErpMaterialSaveReqVO {

    @Schema(description = "主键", requiredMode = Schema.RequiredMode.REQUIRED, example = "2038")
    private Long id;

    @Schema(description = "中铜物料编码;系统使用时使用该编码", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "中铜物料编码;系统使用时使用该编码不能为空")
    private String downCenterNumber;

    @Schema(description = "中铝物料编码", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "中铝物料编码不能为空")
    private String centerNumber;

    @Schema(description = "创建日期", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotNull(message = "创建日期不能为空")
    private LocalDateTime createDate;

    @Schema(description = "物料类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
//    @NotEmpty(message = "物料类型不能为空")
    private String materialType;

    @Schema(description = "物料大类组", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "物料大类组不能为空")
    private String materialGroupDate;

    @Schema(description = "外部物料小类组", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "外部物料小类组不能为空")
    private String externalMaterialGroupDate;

    @Schema(description = "计量单位编码", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "计量单位编码不能为空")
    private String unit;

    @Schema(description = "计量单位描述", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "计量单位描述不能为空")
    private String unitDescription;

    @Schema(description = "物料类型描述", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "物料类型描述不能为空")
    private String materialTypeDescription;

    @Schema(description = "物料组描述", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "物料组描述不能为空")
    private String materialGroupDescription;

    @Schema(description = "外部物料小类组描述", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "外部物料小类组描述不能为空")
    private String externalMaterialGroupDescription;

    @Schema(description = "物料名称", example = "李四")
    private String materialName;

    @Schema(description = "物料长描述", requiredMode = Schema.RequiredMode.REQUIRED)
//    @NotEmpty(message = "物料长描述不能为空")
    private String materialLengthDescription;

    @Schema(description = "类型")
    private String type;

    @Schema(description = "金属元素缩写")
    private String abbreviation;

    @Schema(description = "金属元素名称", example = "赵六")
    private String name;

    @Schema(description = "金属元素编码")
    private String coding;

    @Schema(description = "品位单位")
    private String gradeUnit;

    @Schema(description = "小数位数")
    @Min(value = 1, message = "数值必须大于0")
    private Long decimalValue;

}