Commit bc375ff4 by 徐高华

结束不统计

parent 0b2d5ed6
......@@ -321,6 +321,7 @@ public class GroupChatPlanServiceImpl implements GroupChatPlanService {
int sendCount = 0;
int failCount = 0;
List<TabGroupChatPlanLog> addList = new ArrayList<>();
boolean endFlag = false ;
for (QywxSendMessageResultDTO item : list) {
TabGroupChatPlanLog entity = new TabGroupChatPlanLog();
Date sendTime = item.getSendTime();
......@@ -328,6 +329,7 @@ public class GroupChatPlanServiceImpl implements GroupChatPlanService {
// 如果企微的发送时间晚于计划的结束时间,不记录此类数据
if (sendTime.after(plan.getEndTime())) {
logger.info("发送时间晚计划结束");
endFlag = true ;
continue;
}
GroupChatBO chat = this.groupChatService.getByWxChatId(wxEnterpriseId, wxChatId);
......@@ -362,7 +364,9 @@ public class GroupChatPlanServiceImpl implements GroupChatPlanService {
}
if (CollectionUtils.isNotEmpty(addList)) {
this.groupChatPlanLogMapper.batchInsert(addList);
}
// 更新统计数量、状态
if(!endFlag) {
this.groupChatPlanOwnerLogService.updateSendCount(ownerLog.getOwnerLogId(), sendCount,
list.get(0).getSendTime(), failCount);
// 完成代办
......
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