package co.yixiang.yshop.module.product.controller.admin.campaigninfo.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import javax.validation.constraints.*;
import java.time.LocalDateTime;

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

    @Schema(description = "活动名称", required = true, example = "赵六")
    @NotNull(message = "活动名称不能为空")
    private String name;

    @Schema(description = "活动类型：1、拼团，2、秒杀，3、限时折扣", required = true, example = "2")
    @NotNull(message = "活动类型：1、拼团，2、秒杀，3、限时折扣不能为空")
    private Integer type;

    @Schema(description = "备注", example = "你猜")
    private String remark;

    @Schema(description = "活动开始时间", required = true)
    @NotNull(message = "活动开始时间不能为空")
    private LocalDateTime startTime;

    @Schema(description = "活动结束时间", required = true)
    @NotNull(message = "活动结束时间不能为空")
    private LocalDateTime endTime;

    @Schema(description = "商品限购 1-不限购 2-限购", required = true)
    @NotNull(message = "商品限购 1-不限购 2-限购不能为空")
    private Integer ifLimit;

    @Schema(description = "限购几件/人")
    private Integer limitNumber;

    @Schema(description = "活动预热   1-停用  2-启用", required = true)
    @NotNull(message = "活动预热   1-停用  2-启用不能为空")
    private Integer ifEnable;

    @Schema(description = "预热几分钟前")
    private Integer enableTime;


    @Schema(description = "活动状态 0-未开始 1-进行中 2-已结束")
    private Integer state;

    @Schema(description = "成团人数")
    private Integer person;

    @Schema(description = "成团有效时间几（分钟）")
    private Integer effectiveTime;

    @Schema(description = "是否虚拟成团:0-否，1-是", required = true)
    private Integer isVirtually;

}
