Commit 12e14f52 by Hayreal

修复小程序卡片朋友圈-生成测试链接

1 parent d06ea2be
...@@ -323,12 +323,15 @@ public class ExecuteTaskService { ...@@ -323,12 +323,15 @@ public class ExecuteTaskService {
attachmentDTO.setVideo(video); attachmentDTO.setVideo(video);
attachmentDTO.setMsgType("video"); attachmentDTO.setMsgType("video");
attachmentList.add(attachmentDTO); attachmentList.add(attachmentDTO);
} else if (attType.equals(URI)) { } else if (attType.equals(MINIPROGRAM)) {
WorkWechatMomentAttachmentDTO attachmentDTO = new WorkWechatMomentAttachmentDTO(); WorkWechatMomentAttachmentDTO attachmentDTO = new WorkWechatMomentAttachmentDTO();
attachmentDTO.setMsgType("link");
WorkWechatMomentAttachmentLinkDTO link = new WorkWechatMomentAttachmentLinkDTO(); WorkWechatMomentAttachmentLinkDTO link = new WorkWechatMomentAttachmentLinkDTO();
link.setUrl(buildShortURL(content.getAttContent())); JSONObject object = JSONObject.parseObject(content.getAttContent());
link.setUrl(getMiniProgramShortUrl(content.getAttContent(), request.getMerchantId()));
link.setMediaId(content.getMediaId());
link.setTitle(object.getString(link_title_key));
attachmentDTO.setLink(link); attachmentDTO.setLink(link);
attachmentDTO.setMsgType("link");
attachmentList.add(attachmentDTO); attachmentList.add(attachmentDTO);
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!