package cn.iocoder.yudao.module.smartfactory.controller.admin.packagedata.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

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

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

@Schema(description = "管理后台 - 打包线数据新增 Request VO")
@Data
public class PackageDataCreateReqVO {

    @Schema(description = "工厂编号", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "工厂编号不能为空")
    private Long factoryId;

    @Schema(description = "打包线信息", requiredMode = Schema.RequiredMode.REQUIRED)
    private List<PackageDataSaveReqVO> packageData;

    @Schema(description = "打包日期", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "打包日期不能为空")
    @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
    private LocalDate packageDate;
}
