package cn.newfeifan.mall.module.distri.controller.app.sharelink.vo;

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

import javax.validation.constraints.*;

@Schema(description = "管理后台 - 分享链接新增/修改 Request VO")
@Data
public class AppShareLinkSaveReqVO {

    @Schema(description = "分享链接id", requiredMode = Schema.RequiredMode.REQUIRED, example = "20538")
    private Long id;

    @Schema(description = "链接名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
    @NotEmpty(message = "链接名称不能为空")
    private String name;

    @Schema(description = "状态：是否启用。默认为1，表示启用；当值为0时，表示停用。", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @NotNull(message = "状态：是否启用。默认为1，表示启用；当值为0时，表示停用。不能为空")
    private Integer status;

    @Schema(description = "创建链接的用户id，关联消费者member_user表的主键", requiredMode = Schema.RequiredMode.REQUIRED, example = "30193")
    @NotNull(message = "创建链接的用户id，关联消费者member_user表的主键不能为空")
    private Long createUserId;

    @Schema(description = "分享链接类型编码：1.商城，2.店铺，3.商品", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "分享链接类型编码：1.商城，2.店铺，3.商品不能为空")
    private Integer category;

    @Schema(description = "链接对应业务对象id：如果“链接类型”是3=商品，这个id就是商品的spu表的id，即product_spu.id值。", requiredMode = Schema.RequiredMode.REQUIRED, example = "22758")
    @NotNull(message = "链接对应业务对象id：如果“链接类型”是3=商品，这个id就是商品的spu表的id，即product_spu.id值。不能为空")
    private Long objectId;

    @Schema(description = "通过本分享链接，累计注册的用户总数，默认值是0。每注册一个新用户，累加1.", requiredMode = Schema.RequiredMode.REQUIRED, example = "11628")
    @NotNull(message = "通过本分享链接，累计注册的用户总数，默认值是0。每注册一个新用户，累加1.不能为空")
    private Integer registerUserCount;

}