From 4fe6e6e92730dcd8595cfca291aa0569ad407ae5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E7=90=B3?= <1911390090@qq.com> Date: Mon, 20 May 2024 10:31:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=8B=E4=BB=B6=20FacilityId()=20=3D=3Dnull?= =?UTF-8?q?=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../zc/business/service/impl/DcEventServiceImpl.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/zc-business/src/main/java/com/zc/business/service/impl/DcEventServiceImpl.java b/zc-business/src/main/java/com/zc/business/service/impl/DcEventServiceImpl.java index 99b4d8fc..f47a16ce 100644 --- a/zc-business/src/main/java/com/zc/business/service/impl/DcEventServiceImpl.java +++ b/zc-business/src/main/java/com/zc/business/service/impl/DcEventServiceImpl.java @@ -170,6 +170,10 @@ public class DcEventServiceImpl extends ServiceImpl impl String facilityId = String.valueOf(dcEvent.getDcEventTrafficControl().getFacilityIds()[0]); dcEvent.setStakeMark(extracted(facilityId)); } + if (eventType == 3 && dcEvent.getDcEventTrafficControl().getFacilityId() != null && dcEvent.getDcEventTrafficControl().getFacilityId()>0) { + String facilityId = String.valueOf(dcEvent.getDcEventTrafficControl().getFacilityId()); + dcEvent.setStakeMark(extracted(facilityId)); + } //交通拥堵 if (eventType == 4 && dcEvent.getDcEventTrafficCongestion().getFacilityId() != null) { String facilityId = String.valueOf(dcEvent.getDcEventTrafficCongestion().getFacilityId()); @@ -219,6 +223,11 @@ public class DcEventServiceImpl extends ServiceImpl impl //交通管制 case 3: if (dcEvent.getDcEventTrafficControl() != null) { + if (dcEvent.getDcEventTrafficControl().getFacilityId()==null || dcEvent.getDcEventTrafficControl().getFacilityId()>0){ + dcEvent.getDcEventTrafficControl().setId(uuid); + int i6 = dcEventTrafficControlMapper.insertDcEventTrafficControl(dcEvent.getDcEventTrafficControl()); + break; + } // 插入多个收费站 if (dcEvent.getDcEventTrafficControl().getFacilityIds().length == 1) {//facilityIds==1 说明只选择了一个收费站 @@ -352,6 +361,7 @@ public class DcEventServiceImpl extends ServiceImpl impl } } + } break; //交通拥堵