package com.sqx.modules.activity.dto;

import com.sqx.common.query.PageQuery;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Pattern;
import java.util.Date;

/**
 * 活动查询dto
 *
 * @author : codingliang
 * @date : 2024-06-19 10:24
 */
@Data
public class ActivityQueryDTO extends PageQuery {

    @ApiModelProperty(value = "活动标题")
    private String title;

    @ApiModelProperty(value = "是否启用;0否 1是")
    @Pattern(regexp = "(0|1)", message = "是否启用只能为0或1")
    private String enableFlag;

    @ApiModelProperty(value = "是否允许商户主动加入;0否 1是")
    @Pattern(regexp = "(0|1)", message = "是否允许商户主动加入只能为0或1")
    private String allowShop;

    @ApiModelProperty(value = "活动类型;1普通活动、2时段优惠、3满额优惠、4全场优惠")
    @Pattern(regexp = "[1-4]", message = "活动类型只能为1-4")
    private String type;

    @ApiModelProperty(value = "活动开始时间")
    private Date startTime;

    @ApiModelProperty(value = "活动结束时间")
    private Date endTime;
}
