Commit 864ab228 by songyinghui

feat: 客户触达人数消息

parent 61e6dff4
......@@ -2,6 +2,7 @@ package com.gic.haoban.manage.service.service.content.impl;
import com.alibaba.fastjson.JSON;
import com.gic.api.base.commons.ServiceResponse;
import com.gic.commons.util.DateUtil;
import com.gic.commons.util.UniqueIdUtils;
import com.gic.haoban.manage.api.dto.WxEnterpriseQwDTO;
import com.gic.haoban.manage.api.enums.content.ClerkShareMaterialType;
......@@ -338,7 +339,7 @@ public class GroupMessageServiceImpl implements GroupMessageService {
if (qwInfo.needOpenUserId3th()) {
userId = staff.getWxOpenUseId();
}
List<String> externalUserIds = this.queryMomentResult(corpId, userId, groupMessageInfoBo.getStartTime(), groupMessageInfoBo.getEndTime());
List<String> externalUserIds = this.queryMomentResult(corpId, userId);
if (CollectionUtils.isEmpty(externalUserIds)) {
log.info("处理导购群发朋友圈触达客户日志, 成员无好友. staffId:{}", clerkShareLogBo.getStaffId());
return;
......@@ -468,17 +469,16 @@ public class GroupMessageServiceImpl implements GroupMessageService {
* 查询发朋友圈结果
* @param corpid
* @param userId
* @param startTime
* @param endTime
* @return
*/
public List<String> queryMomentResult(String corpid, String userId, Date startTime, Date endTime) {
public List<String> queryMomentResult(String corpid, String userId) {
Date currentTime = new Date();
QywxMomentInfoQDTO qywxMomentInfoQDTO = new QywxMomentInfoQDTO();
qywxMomentInfoQDTO.setCorpid(corpid);
qywxMomentInfoQDTO.setSuiteid(config.getWxSuiteid());
qywxMomentInfoQDTO.setStartTime(startTime.getTime() / 1000);
qywxMomentInfoQDTO.setEndTime(endTime.getTime() / 1000);
qywxMomentInfoQDTO.setStartTime(DateUtil.addNumForMinute(currentTime, -30).getTime() / 1000);
qywxMomentInfoQDTO.setEndTime(currentTime.getTime() / 1000);
qywxMomentInfoQDTO.setCreatorId(userId);
qywxMomentInfoQDTO.setPageSize(20);
ServiceResponse<QywxMomentRespDTO> serviceResponse = qywxSuiteApiService.queryQywxMomentList(qywxMomentInfoQDTO);
......
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