Commit df578ffe by 裴大威

Merge branch 'feat-1002291-new' into 'master'

feat 1002291

See merge request rays/pcloud-book!379
parents 91115a54 1c754dc2
......@@ -683,6 +683,7 @@ public class SelfRobotKeywordBizImpl implements SelfRobotKeywordBiz {
taskSubscribeBiz.subscribeTask(wxUserId,null,relSkillId,robotId);
}else if (2 == type){
pcloudGroupActivityBiz.processGroup(wxUserId,robotId,Long.valueOf(relSkillId.toString()));
pcloudSkillBiz.sendResource(id,wxUserId,robotId,relSkillId);
}else if (3 == type){
pcloudSkillBiz.sendResource(id,wxUserId,robotId,relSkillId);
}
......
......@@ -18,6 +18,7 @@ import com.pcloud.common.core.aspect.ParamLog;
import com.pcloud.common.page.PageBeanNew;
import com.pcloud.common.page.PageParam;
import com.sdk.wxgroup.SendGroupInviteVO;
import com.sdk.wxgroup.SendPicMessageVO;
import com.sdk.wxgroup.WxGroupSDK;
import org.springframework.stereotype.Service;
......@@ -87,18 +88,28 @@ public class PcloudGroupActivityBizImpl implements PcloudGroupActivityBiz {
log.error("[processGroup] error 共读不存在");
return;
}
GroupQrcodeBaseInfoVO groupQrcode = groupQrcodeBiz.getBaseById(byId.getBookGroupQrcodeId());
if (Objects.isNull(groupQrcode)) {
log.error("[processGroup] error 共读对应社群不存在");
return;
if (0 == byId.getJoinType()) {
GroupQrcodeBaseInfoVO groupQrcode = groupQrcodeBiz.getBaseById(byId.getBookGroupQrcodeId());
if (Objects.isNull(groupQrcode)) {
log.error("[processGroup] error 共读对应社群不存在");
return;
}
SendGroupInviteVO vo = new SendGroupInviteVO();
vo.setWxId(wxId);
vo.setAltId(robotWxId);
vo.setIp(readingActivityBiz.getIP(robotWxId));
vo.setWxGroupId(groupQrcode.getWeixinGroupId());
WxGroupSDK.sendGroupInvite(vo);
log.info("[processGroup] sendGroupInvite:{}", vo);
}
if (1 == byId.getJoinType()) {
SendPicMessageVO vo = new SendPicMessageVO();
vo.setPicUrl(byId.getGroupPic());
vo.setWxGroupId(wxId);
vo.setAltId(robotWxId);
vo.setIp(readingActivityBiz.getIP(robotWxId));
WxGroupSDK.sendPicMessage(vo);
}
SendGroupInviteVO vo = new SendGroupInviteVO();
vo.setWxId(wxId);
vo.setAltId(robotWxId);
vo.setIp(readingActivityBiz.getIP(robotWxId));
vo.setWxGroupId(groupQrcode.getWeixinGroupId());
WxGroupSDK.sendGroupInvite(vo);
log.info("[processGroup] sendGroupInvite:{}", vo);
}
@Override
......
......@@ -390,7 +390,7 @@ public class PcloudSkillBizImpl implements PcloudSkillBiz {
} else if(WelcomeReplyTypeEnum.RESOURCE.value.equals(type)) {
SendFileVO sendFileVO = new SendFileVO();
sendFileVO.setFileUrl(reply.getResourceUrl());
sendFileVO.setFileName(reply.getResourceName());
sendFileVO.setFileName(reply.getContent().split(".")[0]);
sendFileVO.setIp(ip);
sendFileVO.setAltId(robotWxId);
sendFileVO.setWxId(userWxId);
......
......@@ -31,8 +31,8 @@
<select id="queryGroupActivity" resultType="com.pcloud.book.skill.facade.response.QueryGroupActivityResponseVO" parameterType="map" >
SELECT
a.id,
a.NAME,
a.description,
a.`name`,
a.description as `desc`,
a.join_type AS joinType,
a.group_pic AS groupPic,
a.book_group_qrcode_id AS bookGroupQrcodeId,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment