package com.cf.imes.module.executor.controller.admin.order.vo.order;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import java.math.BigDecimal;
import java.util.*;
import javax.validation.constraints.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;

@Schema(description = "管理后台 - 生产单表 order_{N}新增/修改 Request VO")
@Data
public class OrderSaveReqVO {

    private Long id;

    @Schema(description = "父单号")
    private Long parentNo;

    @Schema(description = "生产单日期", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "交付日期不能为空")
    private LocalDateTime orderDate;

    @Schema(description = "交付日期", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "交付日期不能为空")
    private LocalDateTime deliveryDate;

    @Schema(description = "生产单类型，1主单 2子单", example = "1")
    private Boolean orderType;

    @Schema(description = "生产单排序号")
    private Integer orderSort;

    @Schema(description = "CAD数据类型，1CAD 2WebCAD 3Excel", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "CAD数据类型，1CAD 2WebCAD 3Excel不能为空")
    private Integer dataType;

    @Schema(description = "订单状态，订单状态，0空订单1新单2生产中3生产完成", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @NotNull(message = "订单状态，订单状态，0空订单1新单2生产中3生产完成")
    private Integer status;

    @Schema(description = "自定义单号")
    private String customOrderNo;

    @Schema(description = "客户", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "客户不能为空")
    private String customer;

    @Schema(description = "客户地址", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "客户地址不能为空")
    private String address;

    @Schema(description = "客户电话", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "客户电话不能为空")
    private String phoneNumber;

    @Schema(description = "经销商", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "经销商不能为空")
    private String dealer;

    @Schema(description = "经销商电话", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "经销商电话不能为空")
    private String dealerPhoneNumber;

    @Schema(description = "业务员")
    private String salesman;

    @Schema(description = "拆单员")
    private String splitter;

    @Schema(description = "备注", example = "你猜")
    private String remark;

    private Boolean deleted;

}