提交 0d2ed25b 作者: 张小凤

LicenceTraining(add)

上级 7f224da2
...@@ -11,6 +11,7 @@ import lombok.NoArgsConstructor; ...@@ -11,6 +11,7 @@ import lombok.NoArgsConstructor;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size; import javax.validation.constraints.Size;
import java.math.BigDecimal;
/** /**
* @Author small * @Author small
...@@ -54,7 +55,7 @@ public class LicenseTrainingProgramsDTO { ...@@ -54,7 +55,7 @@ public class LicenseTrainingProgramsDTO {
@ApiModelProperty(value = "培训价格", example = "1000", required = true) @ApiModelProperty(value = "培训价格", example = "1000", required = true)
@NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class}) @NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class})
@Size(min = 0, max = 100000, message = "价格不能超过100000") @Size(min = 0, max = 100000, message = "价格不能超过100000")
private Integer price; private BigDecimal price;
@ApiModelProperty(value = "培训地点不能为空", example = "广东省深圳市南山区XXX001", required = true) @ApiModelProperty(value = "培训地点不能为空", example = "广东省深圳市南山区XXX001", required = true)
@NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class}) @NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class})
......
...@@ -8,6 +8,7 @@ import org.hibernate.validator.constraints.Range; ...@@ -8,6 +8,7 @@ import org.hibernate.validator.constraints.Range;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Objects; import java.util.Objects;
/** /**
...@@ -38,7 +39,7 @@ public class LicenseTrainingProgramsVO { ...@@ -38,7 +39,7 @@ public class LicenseTrainingProgramsVO {
@ApiModelProperty(value = "培训价格", example = "1000", required = true) @ApiModelProperty(value = "培训价格", example = "1000", required = true)
@NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class}) @NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class})
@Range(min = 0, max = 100000, message = "价格不能超过100000") @Range(min = 0, max = 100000, message = "价格不能超过100000")
private Integer price; private BigDecimal price;
@ApiModelProperty(value = "培训地点不能为空", example = "广东省深圳市南山区XXX001", required = true) @ApiModelProperty(value = "培训地点不能为空", example = "广东省深圳市南山区XXX001", required = true)
@NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class}) @NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class})
......
...@@ -12,6 +12,7 @@ import lombok.NoArgsConstructor; ...@@ -12,6 +12,7 @@ import lombok.NoArgsConstructor;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size; import javax.validation.constraints.Size;
import java.math.BigDecimal;
/** /**
* @Author small * @Author small
...@@ -55,7 +56,7 @@ public class LicenseProgramsDO { ...@@ -55,7 +56,7 @@ public class LicenseProgramsDO {
@ApiModelProperty(value = "培训价格", example = "1000", required = true) @ApiModelProperty(value = "培训价格", example = "1000", required = true)
@NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class}) @NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class})
@Size(min = 0, max = 100000, message = "价格不能超过100000") @Size(min = 0, max = 100000, message = "价格不能超过100000")
private Integer price; private BigDecimal price;
@ApiModelProperty(value = "培训地点不能为空", example = "广东省深圳市南山区XXX001", required = true) @ApiModelProperty(value = "培训地点不能为空", example = "广东省深圳市南山区XXX001", required = true)
@NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class}) @NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class})
......
...@@ -10,6 +10,7 @@ import lombok.NoArgsConstructor; ...@@ -10,6 +10,7 @@ import lombok.NoArgsConstructor;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
/** /**
* @Author small * @Author small
...@@ -40,7 +41,7 @@ public class LicenseTrainingProgramsDO { ...@@ -40,7 +41,7 @@ public class LicenseTrainingProgramsDO {
@ApiModelProperty(value = "培训价格", example = "1000", required = true) @ApiModelProperty(value = "培训价格", example = "1000", required = true)
@NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class}) @NotNull(message = "培训价格不能为空", groups = {Create.class, Update.class})
private Integer price; private BigDecimal price;
@ApiModelProperty(value = "培训地点不能为空", example = "1", required = true) @ApiModelProperty(value = "培训地点不能为空", example = "1", required = true)
@NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class}) @NotBlank(message = "培训地点不能为空", groups = {Create.class, Update.class})
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论