Browse Source

Merge remote-tracking branch 'origin/develop' into develop

develop
王兴琳 6 months ago
parent
commit
8df5e70be9
  1. 38
      zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java
  2. 9
      zc-business/src/main/java/com/zc/business/controller/DcWarningController.java
  3. 110
      zc-business/src/main/java/com/zc/business/domain/DcPublishManage.java
  4. 25
      zc-business/src/main/java/com/zc/business/domain/DcWarning.java
  5. 2
      zc-business/src/main/java/com/zc/business/mapper/DcPublishManageMapper.java
  6. 3
      zc-business/src/main/java/com/zc/business/mapper/DcWarningMapper.java
  7. 2
      zc-business/src/main/java/com/zc/business/service/IDcPublishManageService.java
  8. 2
      zc-business/src/main/java/com/zc/business/service/IDcWarningService.java
  9. 5
      zc-business/src/main/java/com/zc/business/service/impl/DcPublishManageServiceImpl.java
  10. 6
      zc-business/src/main/java/com/zc/business/service/impl/DcWarningServiceImpl.java
  11. 53
      zc-business/src/main/resources/mapper/business/DcPublishManageMapper.xml
  12. 2
      zc-business/src/main/resources/mapper/business/DcPublishingChannelsMapper.xml
  13. 14
      zc-business/src/main/resources/mapper/business/DcWarningMapper.xml

38
zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java

@ -26,7 +26,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
/** /**
* 信息发布管理记录Controller * 信息发布管理记录Controller
* *
* @author ruoyi * @author ruoyi
* @date 2024-04-19 * @date 2024-04-19
*/ */
@ -60,18 +60,7 @@ public class DcPublishManageController extends BaseController
} }
return AjaxResult.success(dcPublishManageService.selectEventDcPublishManageList(dcPublishManage)); return AjaxResult.success(dcPublishManageService.selectEventDcPublishManageList(dcPublishManage));
} }
/**
* 导出信息发布管理记录列表
*/
@PreAuthorize("@ss.hasPermi('business:manage:export')")
@Log(title = "信息发布管理记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, DcPublishManage dcPublishManage)
{
List<DcPublishManage> list = dcPublishManageService.selectDcPublishManageList(dcPublishManage);
ExcelUtil<DcPublishManage> util = new ExcelUtil<>(DcPublishManage.class);
util.exportExcel(response, list, "信息发布管理记录数据");
}
/** /**
* 获取信息发布管理记录详细信息 * 获取信息发布管理记录详细信息
@ -157,4 +146,27 @@ public class DcPublishManageController extends BaseController
} }
return AjaxResult.success(dcPublishManageService.eventTypePublishManageMonth(dcPublishManage)); return AjaxResult.success(dcPublishManageService.eventTypePublishManageMonth(dcPublishManage));
} }
/**
* 公众服务统计查询
*/
@PostMapping("/statisticsList")
public TableDataInfo statisticsList(@RequestBody DcPublishManage dcPublishManage)
{
startPage();
List<DcPublishManage> list = dcPublishManageService.selectDcPublishManageStatistics(dcPublishManage);
return getDataTable(list);
}
/**
* 公众服务统计导出
*/
@PreAuthorize("@ss.hasPermi('business:manage:export')")
@Log(title = "信息发布管理记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, DcPublishManage dcPublishManage)
{
List<DcPublishManage> list = dcPublishManageService.selectDcPublishManageStatistics(dcPublishManage);
ExcelUtil<DcPublishManage> util = new ExcelUtil<>(DcPublishManage.class);
util.exportExcel(response, list, "信息发布管理记录数据");
}
} }

9
zc-business/src/main/java/com/zc/business/controller/DcWarningController.java

@ -174,4 +174,13 @@ public class DcWarningController extends BaseController
} }
return toAjax(dcWarningService.insertDispatchSource(map)); return toAjax(dcWarningService.insertDispatchSource(map));
} }
//感知事件误报
@PostMapping("/falseAlarm")
public AjaxResult falseAlarmResolution(@RequestBody DcWarning dcWarning){
if (dcWarning==null||dcWarning.getRelieveType()==null||StringUtils.isBlank(dcWarning.getId())){
return AjaxResult.error("参数错误");
}
return toAjax(dcWarningService.falseAlarmResolution(dcWarning));
}
} }

110
zc-business/src/main/java/com/zc/business/domain/DcPublishManage.java

