commit | author | age
|
88f419
|
1 |
/* |
I |
2 |
Copyright [2020] [https://www.xiaonuo.vip] |
|
3 |
|
|
4 |
Licensed under the Apache License, Version 2.0 (the "License"); |
|
5 |
you may not use this file except in compliance with the License. |
|
6 |
You may obtain a copy of the License at |
|
7 |
|
|
8 |
http://www.apache.org/licenses/LICENSE-2.0 |
|
9 |
|
|
10 |
Unless required by applicable law or agreed to in writing, software |
|
11 |
distributed under the License is distributed on an "AS IS" BASIS, |
|
12 |
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
13 |
See the License for the specific language governing permissions and |
|
14 |
limitations under the License. |
|
15 |
|
|
16 |
Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点: |
|
17 |
|
|
18 |
1.请不要删除和修改根目录下的LICENSE文件。 |
|
19 |
2.请不要删除和修改Snowy源码头部的版权声明。 |
|
20 |
3.请保留源码和相关描述文件的项目出处,作者声明等。 |
|
21 |
4.分发源码时候,请注明软件出处 https://gitee.com/xiaonuobase/snowy |
|
22 |
5.在修改包名,模块名称,项目代码等时,请注明软件出处 https://gitee.com/xiaonuobase/snowy |
|
23 |
6.若您的项目无法满足以上几点,可申请商业授权,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip |
|
24 |
*/ |
|
25 |
package vip.xiaonuo.modular.blogarticlecomment.param; |
|
26 |
|
|
27 |
import lombok.Data; |
|
28 |
import vip.xiaonuo.core.pojo.base.param.BaseParam; |
|
29 |
|
|
30 |
import javax.validation.constraints.*; |
|
31 |
|
|
32 |
/** |
|
33 |
* 文章评论参数类 |
|
34 |
* |
|
35 |
* @author inleft |
|
36 |
* @date 2022-03-01 14:00:53 |
|
37 |
*/ |
|
38 |
@Data |
|
39 |
public class BlogArticleCommentAddDto extends BaseParam { |
|
40 |
|
|
41 |
/** |
|
42 |
* 自增id |
|
43 |
*/ |
|
44 |
@NotNull(message = "自增id不能为空,请检查id参数", groups = {edit.class, delete.class, detail.class}) |
|
45 |
private Long id; |
|
46 |
|
|
47 |
/** |
|
48 |
* 留言类型 1:留言板 2:日志评论 |
|
49 |
*/ |
|
50 |
@NotNull(message = "留言类型 1:留言板 2:日志评论不能为空,请检查commentType参数", groups = {add.class}) |
|
51 |
private Integer commentType; |
|
52 |
|
|
53 |
/** |
|
54 |
* 回复id |
|
55 |
*/ |
|
56 |
private Long replyId; |
|
57 |
|
|
58 |
/** |
|
59 |
* 父id (不为0则是子回复) |
|
60 |
*/ |
|
61 |
private Long parentId; |
|
62 |
|
|
63 |
/** |
|
64 |
* 文章id主键 |
|
65 |
*/ |
|
66 |
private Long articleId; |
|
67 |
|
|
68 |
/** |
|
69 |
* 访客id(随机字符) |
|
70 |
*/ |
|
71 |
@NotBlank(message = "访客id(随机字符)不能为空,请检查visitorId参数", groups = {add.class}) |
|
72 |
private String visitorId; |
|
73 |
|
|
74 |
/** |
|
75 |
* 访客名称 |
|
76 |
*/ |
|
77 |
@NotBlank(message = "访客名称不能为空,请检查visitorNickName参数", groups = {add.class, edit.class}) |
|
78 |
private String visitorNickName; |
|
79 |
|
|
80 |
/** |
|
81 |
* 访客邮箱 |
|
82 |
*/ |
|
83 |
@Pattern(regexp = "^$|^[a-zA-Z0-9_.-]+@[a-zA-Z0-9-]+(\\.[a-zA-Z0-9-]+)*\\.[a-zA-Z0-9]{2,6}$", message = "邮箱格式错误", groups = {add.class}) |
|
84 |
private String visitorEmail; |
|
85 |
|
|
86 |
/** |
|
87 |
* 访客主页 |
|
88 |
*/ |
|
89 |
@Pattern(regexp = "^$|^((https|http)?:\\/\\/)[^\\s]+", message = "主页格式错误", groups = {add.class}) |
|
90 |
private String visitorHomePage; |
|
91 |
|
|
92 |
/** |
|
93 |
* 留言内容(500字内) |
|
94 |
*/ |
|
95 |
@NotBlank(message = "留言内容不能为空", groups = {add.class}) |
|
96 |
private String commentContent; |
|
97 |
|
|
98 |
/** |
|
99 |
* 公开状态 1:公开 2:私密 3:密码授权 |
|
100 |
*/ |
|
101 |
@Min(value = 1, message = "公开状态参数异常,请检查authStatus参数", groups = {add.class}) |
|
102 |
@Max(value = 3, message = "公开状态参数异常,请检查authStatus参数", groups = {add.class}) |
|
103 |
@NotNull(message = "公开状态不能为空,请检查authStatus参数", groups = {add.class}) |
|
104 |
private Integer authStatus; |
|
105 |
|
|
106 |
/** |
|
107 |
* 是否接收回信 |
|
108 |
*/ |
|
109 |
@NotNull(message = "是否接收回信为空", groups = {add.class}) |
|
110 |
private Integer isReceiveMail; |
|
111 |
|
|
112 |
} |