后端限制友链字段必填

This commit is contained in:
caozhen
2023-09-18 14:54:33 +08:00
parent 3ca96ce5e6
commit 711285e363
@@ -13,6 +13,8 @@ import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import javax.validation.constraints.NotBlank;
/**
* @Description: 友情链接管理
@@ -34,18 +36,22 @@ public class LawsFriendlyLinks implements Serializable {
private String id;
/**名称*/
@NotBlank(message = "name not null")
@ApiModelProperty(value = "名称")
private String name;
/**链接*/
@NotBlank(message = "link not null")
@ApiModelProperty(value = "链接")
private String link;
/**是否上架(0-是、1-否)*/
@NotBlank(message = "grounding not null")
@ApiModelProperty(value = "是否上架(0-是、1-否)")
private String grounding;
/**排序*/
@NotBlank(message = "sort not null")
@ApiModelProperty(value = "排序")
private Integer sort;