@ -10,7 +10,7 @@ import org.omg.CORBA.INTERNAL;
/** /**
* 信息发布管理记录对象 dc_publish_manage * 信息发布管理记录对象 dc_publish_manage
* *
* @author ruoyi * @author ruoyi
* @date 2024-04-19 * @date 2024-04-19
*/ */
@ -22,27 +22,27 @@ public class DcPublishManage extends BaseEntity
private Long id; private Long id;
/** 事件编号 */ /** 事件编号 */
@Excel(name = "事件编号") //@Excel(name = "事件编号")
private String eventId; private String eventId;
/** 所属机构 */ /** 所属机构 */
@Excel(name = "所属机构") //@Excel(name = "所属机构")
private Long deptId; private Long deptId;
/** 发布渠道ID */ /** 发布渠道ID */
@Excel(name = "发布渠道ID") //@Excel(name = "发布渠道ID")
private Long publishChannelsId; private Long publishChannelsId;
/** 标题 */ /** 标题 */
@Excel(name = "标题") //@Excel(name = "标题")
private String title; private String title;
/** 发布渠道:多选用逗号隔开1-手机短信2-微信公众号3-微博4-情报板5-服务网站6-微信小程序 */ /** 发布渠道:多选用逗号隔开1-手机短信2-微信公众号3-微博4-情报板5-服务网站6-微信小程序 */
@Excel(name = "发布渠道",readConverterExp="1=手机短信,2=微信公众号,3=微博,4=情报板,5=服务网站,6=微信小程序") @Excel(name = "发布渠道",readConverterExp="1=手机短信,2=微信公众号,3=微博,4=情报板,5=服务网站,6=微信小程序,7=语音广播")
private Integer publishChannels; private Integer publishChannels;
/** 审核状态:0-待审核1-已审核2-未通过 */ /** 审核状态:0-待审核1-已审核2-未通过 */
@Excel(name = "审核状态: 0-待审核 1-已审核 2-未通过") //@Excel(name = "审核状态: 0-待审核 1-已审核 2-未通过")
private Integer isverify; private Integer isverify;
/** 发布者 */ /** 发布者 */
@ -50,51 +50,51 @@ public class DcPublishManage extends BaseEntity
private String publisher; private String publisher;
/** 审核者1 */ /** 审核者1 */
@Excel(name = "审核者1") //@Excel(name = "审核者1")
private String auditor1; private String auditor1;
/** 审核者1 */ /** 审核者1 */
@Excel(name = "审核者1") //@Excel(name = "审核者1")
private String auditor2; private String auditor2;
/** 审核时间1 */ /** 审核时间1 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@Excel(name = "审核时间1", width = 30, dateFormat = "yyyy-MM-dd") //@Excel(name = "审核时间1", width = 30, dateFormat = "yyyy-MM-dd")
private Date auditTime1; private Date auditTime1;
/** 审核时间1 */ /** 审核时间1 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@Excel(name = "审核时间1", width = 30, dateFormat = "yyyy-MM-dd") //@Excel(name = "审核时间1", width = 30, dateFormat = "yyyy-MM-dd")
private Date auditTime2; private Date auditTime2;
/** 审核者1意见 */ /** 审核者1意见 */
@Excel(name = "审核者1意见") //@Excel(name = "审核者1意见")
private String auditComment1; private String auditComment1;
/** 审核者2意见 */ /** 审核者2意见 */
@Excel(name = "审核者2意见") //@Excel(name = "审核者2意见")
private String auditComment2; private String auditComment2;
/** 发布时间 */ /** 发布时间 */
@Excel(name = "发布时间", width = 30, dateFormat = "yyyy-MM-dd") @Excel(name = "发布时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
private Date publishTime; private Date publishTime;
/** 发布状态:1-成功2-失败3-草稿 */ /** 发布状态:1-成功2-失败3-草稿 */
@Excel(name = "发布状态: 1-成功 2-失败 3-草稿") @Excel(name = "发布状态",readConverterExp="1=成功,2=失败,3=草稿")
private Integer publishStatus; private Integer publishStatus;
/** 事件详情 */ /** 事件详情 */
@Excel(name = "事件详情") @Excel(name = "内容")
private String contentDetails; private String contentDetails;
@Excel(name = "方向", readConverterExp = "1=菏泽方向,3=济南方向") //@Excel(name = "方向", readConverterExp = "1=菏泽方向,3=济南方向")
private String direction; private String direction;
@Excel(name = "桩号") //@Excel(name = "桩号")
private String stakeMark; private String stakeMark;
@Excel(name = "事件主类",readConverterExp = "1=交通事故,2=车辆故障,3=交通管制,4=交通拥堵,5=非法上路,6=路障清除,7=施工建设,8=服务区异常,9=设施设备隐患,10=异常天气,11=其他事件") //@Excel(name = "事件主类",readConverterExp = "1=交通事故,2=车辆故障,3=交通管制,4=交通拥堵,5=非法上路,6=路障清除,7=施工建设,8=服务区异常,9=设施设备隐患,10=异常天气,11=其他事件")
private String eventType; private String eventType;
@Excel(name = "事件子类", readConverterExp = "1-1=追尾,1-2=侧翻,1-3=撞护栏,1-4=自然,1-5=其他事故,2-1=车辆故障,3-1=主线封闭和限行,3-2=收费站封闭和限行,3-3=立交封闭和限行,3-4=服务区封闭和限行,4-1=道路拥堵,4-2=立交拥堵,4-3=收费站拥堵,4-4=服务区拥堵,5-1=行人,5-2=非机动车,5-3=摩托车,5-4=其他,6-1=烟雾,6-2=倒伏树木,6-3=撒落物,6-4=动物,6-5=其他,7-1=道路养护施工,7-2=收费站养护施工,7-3=服务区养护施工,7-4=枢纽立交匝道养护施工,7-5=地方道路养护施工,7-6=道路工程建设施工,7-7=收费站工程建设施工,7-8=服务区工程建设施工,7-9=枢纽立交匝道工程建设施工,7-10=地方道路工程建设施工,8-1=封闭、暂停营业,8-2=重要设施停用,8-3=服务区其他异常,9-1=摄像机,9-2=护栏,9-3=隔离栅") //@Excel(name = "事件子类", readConverterExp = "1-1=追尾,1-2=侧翻,1-3=撞护栏,1-4=自然,1-5=其他事故,2-1=车辆故障,3-1=主线封闭和限行,3-2=收费站封闭和限行,3-3=立交封闭和限行,3-4=服务区封闭和限行,4-1=道路拥堵,4-2=立交拥堵,4-3=收费站拥堵,4-4=服务区拥堵,5-1=行人,5-2=非机动车,5-3=摩托车,5-4=其他,6-1=烟雾,6-2=倒伏树木,6-3=撒落物,6-4=动物,6-5=其他,7-1=道路养护施工,7-2=收费站养护施工,7-3=服务区养护施工,7-4=枢纽立交匝道养护施工,7-5=地方道路养护施工,7-6=道路工程建设施工,7-7=收费站工程建设施工,7-8=服务区工程建设施工,7-9=枢纽立交匝道工程建设施工,7-10=地方道路工程建设施工,8-1=封闭、暂停营业,8-2=重要设施停用,8-3=服务区其他异常,9-1=摄像机,9-2=护栏,9-3=隔离栅")
private String eventSubclass; private String eventSubclass;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@ -120,7 +120,9 @@ public class DcPublishManage extends BaseEntity
private Integer eventState; private Integer eventState;
//关联情报板id //关联情报板id
private Long logId; private Long logId;
//位置
@Excel(name = "位置/设备")
private String position;
public Long getLogId() { public Long getLogId() {
return logId; return logId;
@ -241,151 +243,151 @@ public class DcPublishManage extends BaseEntity
this.id = id; this.id = id;
} }
public Long getId() public Long getId()
{ {
return id; return id;
} }
public void setEventId(String eventId) public void setEventId(String eventId)
{ {
this.eventId = eventId; this.eventId = eventId;
} }
public String getEventId() public String getEventId()
{ {
return eventId; return eventId;
} }
public void setDeptId(Long deptId) public void setDeptId(Long deptId)
{ {
this.deptId = deptId; this.deptId = deptId;
} }
public Long getDeptId() public Long getDeptId()
{ {
return deptId; return deptId;
} }
public void setPublishChannelsId(Long publishChannelsId) public void setPublishChannelsId(Long publishChannelsId)
{ {
this.publishChannelsId = publishChannelsId; this.publishChannelsId = publishChannelsId;
} }
public Long getPublishChannelsId() public Long getPublishChannelsId()
{ {
return publishChannelsId; return publishChannelsId;
} }
public void setTitle(String title) public void setTitle(String title)
{ {
this.title = title; this.title = title;
} }
public String getTitle() public String getTitle()
{ {
return title; return title;
} }
public void setPublishChannels(Integer publishChannels) public void setPublishChannels(Integer publishChannels)
{ {
this.publishChannels = publishChannels; this.publishChannels = publishChannels;
} }
public Integer getPublishChannels() public Integer getPublishChannels()
{ {
return publishChannels; return publishChannels;
} }
public void setIsverify(Integer isverify) public void setIsverify(Integer isverify)
{ {
this.isverify = isverify; this.isverify = isverify;
} }
public Integer getIsverify() public Integer getIsverify()
{ {
return isverify; return isverify;
} }
public void setPublisher(String publisher) public void setPublisher(String publisher)
{ {
this.publisher = publisher; this.publisher = publisher;
} }
public String getPublisher() public String getPublisher()
{ {
return publisher; return publisher;
} }
public void setAuditor1(String auditor1) public void setAuditor1(String auditor1)
{ {
this.auditor1 = auditor1; this.auditor1 = auditor1;
} }
public String getAuditor1() public String getAuditor1()
{ {
return auditor1; return auditor1;
} }
public void setAuditor2(String auditor2) public void setAuditor2(String auditor2)
{ {
this.auditor2 = auditor2; this.auditor2 = auditor2;
} }
public String getAuditor2() public String getAuditor2()
{ {
return auditor2; return auditor2;
} }
public void setAuditTime1(Date auditTime1) public void setAuditTime1(Date auditTime1)
{ {
this.auditTime1 = auditTime1; this.auditTime1 = auditTime1;
} }
public Date getAuditTime1() public Date getAuditTime1()
{ {
return auditTime1; return auditTime1;
} }
public void setAuditTime2(Date auditTime2) public void setAuditTime2(Date auditTime2)
{ {
this.auditTime2 = auditTime2; this.auditTime2 = auditTime2;
} }
public Date getAuditTime2() public Date getAuditTime2()
{ {
return auditTime2; return auditTime2;
} }
public void setAuditComment1(String auditComment1) public void setAuditComment1(String auditComment1)
{ {
this.auditComment1 = auditComment1; this.auditComment1 = auditComment1;
} }
public String getAuditComment1() public String getAuditComment1()
{ {
return auditComment1; return auditComment1;
} }
public void setAuditComment2(String auditComment2) public void setAuditComment2(String auditComment2)
{ {
this.auditComment2 = auditComment2; this.auditComment2 = auditComment2;
} }
public String getAuditComment2() public String getAuditComment2()
{ {
return auditComment2; return auditComment2;
} }
public void setPublishTime(Date publishTime) public void setPublishTime(Date publishTime)
{ {
this.publishTime = publishTime; this.publishTime = publishTime;
} }
public Date getPublishTime() public Date getPublishTime()
{ {
return publishTime; return publishTime;
} }
public void setPublishStatus(Integer publishStatus) public void setPublishStatus(Integer publishStatus)
{ {
this.publishStatus = publishStatus; this.publishStatus = publishStatus;
} }
public Integer getPublishStatus() public Integer getPublishStatus()
{ {
return publishStatus; return publishStatus;
} }
public void setContentDetails(String contentDetails) public void setContentDetails(String contentDetails)
{ {
this.contentDetails = contentDetails; this.contentDetails = contentDetails;
} }
public String getContentDetails() public String getContentDetails()
{ {
return contentDetails; return contentDetails;
} }

25
zc-business/src/main/java/com/zc/business/domain/DcWarning.java

@ -59,6 +59,14 @@ public class DcWarning extends BaseEntity
@Excel(name = "事件子类", readConverterExp ="1-1-拥堵,1-2=缓行,2-1=普通行人,2-2=工作人员,3-1=摩托车,3-2=自行车,3-3=三轮车,4-1=非工程车,4-2=工程车,4-3=主路有车,4-4=匝道有车,4-5=车辆故障(弃用),4-6=交通事故(弃用),4-7=应急车道被占用,4-8=车离开应急车道,4-9=其他,4-10=未知车辆,5-1=倒车/逆行,5-2=压线,5-3=掉头,5-4=超速,5-5=低速,5-6=违规变道,5-7=未保持安全距离,6-1=烟火,6-2=火灾,6-3=障碍物,6-4=抛洒物,7-1=道路施工,8-1=雨,8-2=冰雹,8-3=风,8-4=雾,8-5=高温,8-6=积水,8-7=路面湿滑,8-8=路面结冰,8-9=道路能见度低,8-10=道路团雾,9-1=只碰撞不倾斜,9-2=只倾斜无碰撞,9-3=碰撞后倾斜,10-1=未知,10-2单车事故,10-3=多车事故,11-1=车辆抛锚,11-2=车辆炸胎(有备胎),11-2=车辆炸胎(无备胎),99-1=其它") @Excel(name = "事件子类", readConverterExp ="1-1-拥堵,1-2=缓行,2-1=普通行人,2-2=工作人员,3-1=摩托车,3-2=自行车,3-3=三轮车,4-1=非工程车,4-2=工程车,4-3=主路有车,4-4=匝道有车,4-5=车辆故障(弃用),4-6=交通事故(弃用),4-7=应急车道被占用,4-8=车离开应急车道,4-9=其他,4-10=未知车辆,5-1=倒车/逆行,5-2=压线,5-3=掉头,5-4=超速,5-5=低速,5-6=违规变道,5-7=未保持安全距离,6-1=烟火,6-2=火灾,6-3=障碍物,6-4=抛洒物,7-1=道路施工,8-1=雨,8-2=冰雹,8-3=风,8-4=雾,8-5=高温,8-6=积水,8-7=路面湿滑,8-8=路面结冰,8-9=道路能见度低,8-10=道路团雾,9-1=只碰撞不倾斜,9-2=只倾斜无碰撞,9-3=碰撞后倾斜,10-1=未知,10-2单车事故,10-3=多车事故,11-1=车辆抛锚,11-2=车辆炸胎(有备胎),11-2=车辆炸胎(无备胎),99-1=其它")
private String warningSubclass; private String warningSubclass;
/** 事件解除原因 */
@Excel(name = "事件解除原因")
private String relieveReason;
/** 事件解除类型: 1-误报解除2-事件已结束3-无需处理事件4-其它 */
@Excel(name = "信息来源", readConverterExp = "1=误报解除2,2=事件已结束3,3=无需处理事件,4=其它")
private Integer relieveType;
/** 事件标题 */ /** 事件标题 */
@Excel(name = "事件标题") @Excel(name = "事件标题")
private String warningTitle; private String warningTitle;
@ -113,6 +121,23 @@ public class DcWarning extends BaseEntity
private String endDate; private String endDate;
//收费站 //收费站
private String facilityName; private String facilityName;
public String getRelieveReason() {
return relieveReason;
}
public void setRelieveReason(String relieveReason) {
this.relieveReason = relieveReason;
}
public Integer getRelieveType() {
return relieveType;
}
public void setRelieveType(Integer relieveType) {
this.relieveType = relieveType;
}
public String getStartStakeMark() { public String getStartStakeMark() {
return startStakeMark; return startStakeMark;
} }

2
zc-business/src/main/java/com/zc/business/mapper/DcPublishManageMapper.java

@ -84,4 +84,6 @@ public interface DcPublishManageMapper
public List<HashMap<String,Object>> eventTypePublishManageSum(); public List<HashMap<String,Object>> eventTypePublishManageSum();
//统计不同事件的发布渠道数量(月统计) //统计不同事件的发布渠道数量(月统计)
public List<HashMap<String,Object>> eventTypePublishManageMonth(DcPublishManage dcPublishManage); public List<HashMap<String,Object>> eventTypePublishManageMonth(DcPublishManage dcPublishManage);
//公众服务统计查询
public List<DcPublishManage> selectDcPublishManageStatistics(DcPublishManage dcPublishManage);
} }

