package com.neusoft.smart.pos.dto.inventory.request;


import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

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

@Data
@ApiModel
public class SellAndWarehouseOutRequest {
    
    @NotNull
    private String orderNum;
    
//    @NotNull
//    private Date orderExpireTime;
    
    @NotNull
    private Integer orgId;
    
    @NotNull
    private Integer shopId;
    
    @NotNull
    private List<OrderItem> orderItems;
    
    
    @Data
    public static class OrderItem {
        
        @ApiModelProperty(name = "goodsId", value = "商品ID", dataType = "Integer", required = true, example = "123")
        private Integer goodsId;
        
        @ApiModelProperty(name = "orgId", value = "集团ID", dataType = "Integer", required = true, example = "123")
        private Integer orgId;
        
        @ApiModelProperty(name = "shopId", value = "门店ID", dataType = "Integer", required = true, example = "123")
        private Integer shopId;
        
        @ApiModelProperty(name = "storageNum", value = "售卖数量(计算后,非原始)", dataType = "BigDecimal", required = true, example = "10.0")
        private BigDecimal storageNum;
        
        @ApiModelProperty(name = "scale", value = "精度", dataType = "Integer", required = true, example = "2")
        private Integer scale = 0;
    }
}
