package com.hys.app.model.erp.dto;

import com.hys.app.model.erp.dos.ProcurementContract;
import com.hys.app.model.erp.dos.ProcurementContractProduct;
import com.hys.app.model.erp.dos.ProcurementPlan;
import com.hys.app.model.erp.dos.SupplierDO;
import com.hys.app.model.erp.dos.WarehouseDO;
import com.hys.app.model.erp.enums.OrderTypeEnum;
import com.hys.app.model.erp.enums.ScanFormCodeTypeEnum;
import com.hys.app.model.erp.enums.WarehouseEntyrTypeEnum;
import com.hys.app.model.erp.vo.AdminUserVO1;
import com.hys.app.model.system.dos.AdminUser;
import com.hys.app.model.system.dos.DeptDO;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.List;
import java.util.Map;

/**
 * 入库单新增/编辑DTO
 *
 * @author 张崧
 * @since 2023-12-05 11:25:07
 */
@Data
public class WarehouseEntryDTO {

    @ApiModelProperty(hidden = true)
    private Long id;

    @ApiModelProperty(name = "type", value = "入库类型")
    private WarehouseEntyrTypeEnum type;


    @ApiModelProperty(name = "memo", value = "订单备注")
    private String memo;

    @ApiModelProperty(name = "order_id", value = "扫码或者选择的单子ID")
    private Long orderId;

    @ApiModelProperty(name = "scan_order_type", value = "单子的类型，扫码订单打出来的数据必传")
    private OrderTypeEnum scanOrderType;

    @ApiModelProperty(value = "扫描订单的sn")
    private String scanOrderSn;

    @ApiModelProperty(name = "warehouse_id", value = "仓库id")
    @NotNull(message = "仓库不能为空")
    private Long warehouseId;

    @ApiModelProperty(name = "product_list", value = "商品明细列表")
    @NotEmpty(message = "商品明细列表不能为空")
    @Valid
    private List<WarehouseEntryProductDTO> productList;


    @ApiModelProperty(value = "操作類型")
    @NotBlank(message = "操作类型不能为空,save保存submit入库")
    private String saveOrSubmit;

}