3
zc-business/src/main/java/com/zc/business/mapper/DcWarningMapper.java

@ -130,5 +130,6 @@ public interface DcWarningMapper
public Integer deleteDispatchResource(@Param("dispatchId")Long dispatchId); public Integer deleteDispatchResource(@Param("dispatchId")Long dispatchId);
DcDispatch selectDcDispatchById(@Param("id") Long id); DcDispatch selectDcDispatchById(@Param("id") Long id);
//误报解除
public Integer falseAlarmResolution(DcWarning dcWarning);
} }

2
zc-business/src/main/java/com/zc/business/service/IDcPublishManageService.java

@ -72,4 +72,6 @@ public interface IDcPublishManageService
public List<HashMap<String,Object>> eventTypePublishManageSum(); public List<HashMap<String,Object>> eventTypePublishManageSum();
//统计不同事件的发布渠道数量(月统计) //统计不同事件的发布渠道数量(月统计)
public List<HashMap<String,Object>> eventTypePublishManageMonth(DcPublishManage dcPublishManage); public List<HashMap<String,Object>> eventTypePublishManageMonth(DcPublishManage dcPublishManage);
//公众服务统计查询
public List<DcPublishManage> selectDcPublishManageStatistics(DcPublishManage dcPublishManage);
} }

2
zc-business/src/main/java/com/zc/business/service/IDcWarningService.java

