From 804758086e9973e1796ff0bcbe4ca2d74c4b4774 Mon Sep 17 00:00:00 2001 From: liuchengqian Date: Thu, 20 Mar 2025 16:24:29 +0800 Subject: [PATCH] =?UTF-8?q?=E6=AD=A3=E5=B8=B8=E5=8F=91=E9=80=81=20?= =?UTF-8?q?=E6=9C=80=E8=BF=91=E5=AF=B9=E6=8E=A5=E7=9A=84=E5=AE=A2=E6=88=B7?= =?UTF-8?q?=E5=9C=A8=E6=B5=8B=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/FirePointServiceImpl.java | 42 +++++++++---------- 1 file changed, 20 insertions(+), 22 deletions(-) diff --git a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java index b518b04..ead0e3c 100644 --- a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java +++ b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java @@ -2,9 +2,7 @@ package com.xkrs.service.impl; import com.xkrs.common.encapsulation.PromptMessageEnum; import com.xkrs.dao.*; -import com.xkrs.model.entity.CountyCodeWeiXinEntity; -import com.xkrs.model.entity.FirePointEntity; -import com.xkrs.model.entity.ShanDongFirePointEntity; +import com.xkrs.model.entity.*; import com.xkrs.model.qo.FirePointQo; import com.xkrs.model.vo.TianDiTuGeocodeVo; import com.xkrs.service.FirePointService; @@ -224,25 +222,25 @@ public class FirePointServiceImpl implements FirePointService { //发送微信群聊消息 sendWeChatGroupMessage(firePointEntity); -// if ("耕地".equals(firePointEntity.getLandType())) { -// //过滤短信通知收件人 -// List sysUserList = sysUserDao.findAll(); -// boolean normalSmsEnable = 1L == globalConfigService.selectGlobalConfigValue(9L); -// boolean vipSmsEnable = 1L == globalConfigService.selectGlobalConfigValue(10L); -// List smsReceiverList = FirePointCodeUtils.filterSmsReceiver(firePointEntity.getStreetCode(), sysUserList, normalSmsEnable, vipSmsEnable); -//// //推送 -//// try { -//// List userAccountList = pushHelper.obtainUserAccountList(smsReceiverList); -//// pushHelper.dispatchPushMessage(userAccountList, firePointEntity); -//// } catch (Exception e) { -//// e.printStackTrace(); -//// } -// //对短信通知收件人进行分组 -// List agentOrgList = agentOrgDao.findAll(); -// Map> agentOrgNameGroupMap = FirePointCodeUtils.groupSmsReceiver(smsReceiverList, agentOrgList); -// //分发短信通知 -// smsHelper.dispatchSMSMessage(agentOrgNameGroupMap, new String[]{firePointEntity.getFirePointAddress()}, new FirePointEntity[]{firePointEntity}); -// } + if ("耕地".equals(firePointEntity.getLandType())) { + //过滤短信通知收件人 + List sysUserList = sysUserDao.findAll(); + boolean normalSmsEnable = 1L == globalConfigService.selectGlobalConfigValue(9L); + boolean vipSmsEnable = 1L == globalConfigService.selectGlobalConfigValue(10L); + List smsReceiverList = FirePointCodeUtils.filterSmsReceiver(firePointEntity.getStreetCode(), sysUserList, normalSmsEnable, vipSmsEnable); +// //推送 +// try { +// List userAccountList = pushHelper.obtainUserAccountList(smsReceiverList); +// pushHelper.dispatchPushMessage(userAccountList, firePointEntity); +// } catch (Exception e) { +// e.printStackTrace(); +// } + //对短信通知收件人进行分组 + List agentOrgList = agentOrgDao.findAll(); + Map> agentOrgNameGroupMap = FirePointCodeUtils.groupSmsReceiver(smsReceiverList, agentOrgList); + //分发短信通知 + smsHelper.dispatchSMSMessage(agentOrgNameGroupMap, new String[]{firePointEntity.getFirePointAddress()}, new FirePointEntity[]{firePointEntity}); + } } /**