package com.starry.admin.modules.weichat.entity.order;

import com.starry.admin.modules.shop.module.constant.GiftConstant;
import java.util.List;
import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

/**
 * 新增赠礼订单实体
 *
 * @author admin
 */
@Data
public class PlayOrderInfoCommodityAdd {

    /**
     * 店员用户ID
     */
    @NotBlank(message = "打赏对象不能为空")
    private String clerkId;

    @NotBlank(message = "商品ID不能为空")
    private String commodityId;

    @NotNull(message = "数量不能为空")
    @Min(value = GiftConstant.MINIMUM_SINGLE_GIFT_QUANTITY, message = "数量不能小于"
            + GiftConstant.MINIMUM_SINGLE_GIFT_QUANTITY)
    @Max(value = GiftConstant.MAXIMUM_SINGLE_GIFT_QUANTITY, message = "数量不能大于"
            + GiftConstant.MAXIMUM_SINGLE_GIFT_QUANTITY)
    private int commodityQuantity;

    @NotBlank(message = "微信号不能为空")
    @Length(max = 255, message = "微信号码长度不超过255个字符")
    private String weiChatCode;

    /**
     * 优惠券ID列表
     */
    private List<String> couponIds;

    /**
     * 备注
     */
    private String remark;
}