@ -92,4 +92,6 @@ public interface IDcWarningService
public Integer insertDispatch(DcDispatch dcDispatch); public Integer insertDispatch(DcDispatch dcDispatch);
//新增指挥调度资源记录 //新增指挥调度资源记录
public Integer insertDispatchSource(HashMap map); public Integer insertDispatchSource(HashMap map);
//误报解除
public Integer falseAlarmResolution(DcWarning dcWarning);
} }

5
zc-business/src/main/java/com/zc/business/service/impl/DcPublishManageServiceImpl.java

@ -140,4 +140,9 @@ public class DcPublishManageServiceImpl implements IDcPublishManageService
public List<HashMap<String, Object>> eventTypePublishManageMonth(DcPublishManage dcPublishManage) { public List<HashMap<String, Object>> eventTypePublishManageMonth(DcPublishManage dcPublishManage) {
return dcPublishManageMapper.eventTypePublishManageMonth(dcPublishManage); return dcPublishManageMapper.eventTypePublishManageMonth(dcPublishManage);
} }
//公众服务统计查询
@Override
public List<DcPublishManage> selectDcPublishManageStatistics(DcPublishManage dcPublishManage) {
return dcPublishManageMapper.selectDcPublishManageStatistics(dcPublishManage);
}
} }

6
zc-business/src/main/java/com/zc/business/service/impl/DcWarningServiceImpl.java

