DinerDTO.java
1.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
package com.infoloop.tianting.model.dto;
import com.infoloop.tianting.annotation.RequestKeyParam;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
@Data
@ApiModel(description = "就餐人DTO")
public class DinerDTO {
@Data
@ApiModel(description = "查询唯一就餐人")
public static class QueryUniqueDinerDTO {
@ApiModelProperty(value = "学号")
@NotEmpty(message = "学号不能为空")
private String studentNo;
}
@Data
@ApiModel(description = "添加就餐人")
public static class CreateDinerDTO {
@ApiModelProperty(value = "学校编码")
@NotEmpty(message = "学校编码不能为空")
@RequestKeyParam
private String clientCode;
@ApiModelProperty(value = "班级")
@NotNull(message = "班级不能为空")
@RequestKeyParam
private Integer classId;
@ApiModelProperty(value = "学号")
@NotEmpty(message = "学号不能为空")
@RequestKeyParam
private String studentNo;
@ApiModelProperty(value = "姓名")
@NotEmpty(message = "姓名不能为空")
private String name;
}
@Data
@ApiModel(description = "修改就餐人")
public static class UpdateDinerDTO {
@ApiModelProperty(value = "学校编码")
@NotEmpty(message = "学校编码不能为空")
private String clientCode;
@ApiModelProperty(value = "班级")
@NotNull(message = "班级不能为空")
private Integer classId;
@ApiModelProperty(value = "学号")
private String studentNo;
@ApiModelProperty(value = "姓名")
private String name;
}
}