|
|
@ -677,13 +677,10 @@ if (eventType !=3 &&dcEventId == null){//非 事件处置 和收费站等多条 |
|
|
|
@Override |
|
|
|
public int updateDcEvent(DcEvent dcEvent) { |
|
|
|
DcEvent oldEvent = selectEventSubclassById(dcEvent.getEventType().intValue(),dcEvent.getId()); |
|
|
|
|
|
|
|
dcEvent.setUpdateTime(DateUtils.getNowDate()); |
|
|
|
int i7 = dcEventMapper.updateDcEvent(dcEvent); |
|
|
|
if (i7 > 0) { |
|
|
|
|
|
|
|
String context = comparisonInfo(oldEvent,dcEvent); |
|
|
|
|
|
|
|
//事件处置流程记录
|
|
|
|
DcEventProcess dcEventProcess = new DcEventProcess(); |
|
|
|
dcEventProcess.setEventId(dcEvent.getId()); |
|
|
@ -691,7 +688,6 @@ if (eventType !=3 &&dcEventId == null){//非 事件处置 和收费站等多条 |
|
|
|
dcEventProcess.setContext(context); |
|
|
|
dcEventProcessService.insertDcEventProcess(dcEventProcess); |
|
|
|
|
|
|
|
|
|
|
|
//中间库
|
|
|
|
MdEvent mdEvent = new MdEvent(dcEvent); |
|
|
|
middleDatabaseService.updateMiddleDatabaseEvent(mdEvent); |
|
|
@ -760,59 +756,62 @@ if (eventType !=3 &&dcEventId == null){//非 事件处置 和收费站等多条 |
|
|
|
* @return 结果 |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
public int deleteDcEventByIds(int eventType, String[] ids) { |
|
|
|
int i7 = dcEventMapper.deleteDcEventByIds(ids); |
|
|
|
if (i7 > 0) { |
|
|
|
switch (eventType) { |
|
|
|
//交通事故
|
|
|
|
case 1: |
|
|
|
int i1 = dcEventAccidentMapper.deleteDcEventAccidentByIds(ids); |
|
|
|
break; |
|
|
|
//车辆事故
|
|
|
|
case 2: |
|
|
|
int i5 = dcEventVehicleAccidentMapper.deleteDcEventVehicleAccidentByIds(ids); |
|
|
|
break; |
|
|
|
//交通管制
|
|
|
|
case 3: |
|
|
|
int i6 = dcEventTrafficControlMapper.deleteDcEventTrafficControlByIds(ids); |
|
|
|
break; |
|
|
|
//交通拥堵
|
|
|
|
case 4: |
|
|
|
int i4 = dcEventTrafficCongestionMapper.deleteDcEventTrafficCongestionByIds(ids); |
|
|
|
public int deleteDcEventByIds(String[] ids) { |
|
|
|
int i7=-1; |
|
|
|
for (String id : ids) { |
|
|
|
DcEvent dcEvent = dcEventMapper.selectDcEventMainById(id); |
|
|
|
int eventType = Math.toIntExact(dcEvent.getEventType()); |
|
|
|
i7 = dcEventMapper.deleteDcEventById(id); |
|
|
|
|
|
|
|
break; |
|
|
|
//非法上路
|
|
|
|
case 5: |
|
|
|
break; |
|
|
|
//路障清除
|
|
|
|
case 6: |
|
|
|
break; |
|
|
|
//施工建设
|
|
|
|
case 7: |
|
|
|
int i2 = dcEventConstructionMapper.deleteDcEventConstructionByIds(ids); |
|
|
|
break; |
|
|
|
//服务区异常
|
|
|
|
case 8: |
|
|
|
int i3 = dcEventServiceAreaMapper.deleteDcEventServiceAreaByIds(ids); |
|
|
|
break; |
|
|
|
//设施设备隐患
|
|
|
|
case 9: |
|
|
|
break; |
|
|
|
//异常天气
|
|
|
|
case 10: |
|
|
|
int i = dcEventAbnormalWeatherMapper.deleteDcEventAbnormalWeatherByIds(ids); |
|
|
|
break; |
|
|
|
//其他事件
|
|
|
|
case 11: |
|
|
|
break; |
|
|
|
//
|
|
|
|
default: |
|
|
|
break; |
|
|
|
switch (eventType) { |
|
|
|
//交通事故
|
|
|
|
case 1: |
|
|
|
int i1 = dcEventAccidentMapper.deleteDcEventAccidentById(id); |
|
|
|
break; |
|
|
|
//车辆事故
|
|
|
|
case 2: |
|
|
|
int i5 = dcEventVehicleAccidentMapper.deleteDcEventVehicleAccidentById(id); |
|
|
|
break; |
|
|
|
//交通管制
|
|
|
|
case 3: |
|
|
|
int i6 = dcEventTrafficControlMapper.deleteDcEventTrafficControlById(id); |
|
|
|
break; |
|
|
|
//交通拥堵
|
|
|
|
case 4: |
|
|
|
int i4 = dcEventTrafficCongestionMapper.deleteDcEventTrafficCongestionById(id); |
|
|
|
|
|
|
|
break; |
|
|
|
//非法上路
|
|
|
|
case 5: |
|
|
|
break; |
|
|
|
//路障清除
|
|
|
|
case 6: |
|
|
|
break; |
|
|
|
//施工建设
|
|
|
|
case 7: |
|
|
|
int i2 = dcEventConstructionMapper.deleteDcEventConstructionById(id); |
|
|
|
break; |
|
|
|
//服务区异常
|
|
|
|
case 8: |
|
|
|
int i3 = dcEventServiceAreaMapper.deleteDcEventServiceAreaById(id); |
|
|
|
break; |
|
|
|
//设施设备隐患
|
|
|
|
case 9: |
|
|
|
break; |
|
|
|
//异常天气
|
|
|
|
case 10: |
|
|
|
int i = dcEventAbnormalWeatherMapper.deleteDcEventAbnormalWeatherById(id); |
|
|
|
break; |
|
|
|
//其他事件
|
|
|
|
case 11: |
|
|
|
break; |
|
|
|
//
|
|
|
|
default: |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|
return i7; |
|
|
|
} else { |
|
|
|
return -1; |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|