package com.sy.coinage.workshop.req;

import com.sy.coinage.core.interceptor.Create;
import com.sy.coinage.core.interceptor.Update;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.NotBlank;

import org.hibernate.validator.constraints.Length;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import org.hibernate.validator.constraints.Range;
import lombok.Data;

/**
 * -实时库存表添加请求bean
 */
@Data
public class StockReq implements Serializable {

    private static final long serialVersionUID = 1L;
    /**
     * -id -10
     */
    @NotNull(message = "id不能为空", groups = {Update.class})
    @Range(min = 1, groups = {Update.class})
    private Integer id;
    /**
     * -仓库id -10
     */
    @ApiModelProperty(value = "仓库id", required = true)
    @NotNull(message = "仓库id不能为空")
    private Integer wareId;
    /**
     * -仓库 -20
     */
    @ApiModelProperty(value = "仓库", required = true)
    @NotBlank(message = "仓库不能为空")
    @Length(max = 20, message = "仓库长度20不正确")
    private String wareCn;
    /**
     * -库位ID -10
     */
    @ApiModelProperty(value = "库位ID", required = true)
    @NotNull(message = "库位ID不能为空")
    private Integer areaId;
    /**
     * -品名ID -10
     */
    @ApiModelProperty(value = "品名ID", required = true)
    @NotNull(message = "品名ID不能为空")
    private Integer securitiesId;
    /**
     * -品名名称 -20
     */
    @ApiModelProperty(value = "品名名称", required = true)
    @NotBlank(message = "品名名称不能为空")
    @Length(max = 20, message = "品名名称长度20不正确")
    private String securities;
    /**
     * -整拍数量 -10
     */
    @ApiModelProperty(value = "整拍数量", required = true)
    @NotNull(message = "整拍数量不能为空")
    private Integer racketNum;
    /**
     * -零箱数量 -10
     */
    @ApiModelProperty(value = "零箱数量", required = true)
    @NotNull(message = "零箱数量不能为空")
    private Integer boxNum;
    /**
     * -零枚数量 -10
     */
    @ApiModelProperty(value = "零枚数量", required = true)
    @NotNull(message = "零枚数量不能为空")
    private Integer piecesTotal;
    /**
     * -抽检零箱数量 -10
     */
    @ApiModelProperty(value = "抽检零箱数量", required = true)
    @NotNull(message = "抽检零箱数量不能为空")
    private Integer checkBoxNum;

}