@ -764,5 +764,11 @@ public class DcWarningServiceImpl implements IDcWarningService
dcEventProcessService.insertDcEventProcess(dcEventProcess); dcEventProcessService.insertDcEventProcess(dcEventProcess);
return 1; return 1;
} }
//误报解除
@Override
public Integer falseAlarmResolution(DcWarning dcWarning) {
dcWarning.setUpdateTime(DateUtils.getNowDate());
return dcWarningMapper.falseAlarmResolution(dcWarning);
}
} }

53
zc-business/src/main/resources/mapper/business/DcPublishManageMapper.xml

@ -3,7 +3,7 @@
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.zc.business.mapper.DcPublishManageMapper"> <mapper namespace="com.zc.business.mapper.DcPublishManageMapper">
<resultMap type="DcPublishManage" id="DcPublishManageResult"> <resultMap type="DcPublishManage" id="DcPublishManageResult">
<result property="id" column="id" /> <result property="id" column="id" />
<result property="eventId" column="event_id" /> <result property="eventId" column="event_id" />
@ -45,7 +45,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
from dc_publish_manage as manage from dc_publish_manage as manage
LEFT JOIN dc_event as event on event.id=manage.event_id LEFT JOIN dc_event as event on event.id=manage.event_id
LEFT JOIN dc_event_traffic_control as traffic on event.id=traffic.id LEFT JOIN dc_event_traffic_control as traffic on event.id=traffic.id
LEFT JOIN dc_facility as facility ON traffic.facility_id=facility.id
</sql> </sql>
<select id="selectEventDcPublishManageList" resultType="com.zc.business.domain.DcPublishManage"> <select id="selectEventDcPublishManageList" resultType="com.zc.business.domain.DcPublishManage">
select facility.facility_name,event.event_state,manage.publish_time, manage.create_time, select facility.facility_name,event.event_state,manage.publish_time, manage.create_time,
@ -65,7 +64,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
manage.event_id is not null manage.event_id is not null
<if test="eventState != null"> and event.event_state = #{eventState}</if> <if test="eventState != null"> and event.event_state = #{eventState}</if>
<if test="eventType != null and eventType != ''"> and event.event_type = #{eventType}</if> <if test="eventType != null and eventType != ''"> and event.event_type = #{eventType}</if>
<if test="publishStatus != null and publishStatus != '' "> and manage.publish_status = #{publishStatus}</if> <if test="publishStatus != null "> and manage.publish_status = #{publishStatus}</if>
<if test="startTime != null and endTime != null "> <if test="startTime != null and endTime != null ">
and manage.create_time between #{startTime} and #{endTime} and manage.create_time between #{startTime} and #{endTime}
</if> </if>
@ -81,7 +80,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
GROUP BY manage.event_id GROUP BY manage.event_id
ORDER BY event.create_time desc ORDER BY event.create_time desc
</select> </select>
<select id="selectDcPublishManageById" parameterType="Long" resultMap="DcPublishManageResult"> <select id="selectDcPublishManageById" parameterType="Long" resultMap="DcPublishManageResult">
<include refid="selectDcPublishManageVo"/> <include refid="selectDcPublishManageVo"/>
where id = #{id} where id = #{id}
@ -189,7 +188,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
delete from dc_publish_manage where event_id = #{eventId} delete from dc_publish_manage where event_id = #{eventId}
</delete> </delete>
<delete id="deleteDcPublishManageByIds" parameterType="String"> <delete id="deleteDcPublishManageByIds" parameterType="String">
delete from dc_publish_manage where id in delete from dc_publish_manage where id in
<foreach item="id" collection="array" open="(" separator="," close=")"> <foreach item="id" collection="array" open="(" separator="," close=")">
#{id} #{id}
</foreach> </foreach>
@ -222,11 +221,24 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
ORDER BY p.publish_channels; ORDER BY p.publish_channels;
</select> </select>
<select id="eventTypePublishManage" resultType="java.util.HashMap"> <select id="eventTypePublishManage" resultType="java.util.HashMap">
SELECT event.event_type AS eventType, COUNT(manage.event_id) AS number SELECT h.eventType,
FROM dc_event AS event COALESCE(m.number, 0) AS number
LEFT JOIN dc_publish_manage AS manage ON event.id = manage.event_id AND DATE(manage.publish_time) = CURDATE() FROM (
GROUP BY event.event_type SELECT 1 AS eventType
ORDER BY event.event_type; UNION ALL
SELECT 2 UNION ALL SELECT 3 UNION ALL SELECT 4 UNION ALL
SELECT 5 UNION ALL SELECT 6 UNION ALL SELECT 7 UNION ALL
SELECT 8 UNION ALL SELECT 9 UNION ALL SELECT 10 UNION ALL
SELECT 11
) AS h
LEFT JOIN (
SELECT publish_channels ,dc_event.event_type eventType, COUNT(*)AS number
FROM dc_publish_manage
LEFT JOIN dc_event on dc_publish_manage.event_id=dc_event.id
where event_id is not NULL
GROUP BY eventType
) AS m ON h.eventType = m.eventType
ORDER BY h.eventType
</select> </select>
<select id="releaseTrendsPublishManage" resultType="java.util.HashMap"> <select id="releaseTrendsPublishManage" resultType="java.util.HashMap">
SELECT h.hour, SELECT h.hour,
@ -260,7 +272,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
ORDER BY h.hour, pc.publish_channels; ORDER BY h.hour, pc.publish_channels;
</select> </select>
<select id="monthTrendsPublishManage" resultType="java.util.HashMap"> <select id="monthTrendsPublishManage" resultType="java.util.HashMap">
SELECT h.hour, pc.publish_channels, COALESCE(m.number, 0) AS number SELECT h.hour, pc.publish_channels publishChannels, COALESCE(m.number, 0) AS number
FROM ( FROM (
SELECT 0 AS hour UNION ALL SELECT 1 UNION ALL SELECT 2 UNION ALL SELECT 0 AS hour UNION ALL SELECT 1 UNION ALL SELECT 2 UNION ALL
SELECT 3 UNION ALL SELECT 4 UNION ALL SELECT 5 UNION ALL SELECT 6 UNION ALL SELECT 3 UNION ALL SELECT 4 UNION ALL SELECT 5 UNION ALL SELECT 6 UNION ALL
@ -307,7 +319,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
SELECT publish_channels ,dc_event.event_type eventType, COUNT(*)AS number SELECT publish_channels ,dc_event.event_type eventType, COUNT(*)AS number
FROM dc_publish_manage FROM dc_publish_manage
LEFT JOIN dc_event on dc_publish_manage.event_id=dc_event.id LEFT JOIN dc_event on dc_publish_manage.event_id=dc_event.id
GROUP BY HOUR(publish_time), publish_channels GROUP BY dc_event.event_type
) AS m ON h.eventType = m.eventType AND pc.publish_channels = m.publish_channels ) AS m ON h.eventType = m.eventType AND pc.publish_channels = m.publish_channels
ORDER BY h.eventType, pc.publish_channels; ORDER BY h.eventType, pc.publish_channels;
</select> </select>
@ -340,4 +352,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
) AS m ON h.eventType = m.eventType AND pc.publish_channels = m.publish_channels ) AS m ON h.eventType = m.eventType AND pc.publish_channels = m.publish_channels
ORDER BY h.eventType, pc.publish_channels; ORDER BY h.eventType, pc.publish_channels;
</select> </select>
</mapper> <select id="selectDcPublishManageStatistics" resultType="com.zc.business.domain.DcPublishManage">
select manage.id,IFNULL(event.stake_mark,log.dc_device_name)position,
manage.publisher,manage.publish_channels,manage.publish_status,manage.content_details,publish_time
from dc_publish_manage as manage
left join dc_event as event on event.id=manage.event_id
left join dc_oper_log as log on log.id=manage.log_id
<where>
<if test="publishChannels != null "> and manage.publish_channels = #{publishChannels}</if>
<if test="publishStatus != null "> and manage.publish_status = #{publishStatus}</if>
<if test="startTime != null and endTime != null ">
and manage.publish_time between #{startTime} and #{endTime}
</if>
</where>
ORDER BY publish_time desc
</select>
</mapper>

