|
|
@@ -31,7 +31,6 @@ import java.util.concurrent.TimeUnit;
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
import static com.tzld.piaoquan.growth.common.common.constant.MessageConstant.MAX_VIDEO_NUM;
|
|
|
-import static com.tzld.piaoquan.growth.common.common.constant.MessageConstant.specialStaffIdList;
|
|
|
import static com.tzld.piaoquan.growth.common.common.constant.WeComConstant.*;
|
|
|
import static com.tzld.piaoquan.growth.common.common.enums.SourceEnum.HISTORICAL_TOP;
|
|
|
import static com.tzld.piaoquan.growth.common.common.enums.SourceEnum.MANUAL;
|
|
|
@@ -168,14 +167,14 @@ public class WeComHistoryDataJob {
|
|
|
successSendCount += sendCountList.get(1);
|
|
|
notFriendCount += sendCountList.get(2);
|
|
|
failSendCount += sendCountList.get(3);
|
|
|
- if (sendCountList.get(0) > 0 && !specialStaffIdList.contains(sendDetail.getStaffId())) {
|
|
|
- //LarkRobotUtil.sendMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
- //LarkRobotUtil.sendTipMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
- //8点前报警
|
|
|
- if (DateUtil.getHourOfDay() < 8 && (corpId == 1 || corpId == 3)) {
|
|
|
- LarkRobotUtil.sendNotPushMessage("<at user_id=\"g6732afb\">王云鹏</at> " + sendDetail.getRemark() + " 存在未发送记录,请检查");
|
|
|
- }
|
|
|
- }
|
|
|
+ //if (sendCountList.get(0) > 0 && !specialStaffIdList.contains(sendDetail.getStaffId())) {
|
|
|
+ // LarkRobotUtil.sendMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
+ // LarkRobotUtil.sendTipMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
+ // //8点前报警
|
|
|
+ // if (DateUtil.getHourOfDay() < 9 && (corpId == 1 || corpId == 3)) {
|
|
|
+ // LarkRobotUtil.sendNotPushMessage("<at user_id=\"all\">所有人</at> " + sendDetail.getRemark() + " 存在未发送记录,请检查");
|
|
|
+ // }
|
|
|
+ //}
|
|
|
|
|
|
JSONObject row = new JSONObject();
|
|
|
row.put("name", sendDetail.getRemark());
|
|
|
@@ -199,13 +198,16 @@ public class WeComHistoryDataJob {
|
|
|
JSONObject bodyParam = buildCheckQWMsg(corpName, rows);
|
|
|
LarkRobotUtil.sendMessage(bodyParam);
|
|
|
LarkRobotUtil.sendTipMessage(bodyParam);
|
|
|
+ if (DateUtil.getHourOfDay() < 9 && (corpId == 1 || corpId == 3)) {
|
|
|
+ LarkRobotUtil.sendNotPushMessage(bodyParam);
|
|
|
+ }
|
|
|
}
|
|
|
return notSendCount;
|
|
|
}
|
|
|
|
|
|
private JSONObject buildCheckQWMsg(String corpName, List<JSONObject> rows) {
|
|
|
List<FeishuTableDTO.Column> columns = buildCheckQWMsgSendColumns();
|
|
|
- FeishuTableDTO tableDTO = FeishuTableDTO.createTable(corpName, columns, rows, false);
|
|
|
+ FeishuTableDTO tableDTO = FeishuTableDTO.createTable(corpName, columns, rows, true);
|
|
|
JSONObject content = JSONObject.parseObject(JSONObject.toJSONString(tableDTO));
|
|
|
JSONObject bodyParam = new JSONObject();
|
|
|
bodyParam.put("msg_type", "interactive");
|
|
|
@@ -316,14 +318,14 @@ public class WeComHistoryDataJob {
|
|
|
}
|
|
|
|
|
|
|
|
|
- if (count == sendCountList.get(0)) {
|
|
|
- //LarkRobotUtil.sendMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
- if (sendDetail.getStaffId() == 3) {
|
|
|
- //LarkRobotUtil.sendTipMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
- } else {
|
|
|
- LarkRobotUtil.sendNotPushMessage("<at user_id=\"g6732afb\">王云鹏</at> " + sendDetail.getRemark() + " 存在未发送记录,请检查");
|
|
|
- }
|
|
|
- }
|
|
|
+ //if (count == sendCountList.get(0)) {
|
|
|
+ // //LarkRobotUtil.sendMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
+ // if (sendDetail.getStaffId() == 3) {
|
|
|
+ // //LarkRobotUtil.sendTipMessage(sendDetail.getRemark() + "存在未发送记录,请检查");
|
|
|
+ // } else {
|
|
|
+ // LarkRobotUtil.sendNotPushMessage("<at user_id=\"all\">所有人</at> " + sendDetail.getRemark() + " 存在未发送记录,请检查");
|
|
|
+ // }
|
|
|
+ //}
|
|
|
JSONObject row = new JSONObject();
|
|
|
row.put("name", sendDetail.getRemark());
|
|
|
row.put("totalCount", count);
|
|
|
@@ -336,6 +338,9 @@ public class WeComHistoryDataJob {
|
|
|
JSONObject bodyParam = buildCheckQWMsg(corpName, rows);
|
|
|
LarkRobotUtil.sendMessage(bodyParam);
|
|
|
LarkRobotUtil.sendTipMessage(bodyParam);
|
|
|
+ if (DateUtil.getHourOfDay() < 9 && (corpId == 1 || corpId == 3)) {
|
|
|
+ LarkRobotUtil.sendNotPushMessage(bodyParam);
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
private void selectGroupMsgList(Long startTime, Long endTime, Long corpId, Long staffId) {
|