From 43997e27063382ef234bb40f85293eac39816b18 Mon Sep 17 00:00:00 2001 From: mengff <1198151809@qq.com> Date: Mon, 21 Oct 2024 10:18:38 +0800 Subject: [PATCH] =?UTF-8?q?--=E5=A2=9E=E5=8A=A0=E6=84=9F=E7=9F=A5=E4=BA=8B?= =?UTF-8?q?=E4=BB=B6=E7=BB=9F=E8=AE=A1=E6=9F=A5=E8=AF=A2=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E5=AE=A1=E6=A0=B8=E7=8A=B6=E6=80=81=E5=AD=97=E6=AE=B5=20--?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=AE=A1=E6=A0=B8=E7=8A=B6=E6=80=81=E8=AF=A6?= =?UTF-8?q?=E6=83=85=E5=A2=9E=E5=8A=A0=E5=AE=A1=E6=A0=B8=E4=BA=BA=E3=80=81?= =?UTF-8?q?=E5=AE=A1=E6=A0=B8=E6=97=B6=E9=97=B4=E3=80=81=E5=AE=A1=E6=A0=B8?= =?UTF-8?q?=E7=8A=B6=E6=80=81=E6=98=BE=E7=A4=BA=20--=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E5=AE=A1=E6=A0=B8=E6=8C=89=E9=92=AE=E6=93=8D=E4=BD=9C=20--?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=AE=A1=E6=A0=B8=E4=BA=BA=E3=80=81=E5=AE=A1?= =?UTF-8?q?=E6=A0=B8=E6=97=B6=E9=97=B4=E5=92=8C=E5=AE=A1=E6=A0=B8=E7=8A=B6?= =?UTF-8?q?=E6=80=81=E7=9A=84=E5=AF=BC=E5=87=BA=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DCPerceivedEventsWarningController.java | 8 +++++ .../com/zc/business/domain/DcWarning.java | 34 +++++++++++++++++++ .../DcPerceivedEventsWarningMapper.java | 3 ++ .../IDCPerceivedEventsWarningService.java | 2 ++ .../DcPerceivedEventsWarningServiceImpl.java | 6 ++++ .../DcPerceivedEventsWarningMapper.xml | 13 ++++++- .../mapper/business/DcWarningMapper.xml | 2 ++ 7 files changed, 67 insertions(+), 1 deletion(-) diff --git a/zc-business/src/main/java/com/zc/business/controller/DCPerceivedEventsWarningController.java b/zc-business/src/main/java/com/zc/business/controller/DCPerceivedEventsWarningController.java index b52aa90b..ab17b5bb 100644 --- a/zc-business/src/main/java/com/zc/business/controller/DCPerceivedEventsWarningController.java +++ b/zc-business/src/main/java/com/zc/business/controller/DCPerceivedEventsWarningController.java @@ -227,6 +227,14 @@ public class DCPerceivedEventsWarningController extends BaseController { return toAjax(perceivedEventsWarningService.updateWarning(dcWarning)); } + + //增加感知事件审核状态 + @PostMapping("/updateWarningAuditFlag") + public AjaxResult updateWarningAuditFlag(@RequestBody DcWarning dcWarning){ + dcWarning.setAuditor(getUsername()); + return toAjax(perceivedEventsWarningService.updateWarningAuditFlag(dcWarning)); + } + //查询非机预警类型,按照时间与类型查询(传入时间类型type与时间warningTime) @PostMapping("/nonAutomaticWarningType") public AjaxResult nonAutomaticWarningType(@RequestBody DcWarning dcWarning){ diff --git a/zc-business/src/main/java/com/zc/business/domain/DcWarning.java b/zc-business/src/main/java/com/zc/business/domain/DcWarning.java index f81e7a0a..b1d4661f 100644 --- a/zc-business/src/main/java/com/zc/business/domain/DcWarning.java +++ b/zc-business/src/main/java/com/zc/business/domain/DcWarning.java @@ -76,6 +76,40 @@ public class DcWarning extends BaseEntity @Excel(name = "车道",readConverterExp="0=应急,1=行1,2=行2,3=行3,4=行4") private String lane; + @Excel(name="审核人") + private String auditor; + + public String getAuditor() { + return auditor; + } + + public void setAuditor(String auditor) { + this.auditor = auditor; + } + + public Date getAuditTime() { + return auditTime; + } + + public void setAuditTime(Date auditTime) { + this.auditTime = auditTime; + } + + public Integer getAuditFlag() { + return auditFlag; + } + + public void setAuditFlag(Integer auditFlag) { + this.auditFlag = auditFlag; + } + + @Excel(name="审核时间") + private Date auditTime; + + @Excel(name="审核状态",readConverterExp = "1=正确,2=错误") + private Integer auditFlag; + + /** 所属辖区路段名称 */ private String sectionName; diff --git a/zc-business/src/main/java/com/zc/business/mapper/DcPerceivedEventsWarningMapper.java b/zc-business/src/main/java/com/zc/business/mapper/DcPerceivedEventsWarningMapper.java index dcfd6986..387392a9 100644 --- a/zc-business/src/main/java/com/zc/business/mapper/DcPerceivedEventsWarningMapper.java +++ b/zc-business/src/main/java/com/zc/business/mapper/DcPerceivedEventsWarningMapper.java @@ -72,6 +72,9 @@ public interface DcPerceivedEventsWarningMapper { List> selectWarningEscalation(DcWarning dcWarning); //修改感知事件信息 Integer updateWarning(DcWarning dcWarning); + + //增加感知事件审核状态 + Integer updateWarningAuditFlag(DcWarning dcWarning); //查询事件条数,以桩号和方向,时间作为条件 String selectWarningMarkDay(DcWarning dcWarning); String selectWarningMarkMonth(DcWarning dcWarning); diff --git a/zc-business/src/main/java/com/zc/business/service/IDCPerceivedEventsWarningService.java b/zc-business/src/main/java/com/zc/business/service/IDCPerceivedEventsWarningService.java index ae338ab0..46262912 100644 --- a/zc-business/src/main/java/com/zc/business/service/IDCPerceivedEventsWarningService.java +++ b/zc-business/src/main/java/com/zc/business/service/IDCPerceivedEventsWarningService.java @@ -54,6 +54,8 @@ public interface IDCPerceivedEventsWarningService { //修改感知事件信息 Integer updateWarning(DcWarning dcWarning); + Integer updateWarningAuditFlag(DcWarning dcWarning); + //查询非机预警事件按照类型区分时间查询 List> selectTypeNonAutomaticWarning(DcWarning dcWarning); //查询非机预警按照时间类型查询 diff --git a/zc-business/src/main/java/com/zc/business/service/impl/DcPerceivedEventsWarningServiceImpl.java b/zc-business/src/main/java/com/zc/business/service/impl/DcPerceivedEventsWarningServiceImpl.java index f4bf4bb1..0b69ff3c 100644 --- a/zc-business/src/main/java/com/zc/business/service/impl/DcPerceivedEventsWarningServiceImpl.java +++ b/zc-business/src/main/java/com/zc/business/service/impl/DcPerceivedEventsWarningServiceImpl.java @@ -266,6 +266,12 @@ public class DcPerceivedEventsWarningServiceImpl implements IDCPerceivedEventsWa dcWarning.setUpdateTime(DateUtils.getNowDate()); return perceivedEventsWarningMapper.updateWarning(dcWarning); } + + + public Integer updateWarningAuditFlag(DcWarning dcWarning) { + dcWarning.setAuditTime(DateUtils.getNowDate()); + return perceivedEventsWarningMapper.updateWarningAuditFlag(dcWarning); + } //查询非机预警事件按照类型区分时间查询 @Override public List> selectTypeNonAutomaticWarning(DcWarning dcWarning) { diff --git a/zc-business/src/main/resources/mapper/business/DcPerceivedEventsWarningMapper.xml b/zc-business/src/main/resources/mapper/business/DcPerceivedEventsWarningMapper.xml index e5c2ac2f..30775967 100644 --- a/zc-business/src/main/resources/mapper/business/DcPerceivedEventsWarningMapper.xml +++ b/zc-business/src/main/resources/mapper/business/DcPerceivedEventsWarningMapper.xml @@ -15,7 +15,7 @@ select count(1) from dc_warning where stake_mark=#{stakeMark} AND direction=#{direction} and DATE(warning_time)=DATE_FORMAT(#{warningTime},'%Y-%m-%d') diff --git a/zc-business/src/main/resources/mapper/business/DcWarningMapper.xml b/zc-business/src/main/resources/mapper/business/DcWarningMapper.xml index 58424fad..36a7815f 100644 --- a/zc-business/src/main/resources/mapper/business/DcWarningMapper.xml +++ b/zc-business/src/main/resources/mapper/business/DcWarningMapper.xml @@ -87,6 +87,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" warning.`id`,warning.`stake_mark`, warning.`direction`,warning.end_time,warning.event_cause, warning.lane,warning.vehicle_type,mark.longitude,mark.latitude, warning.`dept_id`,warning.`warning_state`,warning.`warning_time`, + warning.`auditor`,warning.`audit_time`,warning.`audit_flag`, warning.`user_id`, warning.`warning_source`,warning.`warning_level`, warning.`remark`, warning.`create_time`,warning.`update_time`, warning.`warning_type`,warning.`warning_subclass`,warning.`warning_title`, @@ -103,6 +104,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" #{warningSubclass} and warning.direction = #{direction} + and warning.audit_flag = #{auditFlag} and warning.stake_mark = #{stakeMark} and warning.warning_time between #{startTime} and #{completeTime}