2
zc-business/src/main/resources/mapper/business/DcPublishingChannelsMapper.xml

@ -103,7 +103,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
select id from dc_publishing_channels where data_category=#{dataCategory} select id from dc_publishing_channels where data_category=#{dataCategory}
</select> </select>
<select id="eventPublishChannels" resultType="com.zc.business.domain.DcPublishingChannels"> <select id="eventPublishChannels" resultType="com.zc.business.domain.DcPublishingChannels">
select publish_channels publishChannels from dc_publishing_channels where data_category=#{dataCategory} select publish_channels publishChannels from dc_publishing_channels where data_category=#{dataCategory} and enabled=2
</select> </select>
<select id="eventType" resultType="java.lang.String"> <select id="eventType" resultType="java.lang.String">
select event_type from dc_event where id=#{id} select event_type from dc_event where id=#{id}

14
zc-business/src/main/resources/mapper/business/DcWarningMapper.xml

@ -23,6 +23,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="otherConfig" column="other_config" /> <result property="otherConfig" column="other_config" />
<result property="lane" column="lane" /> <result property="lane" column="lane" />
<result property="vehicleType" column="vehicle_type" /> <result property="vehicleType" column="vehicle_type" />
<result property="relieveReason" column="relieve_reason" />
<result property="relieveType" column="relieve_type" />
</resultMap> </resultMap>
<resultMap type="map" id="eventMap"> <resultMap type="map" id="eventMap">
<result property="targetId" column="targetId" /> <result property="targetId" column="targetId" />
@ -236,6 +238,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<update id="updateDcDispatch"> <update id="updateDcDispatch">
update dc_dispatch set organization_id=#{organization_id} where id=#{id} update dc_dispatch set organization_id=#{organization_id} where id=#{id}
</update> </update>
<update id="falseAlarmResolution">
update dc_warning
<trim prefix="SET" suffixOverrides=",">
<if test="relieveReason != null and relieveReason != ''">relieve_reason = #{relieveReason},</if>
<if test="relieveType != null">relieve_type = #{relieveType},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
warning_state=3
</trim>
where id = #{id}
</update>
<delete id="deleteDcWarningById" parameterType="Integer"> <delete id="deleteDcWarningById" parameterType="Integer">
delete from dc_warning where id = #{id} delete from dc_warning where id = #{id}
</delete> </delete>
@ -295,6 +307,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select> </select>
<select id="selectRecentlySection" resultType="hashmap"> <select id="selectRecentlySection" resultType="hashmap">
select id,organization_name organizationName,stake_mark stakeMark from dc_organization select id,organization_name organizationName,stake_mark stakeMark from dc_organization
where parent_id!=0
</select> </select>
<select id="selectOrganizationEmployees" resultType="java.util.HashMap"> <select id="selectOrganizationEmployees" resultType="java.util.HashMap">
select id, name,contact_number contactNumber from dc_employees where organization_id=#{organizationId} and employees_type=2 select id, name,contact_number contactNumber from dc_employees where organization_id=#{organizationId} and employees_type=2
@ -364,7 +377,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and respurce.dispatch_type = 1 and respurce.dispatch_type = 1
and path.event_id = #{eventId}) as t on t.id = dc_employees.id and path.event_id = #{eventId}) as t on t.id = dc_employees.id
where organization_id = #{organizationId} where organization_id = #{organizationId}
and employees_type = 2
</select> </select>
<select id="selectVehiclesDispatch" resultType="java.util.HashMap"> <select id="selectVehiclesDispatch" resultType="java.util.HashMap">
select DISTINCT dc_vehicles.id, select DISTINCT dc_vehicles.id,

Loading…
Cancel
Save