|
@@ -1,7 +1,7 @@
|
|
package cn.iocoder.yudao.module.mp.controller.admin.menu.vo;
|
|
package cn.iocoder.yudao.module.mp.controller.admin.menu.vo;
|
|
|
|
|
|
import cn.iocoder.yudao.module.mp.dal.dataobject.message.MpMessageDO;
|
|
import cn.iocoder.yudao.module.mp.dal.dataobject.message.MpMessageDO;
|
|
-import io.swagger.annotations.ApiModelProperty;
|
|
|
|
|
|
+import io.swagger.v3.oas.annotations.media.Schema;
|
|
import lombok.Data;
|
|
import lombok.Data;
|
|
import me.chanjar.weixin.common.api.WxConsts;
|
|
import me.chanjar.weixin.common.api.WxConsts;
|
|
import org.hibernate.validator.constraints.URL;
|
|
import org.hibernate.validator.constraints.URL;
|
|
@@ -44,54 +44,53 @@ public class MpMenuBaseVO {
|
|
*/
|
|
*/
|
|
private String type;
|
|
private String type;
|
|
|
|
|
|
- @ApiModelProperty(value = "网页链接", example = "https://www.iocoder.cn/")
|
|
|
|
|
|
+ @Schema(description = "网页链接", example = "https://www.iocoder.cn/")
|
|
@NotEmpty(message = "网页链接不能为空", groups = {ViewButtonGroup.class, MiniProgramButtonGroup.class})
|
|
@NotEmpty(message = "网页链接不能为空", groups = {ViewButtonGroup.class, MiniProgramButtonGroup.class})
|
|
@URL(message = "网页链接必须是 URL 格式")
|
|
@URL(message = "网页链接必须是 URL 格式")
|
|
private String url;
|
|
private String url;
|
|
|
|
|
|
- @ApiModelProperty(value = "小程序的 appId", example = "wx1234567890")
|
|
|
|
|
|
+ @Schema(description = "小程序的 appId", example = "wx1234567890")
|
|
@NotEmpty(message = "小程序的 appId 不能为空", groups = MiniProgramButtonGroup.class)
|
|
@NotEmpty(message = "小程序的 appId 不能为空", groups = MiniProgramButtonGroup.class)
|
|
private String miniProgramAppId;
|
|
private String miniProgramAppId;
|
|
|
|
|
|
- @ApiModelProperty(value = "小程序的页面路径", example = "pages/index/index")
|
|
|
|
|
|
+ @Schema(description = "小程序的页面路径", example = "pages/index/index")
|
|
@NotEmpty(message = "小程序的页面路径不能为空", groups = MiniProgramButtonGroup.class)
|
|
@NotEmpty(message = "小程序的页面路径不能为空", groups = MiniProgramButtonGroup.class)
|
|
private String miniProgramPagePath;
|
|
private String miniProgramPagePath;
|
|
|
|
|
|
- @ApiModelProperty(value ="跳转图文的媒体编号", example = "jCQk93AIIgp8ixClWcW_NXXqBKInNWNmq2XnPeDZl7IMVqWiNeL4FfELtggRXd83")
|
|
|
|
|
|
+ @Schema(description ="跳转图文的媒体编号", example = "jCQk93AIIgp8ixClWcW_NXXqBKInNWNmq2XnPeDZl7IMVqWiNeL4FfELtggRXd83")
|
|
@NotEmpty(message = "跳转图文的媒体编号不能为空", groups = ViewLimitedButtonGroup.class)
|
|
@NotEmpty(message = "跳转图文的媒体编号不能为空", groups = ViewLimitedButtonGroup.class)
|
|
private String articleId;
|
|
private String articleId;
|
|
|
|
|
|
// ========== 消息内容 ==========
|
|
// ========== 消息内容 ==========
|
|
|
|
|
|
- @ApiModelProperty(value = "回复的消息类型", example = "text",
|
|
|
|
- notes = "枚举 TEXT、IMAGE、VOICE、VIDEO、NEWS、MUSIC")
|
|
|
|
|
|
+ @Schema(description = "回复的消息类型 枚举 TEXT、IMAGE、VOICE、VIDEO、NEWS、MUSIC", example = "text")
|
|
@NotEmpty(message = "回复的消息类型不能为空", groups = {ClickButtonGroup.class, ScanCodeWaitMsgButtonGroup.class})
|
|
@NotEmpty(message = "回复的消息类型不能为空", groups = {ClickButtonGroup.class, ScanCodeWaitMsgButtonGroup.class})
|
|
private String replyMessageType;
|
|
private String replyMessageType;
|
|
|
|
|
|
- @ApiModelProperty(value = "回复的消息内容", example = "欢迎关注")
|
|
|
|
|
|
+ @Schema(description = "回复的消息内容", example = "欢迎关注")
|
|
@NotEmpty(message = "回复的消息内容不能为空", groups = TextMessageGroup.class)
|
|
@NotEmpty(message = "回复的消息内容不能为空", groups = TextMessageGroup.class)
|
|
private String replyContent;
|
|
private String replyContent;
|
|
|
|
|
|
- @ApiModelProperty(value = "回复的媒体 id", example = "123456")
|
|
|
|
|
|
+ @Schema(description = "回复的媒体 id", example = "123456")
|
|
@NotEmpty(message = "回复的消息 mediaId 不能为空",
|
|
@NotEmpty(message = "回复的消息 mediaId 不能为空",
|
|
groups = {ImageMessageGroup.class, VoiceMessageGroup.class, VideoMessageGroup.class})
|
|
groups = {ImageMessageGroup.class, VoiceMessageGroup.class, VideoMessageGroup.class})
|
|
private String replyMediaId;
|
|
private String replyMediaId;
|
|
- @ApiModelProperty(value = "回复的媒体 URL", example = "https://www.iocoder.cn/xxx.jpg")
|
|
|
|
|
|
+ @Schema(description = "回复的媒体 URL", example = "https://www.iocoder.cn/xxx.jpg")
|
|
@NotEmpty(message = "回复的消息 mediaId 不能为空",
|
|
@NotEmpty(message = "回复的消息 mediaId 不能为空",
|
|
groups = {ImageMessageGroup.class, VoiceMessageGroup.class, VideoMessageGroup.class})
|
|
groups = {ImageMessageGroup.class, VoiceMessageGroup.class, VideoMessageGroup.class})
|
|
private String replyMediaUrl;
|
|
private String replyMediaUrl;
|
|
|
|
|
|
- @ApiModelProperty(value = "缩略图的媒体 id", example = "123456")
|
|
|
|
|
|
+ @Schema(description = "缩略图的媒体 id", example = "123456")
|
|
@NotEmpty(message = "回复的消息 thumbMediaId 不能为空", groups = {MusicMessageGroup.class})
|
|
@NotEmpty(message = "回复的消息 thumbMediaId 不能为空", groups = {MusicMessageGroup.class})
|
|
private String replyThumbMediaId;
|
|
private String replyThumbMediaId;
|
|
- @ApiModelProperty(value = "缩略图的媒体 URL",example = "https://www.iocoder.cn/xxx.jpg")
|
|
|
|
|
|
+ @Schema(description = "缩略图的媒体 URL",example = "https://www.iocoder.cn/xxx.jpg")
|
|
@NotEmpty(message = "回复的消息 thumbMedia 地址不能为空", groups = {MusicMessageGroup.class})
|
|
@NotEmpty(message = "回复的消息 thumbMedia 地址不能为空", groups = {MusicMessageGroup.class})
|
|
private String replyThumbMediaUrl;
|
|
private String replyThumbMediaUrl;
|
|
|
|
|
|
- @ApiModelProperty(value = "回复的标题", example = "视频标题")
|
|
|
|
|
|
+ @Schema(description = "回复的标题", example = "视频标题")
|
|
@NotEmpty(message = "回复的消息标题不能为空", groups = VideoMessageGroup.class)
|
|
@NotEmpty(message = "回复的消息标题不能为空", groups = VideoMessageGroup.class)
|
|
private String replyTitle;
|
|
private String replyTitle;
|
|
- @ApiModelProperty(value = "回复的描述", example = "视频描述")
|
|
|
|
|
|
+ @Schema(description = "回复的描述", example = "视频描述")
|
|
@NotEmpty(message = "消息描述不能为空", groups = VideoMessageGroup.class)
|
|
@NotEmpty(message = "消息描述不能为空", groups = VideoMessageGroup.class)
|
|
private String replyDescription;
|
|
private String replyDescription;
|
|
|
|
|
|
@@ -104,11 +103,11 @@ public class MpMenuBaseVO {
|
|
@Valid
|
|
@Valid
|
|
private List<MpMessageDO.Article> replyArticles;
|
|
private List<MpMessageDO.Article> replyArticles;
|
|
|
|
|
|
- @ApiModelProperty(value = "回复的音乐链接", example = "https://www.iocoder.cn/xxx.mp3")
|
|
|
|
|
|
+ @Schema(description = "回复的音乐链接", example = "https://www.iocoder.cn/xxx.mp3")
|
|
@NotEmpty(message = "回复的音乐链接不能为空", groups = MusicMessageGroup.class)
|
|
@NotEmpty(message = "回复的音乐链接不能为空", groups = MusicMessageGroup.class)
|
|
@URL(message = "回复的高质量音乐链接格式不正确", groups = MusicMessageGroup.class)
|
|
@URL(message = "回复的高质量音乐链接格式不正确", groups = MusicMessageGroup.class)
|
|
private String replyMusicUrl;
|
|
private String replyMusicUrl;
|
|
- @ApiModelProperty(value = "高质量音乐链接", example = "https://www.iocoder.cn/xxx.mp3")
|
|
|
|
|
|
+ @Schema(description = "高质量音乐链接", example = "https://www.iocoder.cn/xxx.mp3")
|
|
@NotEmpty(message = "回复的高质量音乐链接不能为空", groups = MusicMessageGroup.class)
|
|
@NotEmpty(message = "回复的高质量音乐链接不能为空", groups = MusicMessageGroup.class)
|
|
@URL(message = "回复的高质量音乐链接格式不正确", groups = MusicMessageGroup.class)
|
|
@URL(message = "回复的高质量音乐链接格式不正确", groups = MusicMessageGroup.class)
|
|
private String replyHqMusicUrl;
|
|
private String replyHqMusicUrl;
|