mirror of
https://gitee.com/huangge1199_admin/vue-pro.git
synced 2024-11-22 23:31:52 +08:00
秒杀相关VO添加example
This commit is contained in:
parent
6808d3c163
commit
9384ba0d52
@ -14,9 +14,9 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_
|
||||
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.TIME_ZONE_DEFAULT;
|
||||
|
||||
/**
|
||||
* 秒杀活动 Base VO,提供给添加、修改、详细的子 VO 使用
|
||||
* 如果子 VO 存在差异的字段,请不要添加到这里,影响 Swagger 文档生成
|
||||
*/
|
||||
* 秒杀活动 Base VO,提供给添加、修改、详细的子 VO 使用
|
||||
* 如果子 VO 存在差异的字段,请不要添加到这里,影响 Swagger 文档生成
|
||||
*/
|
||||
@Data
|
||||
public class SeckillActivityBaseVO {
|
||||
|
||||
|
@ -11,7 +11,6 @@ import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.List;
|
||||
|
||||
// TODO halfninety:检查下所有的 VO,需要保证 example 都写了哈。
|
||||
@ApiModel("管理后台 - 秒杀活动创建 Request VO")
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ -21,11 +20,11 @@ public class SeckillActivityCreateReqVO extends SeckillActivityBaseVO {
|
||||
@ApiModelProperty(value = "备注", example = "限时秒杀活动")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "排序", required = true)
|
||||
@ApiModelProperty(value = "排序", required = true, example = "1")
|
||||
@NotNull(message = "排序不能为空")
|
||||
private Integer sort;
|
||||
|
||||
@ApiModelProperty(value = "秒杀时段id", required = true)
|
||||
@ApiModelProperty(value = "秒杀时段id", required = true, example = "1,3")
|
||||
@NotEmpty(message = "参与场次不能为空")
|
||||
private List<Long> timeIds;
|
||||
|
||||
|
@ -11,7 +11,7 @@ import java.util.List;
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class SeckillActivityDetailRespVO extends SeckillActivityRespVO{
|
||||
public class SeckillActivityDetailRespVO extends SeckillActivityRespVO {
|
||||
|
||||
/**
|
||||
* 商品列表
|
||||
|
@ -26,7 +26,7 @@ public class SeckillActivityPageReqVO extends PageParam {
|
||||
@ApiModelProperty(value = "活动状态", example = "进行中")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty(value = "秒杀时段id")
|
||||
@ApiModelProperty(value = "秒杀时段id", example = "1")
|
||||
private Long timeId;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
|
@ -15,22 +15,22 @@ import java.util.List;
|
||||
@ToString(callSuper = true)
|
||||
public class SeckillActivityRespVO extends SeckillActivityBaseVO {
|
||||
|
||||
@ApiModelProperty(value = "秒杀活动id", required = true, example = "1")
|
||||
@ApiModelProperty(value = "秒杀活动id", required = true, example = "1")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "付款订单数", required = true)
|
||||
@ApiModelProperty(value = "付款订单数", required = true, example = "1")
|
||||
private Integer orderCount;
|
||||
|
||||
@ApiModelProperty(value = "付款人数", required = true)
|
||||
@ApiModelProperty(value = "付款人数", required = true, example = "1")
|
||||
private Integer userCount;
|
||||
|
||||
@ApiModelProperty(value = "创建时间", required = true)
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@ApiModelProperty(value = "秒杀时段id", required = true)
|
||||
@ApiModelProperty(value = "秒杀时段id", required = true, example = "1,3")
|
||||
private List<Long> timeIds;
|
||||
|
||||
@ApiModelProperty(value = "排序", required = true)
|
||||
@ApiModelProperty(value = "排序", required = true, example = "1")
|
||||
private Integer sort;
|
||||
|
||||
@ApiModelProperty(value = "备注", example = "限时秒杀活动")
|
||||
|
@ -24,11 +24,11 @@ public class SeckillActivityUpdateReqVO extends SeckillActivityBaseVO {
|
||||
@ApiModelProperty(value = "备注", example = "限时秒杀活动")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(value = "排序", required = true)
|
||||
@ApiModelProperty(value = "排序", required = true, example = "1")
|
||||
@NotNull(message = "排序不能为空")
|
||||
private Integer sort;
|
||||
|
||||
@ApiModelProperty(value = "秒杀时段id", required = true)
|
||||
@ApiModelProperty(value = "秒杀时段id", required = true, example = "1,3")
|
||||
@NotEmpty(message = "秒杀时段id不能为空")
|
||||
private List<Long> timeIds;
|
||||
|
||||
|
@ -1,28 +1,27 @@
|
||||
package cn.iocoder.yudao.module.promotion.controller.admin.seckill.vo.time;
|
||||
|
||||
import lombok.*;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.time.LocalTime;
|
||||
|
||||
import io.swagger.annotations.*;
|
||||
import javax.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 秒杀时段 Base VO,提供给添加、修改、详细的子 VO 使用
|
||||
* 如果子 VO 存在差异的字段,请不要添加到这里,影响 Swagger 文档生成
|
||||
*/
|
||||
* 秒杀时段 Base VO,提供给添加、修改、详细的子 VO 使用
|
||||
* 如果子 VO 存在差异的字段,请不要添加到这里,影响 Swagger 文档生成
|
||||
*/
|
||||
@Data
|
||||
public class SeckillTimeBaseVO {
|
||||
|
||||
@ApiModelProperty(value = "秒杀时段名称", required = true)
|
||||
@ApiModelProperty(value = "秒杀时段名称", required = true, example = "上午场")
|
||||
@NotNull(message = "秒杀时段名称不能为空")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "开始时间点", required = true)
|
||||
@ApiModelProperty(value = "开始时间点", required = true, example = "16:30:40")
|
||||
@NotNull(message = "开始时间点不能为空")
|
||||
private LocalTime startTime;
|
||||
|
||||
@ApiModelProperty(value = "结束时间点", required = true)
|
||||
@ApiModelProperty(value = "结束时间点", required = true, example = "16:30:40")
|
||||
@NotNull(message = "结束时间点不能为空")
|
||||
private LocalTime endTime;
|
||||
|
||||
|
@ -16,14 +16,14 @@ import java.time.LocalTime;
|
||||
@ToString(callSuper = true)
|
||||
public class SeckillTimePageReqVO extends PageParam {
|
||||
|
||||
@ApiModelProperty(value = "秒杀时段名称")
|
||||
@ApiModelProperty(value = "秒杀时段名称", example = "上午场")
|
||||
private String name;
|
||||
|
||||
@ApiModelProperty(value = "开始时间点")
|
||||
@ApiModelProperty(value = "开始时间点", example = "16:30:40")
|
||||
@DateTimeFormat(pattern = "HH:mm:ss")
|
||||
private LocalTime startTime;
|
||||
|
||||
@ApiModelProperty(value = "结束时间点")
|
||||
@ApiModelProperty(value = "结束时间点", example = "16:30:40")
|
||||
@DateTimeFormat(pattern = "HH:mm:ss")
|
||||
private LocalTime endTime;
|
||||
|
||||
|
@ -1,8 +1,12 @@
|
||||
package cn.iocoder.yudao.module.promotion.controller.admin.seckill.vo.time;
|
||||
|
||||
import lombok.*;
|
||||
import java.util.*;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.ToString;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
@ApiModel("管理后台 - 秒杀时段 Response VO")
|
||||
@Data
|
||||
@ -10,13 +14,13 @@ import io.swagger.annotations.*;
|
||||
@ToString(callSuper = true)
|
||||
public class SeckillTimeRespVO extends SeckillTimeBaseVO {
|
||||
|
||||
@ApiModelProperty(value = "编号", required = true)
|
||||
@ApiModelProperty(value = "编号", required = true, example = "1")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty(value = "秒杀活动数量", required = true)
|
||||
@ApiModelProperty(value = "秒杀活动数量", required = true, example = "1")
|
||||
private Integer seckillActivityCount;
|
||||
|
||||
@ApiModelProperty(value = "创建时间", required = true)
|
||||
private Date createTime;
|
||||
private LocalDateTime createTime;
|
||||
|
||||
}
|
||||
|
@ -1,4 +0,0 @@
|
||||
package cn.iocoder.yudao.module.promotion.controller.admin.seckill.vo.time;
|
||||
|
||||
public class SeckillTimeSimpleRespVO {
|
||||
}
|
@ -14,7 +14,7 @@ import javax.validation.constraints.NotNull;
|
||||
@ToString(callSuper = true)
|
||||
public class SeckillTimeUpdateReqVO extends SeckillTimeBaseVO {
|
||||
|
||||
@ApiModelProperty(value = "编号", required = true)
|
||||
@ApiModelProperty(value = "编号", required = true, example = "1")
|
||||
@NotNull(message = "编号不能为空")
|
||||
private Long id;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user