package cn.iocoder.yudao.module.basic.controller.admin.goodsinfo.vo;

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

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
* 商品 Base VO，提供给添加、修改、详细的子 VO 使用
* 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
*/
@Data
public class GoodsInfoBaseVO {

    @ApiModelProperty(value = "商品名称", required = true)
    @NotNull(message = "商品名称不能为空")
    private String goodsName;

    @ApiModelProperty(value = "商品编码")
    private String goodsId;

    @ApiModelProperty(value = "商品类型", required = true)
    @NotNull(message = "商品类型不能为空")
    private String goodsType;

    @ApiModelProperty(value = "商品类型id", required = true)
    private Long goodsTypeId;

    @ApiModelProperty(value = "是否基础单位(kg)")
    private Boolean isBaseUnit;

    @ApiModelProperty(value = "商品单位id, 是基础单位(kg)时 该字段为0")
    private Long goodsUnitId;

    @ApiModelProperty(value = "商品规格, 换算之后写入的数值 如：5kg/袋 (或者kg)")
    private String goodsSpecs;

    @ApiModelProperty(value = "换算值")
    private BigDecimal conversionValue;

    @ApiModelProperty(value = "商品说明")
    private String goodsRemarks;

    @ApiModelProperty(value = "商品图片url，以;分割，最多6张")
    private String goodsImgUrl;

    @ApiModelProperty(value = "保质期天")
    private Integer shelfLife;

    @ApiModelProperty(value = "所属商户id", required = true)
    @NotNull(message = "所属商户id不能为空")
    private Long belongBusinessId;

    @ApiModelProperty(value = "所属商户名称", required = true)
    @NotNull(message = "所属商户名称不能为空")
    private String belongBusinessName;

}
