feat: add message enable

This commit is contained in:
guoyuqi 2023-08-17 17:11:43 +08:00 committed by 刘瑞斌
parent 4f27990b2c
commit c7e1cf7505

View File

@ -10,48 +10,48 @@ import lombok.Data;
@Data
public class MessageTask implements Serializable {
@Schema(title = "", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.id.not_blank}", groups = {Updated.class})
@Size(min = 1, max = 50, message = "{message_task.id.length_range}", groups = {Created.class, Updated.class})
private String id;
@Schema(title = "消息类型", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "消息类型", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.type.not_blank}", groups = {Created.class})
@Size(min = 1, max = 50, message = "{message_task.type.length_range}", groups = {Created.class, Updated.class})
private String type;
@Schema(title = "通知事件类型", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "通知事件类型", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.event.not_blank}", groups = {Created.class})
@Size(min = 1, max = 255, message = "{message_task.event.length_range}", groups = {Created.class, Updated.class})
private String event;
@Schema(title = "接收人id", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "接收人id", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.receiver.not_blank}", groups = {Created.class})
@Size(min = 1, max = 50, message = "{message_task.receiver.length_range}", groups = {Created.class, Updated.class})
private String receiver;
@Schema(title = "任务类型", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "任务类型", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.task_type.not_blank}", groups = {Created.class})
@Size(min = 1, max = 64, message = "{message_task.task_type.length_range}", groups = {Created.class, Updated.class})
private String taskType;
@Schema(title = "webhook地址")
@Schema(description = "webhook地址")
private String webhook;
@Schema(title = "具体测试的ID", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "具体测试的ID", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.test_id.not_blank}", groups = {Created.class})
@Size(min = 1, max = 50, message = "{message_task.test_id.length_range}", groups = {Created.class, Updated.class})
private String testId;
@Schema(title = "创建时间")
@Schema(description = "创建时间")
private Long createTime;
@Schema(title = "项目ID", requiredMode = Schema.RequiredMode.REQUIRED)
@Schema(description = "项目ID", requiredMode = Schema.RequiredMode.REQUIRED)
@NotBlank(message = "{message_task.project_id.not_blank}", groups = {Created.class})
@Size(min = 1, max = 50, message = "{message_task.project_id.length_range}", groups = {Created.class, Updated.class})
private String projectId;
@Schema(title = "是否启用")
@Schema(description = "是否启用")
@NotNull(message = "{message_task.enable.not_blank}", groups = {Created.class, Updated.class})
private Boolean enable;