From aa4130ad7d9e5aa83136a755e2e1e4a1767ef353 Mon Sep 17 00:00:00 2001 From: liuchengqian Date: Mon, 24 Oct 2022 14:12:44 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A6=82=E6=9E=9C=E6=98=AF=E5=B1=B1=E4=B8=9C?= =?UTF-8?q?=E7=9A=84=E9=9D=9E=E8=80=95=E5=9C=B0=E7=81=AB=E7=82=B9=EF=BC=8C?= =?UTF-8?q?=E5=B0=B1=E8=80=83=E8=99=91=E5=85=A5=E5=BA=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/FirePointServiceImpl.java | 32 +++++++++---------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java index aad629f..a85db95 100644 --- a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java +++ b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java @@ -126,31 +126,29 @@ public class FirePointServiceImpl implements FirePointService { return false; } if (firePointEntity.getCountyCode().startsWith("37")) { - //如果是山东的点,就入库 if (isSwitchStateOpen()) { - //如果开关已打开,就只将未审核的火点添加到山东临时表 - log.info("-------发现新山东火点"); - ShanDongFirePointEntity shanDongFirePointByFirePoint = getShanDongFirePointByFirePoint(firePointEntity); - ShanDongFirePointEntity savedShanDongFirePoint = shanDongFirePointDao.save(shanDongFirePointByFirePoint); - //微信消息通知火点审核工作组 - try { - String messageContent = getMessageContent(savedShanDongFirePoint); - WDWxSendMsgUtil.sendMsg("18447024917@chatroom", messageContent, 0); - } catch (Exception e) { - e.printStackTrace(); + //如果是山东的非耕地火点,就考虑入库 + if (!"耕地".equals(firePointEntity.getLandType())) { + //如果开关已打开,就只将未审核的火点添加到山东临时表 + log.info("-------发现新山东火点"); + ShanDongFirePointEntity shanDongFirePointByFirePoint = getShanDongFirePointByFirePoint(firePointEntity); + ShanDongFirePointEntity savedShanDongFirePoint = shanDongFirePointDao.save(shanDongFirePointByFirePoint); + //微信消息通知火点审核工作组 + try { + String messageContent = getMessageContent(savedShanDongFirePoint); + WDWxSendMsgUtil.sendMsg("18447024917@chatroom", messageContent, 0); + } catch (Exception e) { + e.printStackTrace(); + } + return true; } - return true; - } else { - return false; } } else { log.info("-------发现新火点"); firePointDao.save(firePointEntity); return true; } -// log.info("-------发现新火点"); -// firePointDao.save(firePointEntity); -// return true; + return false; } /**