Browse Source

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

develop
zhao-meiyu 10 months ago
parent
commit
9c01b333cd
  1. 3
      zc-business/src/main/java/com/zc/business/domain/DcEvent.java
  2. 10
      zc-business/src/main/java/com/zc/business/domain/DcEventAccident.java
  3. 2
      zc-business/src/main/java/com/zc/business/domain/DcEventTrafficControl.java
  4. 3
      zc-business/src/main/java/com/zc/business/service/impl/DcEventServiceImpl.java
  5. 7
      zc-business/src/main/resources/mapper/business/DcEventAccidentMapper.xml
  6. 9
      zc-business/src/main/resources/mapper/business/DcEventMapper.xml
  7. 6
      zc-business/src/main/resources/mapper/business/DcEventTrafficControlMapper.xml

3
zc-business/src/main/java/com/zc/business/domain/DcEvent.java

@ -185,6 +185,9 @@ public class DcEvent extends BaseEntity {
*/ */
@ApiModelProperty("是否处在隧道 0 表示 false,1 表示 true") @ApiModelProperty("是否处在隧道 0 表示 false,1 表示 true")
private Integer inTunnel; private Integer inTunnel;
@ApiModelProperty("高速公路")
private Long roadId;
@ApiModelProperty("事件详情参数") @ApiModelProperty("事件详情参数")
@TableField(exist = false) @TableField(exist = false)
private DcEventMap dcEventMap; private DcEventMap dcEventMap;

10
zc-business/src/main/java/com/zc/business/domain/DcEventAccident.java

@ -109,14 +109,14 @@ public class DcEventAccident extends BaseEntity {
*/ */
@ApiModelProperty("交警电话") @ApiModelProperty("交警电话")
private Integer policeContact; private String policeContact;
/** /**
* 清障电话 * 清障电话
*/ */
@ApiModelProperty("清障电话") @ApiModelProperty("清障电话")
private Integer towingServiceContact; private String towingServiceContact;
/** /**
* 前方是否拥堵 * 前方是否拥堵
@ -210,12 +210,12 @@ public class DcEventAccident extends BaseEntity {
@ApiModelProperty("私密事件") @ApiModelProperty("私密事件")
private Integer isPrivate; private Integer isPrivate;
/** /* *//**
* 高速公路 * 高速公路
*/ *//*
@ApiModelProperty("高速公路") @ApiModelProperty("高速公路")
private Integer roadId; private Integer roadId;*/
/** /**
* 设施关联 * 设施关联
*/ */

2
zc-business/src/main/java/com/zc/business/domain/DcEventTrafficControl.java

@ -67,8 +67,10 @@ public class DcEventTrafficControl extends BaseEntity
@ApiModelProperty("匝道(立交)") @ApiModelProperty("匝道(立交)")
@Excel(name = "匝道", readConverterExp = "立=交") @Excel(name = "匝道", readConverterExp = "立=交")
private Long rampId; private Long rampId;
/*
@ApiModelProperty("高速公路 id") @ApiModelProperty("高速公路 id")
private Long roadId; private Long roadId;
*/
@ApiModelProperty("原因类型") @ApiModelProperty("原因类型")
private String causeType; private String causeType;

3
zc-business/src/main/java/com/zc/business/service/impl/DcEventServiceImpl.java

@ -2,6 +2,7 @@ package com.zc.business.service.impl;
import java.util.List; import java.util.List;
import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.SecurityUtils;
import com.ruoyi.common.utils.uuid.IdUtils; import com.ruoyi.common.utils.uuid.IdUtils;
import com.zc.business.domain.*; import com.zc.business.domain.*;
import com.zc.business.mapper.*; import com.zc.business.mapper.*;
@ -94,6 +95,8 @@ private DcEventAbnormalWeatherMapper dcEventAbnormalWeatherMapper;
//设置事件Id UUID无下划线格式32 //设置事件Id UUID无下划线格式32
String uuid = IdUtils.fastSimpleUUID(); String uuid = IdUtils.fastSimpleUUID();
dcEvent.setId(uuid); dcEvent.setId(uuid);
//获取部门信息
dcEvent.setDeptId(SecurityUtils.getDeptId());
dcEvent.setCreateTime(DateUtils.getNowDate()); dcEvent.setCreateTime(DateUtils.getNowDate());
int i7 = dcEventMapper.insertDcEvent(dcEvent); int i7 = dcEventMapper.insertDcEvent(dcEvent);
if (i7>0){ if (i7>0){

7
zc-business/src/main/resources/mapper/business/DcEventAccidentMapper.xml

@ -31,11 +31,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="fatalities" column="fatalities" /> <result property="fatalities" column="fatalities" />
<result property="isPrivate" column="is_private" /> <result property="isPrivate" column="is_private" />
<result property="facilityId" column="facility_id" /> <result property="facilityId" column="facility_id" />
<result property="roadId" column="road_id" />
</resultMap> </resultMap>
<sql id="selectDcEventAccidentVo"> <sql id="selectDcEventAccidentVo">
select id, reporter_name, reporter_phone_number, accident_type, location_type, traffic_jam, weather_condition, impact_level, is_reverse_cargo, is_maintenance, police_contact, towing_service_contact, congestion_ahead, at_intersection, on_curve, spillage_item, vehicle_owner_phone, lane_occupancy, small_car, trucks, buses, tankers, minor_injuries, serious_injuries, fatalities, is_private, facility_id, road_id from dc_event_accident select id, reporter_name, reporter_phone_number, accident_type, location_type, traffic_jam, weather_condition, impact_level, is_reverse_cargo, is_maintenance, police_contact, towing_service_contact, congestion_ahead, at_intersection, on_curve, spillage_item, vehicle_owner_phone, lane_occupancy, small_car, trucks, buses, tankers, minor_injuries, serious_injuries, fatalities, is_private, facility_id from dc_event_accident
</sql> </sql>
<select id="selectDcEventAccidentList" parameterType="DcEventAccident" resultMap="DcEventAccidentResult"> <select id="selectDcEventAccidentList" parameterType="DcEventAccident" resultMap="DcEventAccidentResult">
@ -67,7 +66,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fatalities != null "> and fatalities = #{fatalities}</if> <if test="fatalities != null "> and fatalities = #{fatalities}</if>
<if test="isPrivate != null "> and is_private = #{isPrivate}</if> <if test="isPrivate != null "> and is_private = #{isPrivate}</if>
<if test="facilityId != null "> and facility_id = #{facilityId}</if> <if test="facilityId != null "> and facility_id = #{facilityId}</if>
<if test="roadId != null "> and road_id = #{roadId}</if>
</where> </where>
</select> </select>
@ -106,7 +104,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fatalities != null">fatalities,</if> <if test="fatalities != null">fatalities,</if>
<if test="isPrivate != null">is_private,</if> <if test="isPrivate != null">is_private,</if>
<if test="facilityId != null">facility_id,</if> <if test="facilityId != null">facility_id,</if>
<if test="roadId != null">road_id,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if> <if test="id != null">#{id},</if>
@ -136,7 +133,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fatalities != null">#{fatalities},</if> <if test="fatalities != null">#{fatalities},</if>
<if test="isPrivate != null">#{isPrivate},</if> <if test="isPrivate != null">#{isPrivate},</if>
<if test="facilityId != null">#{facilityId},</if> <if test="facilityId != null">#{facilityId},</if>
<if test="roadId != null">#{roadId},</if>
</trim> </trim>
</insert> </insert>
@ -169,7 +165,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="fatalities != null">fatalities = #{fatalities},</if> <if test="fatalities != null">fatalities = #{fatalities},</if>
<if test="isPrivate != null">is_private = #{isPrivate},</if> <if test="isPrivate != null">is_private = #{isPrivate},</if>
<if test="facilityId != null">facility_id = #{facilityId},</if> <if test="facilityId != null">facility_id = #{facilityId},</if>
<if test="roadId != null">road_id = #{roadId},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>

9
zc-business/src/main/resources/mapper/business/DcEventMapper.xml

@ -26,6 +26,7 @@
<result property="eventSourceTips" column="event_source_tips" /> <result property="eventSourceTips" column="event_source_tips" />
<result property="stringEventType" column="stringEventType" /> <result property="stringEventType" column="stringEventType" />
<result property="stringEventSource" column="stringEventSource" /> <result property="stringEventSource" column="stringEventSource" />
<result property="roadId" column="road_id" />
</resultMap> </resultMap>
<resultMap type="com.zc.business.domain.DcEvent" id="DcEventResultById"> <resultMap type="com.zc.business.domain.DcEvent" id="DcEventResultById">
<result property="id" column="id" /> <result property="id" column="id" />
@ -51,6 +52,7 @@
<result property="inTunnel" column="in_tunnel" /> <result property="inTunnel" column="in_tunnel" />
<result property="eventName" column="event_name" /> <result property="eventName" column="event_name" />
<result property="nodeNode" column="node_node" /> <result property="nodeNode" column="node_node" />
<result property="roadId" column="road_id" />
<result property="commonPhrases" column="common_phrases" /> <result property="commonPhrases" column="common_phrases" />
<result property="stringEventType" column="stringEventType" /> <result property="stringEventType" column="stringEventType" />
<result property="stringEventSource" column="stringEventSource" /> <result property="stringEventSource" column="stringEventSource" />
@ -212,7 +214,8 @@
create_time, create_time,
update_time, update_time,
event_source_tips, event_source_tips,
in_tunnel in_tunnel,
road_id
FROM FROM
dc_event </sql> dc_event </sql>
<sql id="selectDcEventVoListAll"> select dc_event.id AS id, <sql id="selectDcEventVoListAll"> select dc_event.id AS id,
@ -236,6 +239,7 @@
dc_event.update_time, dc_event.update_time,
dc_event.event_source_tips, dc_event.event_source_tips,
dc_event.in_tunnel, dc_event.in_tunnel,
dc_event.road_id,
dc_event_type.event_name AS event_name, dc_event_type.event_name AS event_name,
dc_process_config.node_node AS node_node, dc_process_config.node_node AS node_node,
@ -441,6 +445,7 @@
<if test="updateTime != null">update_time,</if> <if test="updateTime != null">update_time,</if>
<if test="eventSourceTips != null">event_source_tips,</if> <if test="eventSourceTips != null">event_source_tips,</if>
<if test="inTunnel != null">in_tunnel,</if> <if test="inTunnel != null">in_tunnel,</if>
<if test="roadId != null">road_id,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if> <if test="id != null">#{id},</if>
@ -464,6 +469,7 @@
<if test="updateTime != null">#{updateTime},</if> <if test="updateTime != null">#{updateTime},</if>
<if test="eventSourceTips != null">#{eventSourceTips},</if> <if test="eventSourceTips != null">#{eventSourceTips},</if>
<if test="inTunnel != null">#{inTunnel},</if> <if test="inTunnel != null">#{inTunnel},</if>
<if test="roadId != null">#{roadId},</if>
</trim> </trim>
</insert> </insert>
@ -490,6 +496,7 @@
<if test="updateTime != null">update_time = #{updateTime},</if> <if test="updateTime != null">update_time = #{updateTime},</if>
<if test="eventSourceTips != null">event_source_tips = #{eventSourceTips},</if> <if test="eventSourceTips != null">event_source_tips = #{eventSourceTips},</if>
<if test="inTunnel != null">in_tunnel = #{inTunnel},</if> <if test="inTunnel != null">in_tunnel = #{inTunnel},</if>
<if test="roadId != null">road_id = #{roadId},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>

6
zc-business/src/main/resources/mapper/business/DcEventTrafficControlMapper.xml

@ -11,7 +11,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="exitsInlets" column="exits_inlets" /> <result property="exitsInlets" column="exits_inlets" />
<result property="facilityId" column="facility_id" /> <result property="facilityId" column="facility_id" />
<result property="rampId" column="ramp_id" /> <result property="rampId" column="ramp_id" />
<result property="rampId" column="road_id" />
<result property="causeType" column="cause_type" /> <result property="causeType" column="cause_type" />
<result property="measure" column="measure" /> <result property="measure" column="measure" />
@ -28,7 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap> </resultMap>
<sql id="selectDcEventTrafficControlVo"> <sql id="selectDcEventTrafficControlVo">
select id, control_type, control_cause, exits_inlets, facility_id, ramp_id,road_id,cause_type,measure,classify,limited_type,vehicle_type from dc_event_traffic_control select id, control_type, control_cause, exits_inlets, facility_id, ramp_id,cause_type,measure,classify,limited_type,vehicle_type from dc_event_traffic_control
</sql> </sql>
<!--关联路网设施查询--> <!--关联路网设施查询-->
<sql id="selectDcEventTrafficControlVoById"> <sql id="selectDcEventTrafficControlVoById">
@ -79,7 +78,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="exitsInlets != null">exits_inlets,</if> <if test="exitsInlets != null">exits_inlets,</if>
<if test="facilityId != null">facility_id,</if> <if test="facilityId != null">facility_id,</if>
<if test="rampId != null">ramp_id,</if> <if test="rampId != null">ramp_id,</if>
<if test="roadId != null">road_id,</if>
<if test="causeType != null">cause_type,</if> <if test="causeType != null">cause_type,</if>
<if test="measure != null">measure,</if> <if test="measure != null">measure,</if>
@ -94,7 +92,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="exitsInlets != null">#{exitsInlets},</if> <if test="exitsInlets != null">#{exitsInlets},</if>
<if test="facilityId != null">#{facilityId},</if> <if test="facilityId != null">#{facilityId},</if>
<if test="rampId != null">#{rampId},</if> <if test="rampId != null">#{rampId},</if>
<if test="roadId != null">#{roadId},</if>
<if test="causeType != null">#{causeType},</if> <if test="causeType != null">#{causeType},</if>
<if test="measure != null">#{measure},</if> <if test="measure != null">#{measure},</if>
@ -112,7 +109,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="exitsInlets != null">exits_inlets = #{exitsInlets},</if> <if test="exitsInlets != null">exits_inlets = #{exitsInlets},</if>
<if test="facilityId != null">facility_id = #{facilityId},</if> <if test="facilityId != null">facility_id = #{facilityId},</if>
<if test="rampId != null">ramp_id = #{rampId},</if> <if test="rampId != null">ramp_id = #{rampId},</if>
<if test="roadId != null">road_id = #{roadId},</if>
<if test="causeType != null">cause_type = #{causeType},</if> <if test="causeType != null">cause_type = #{causeType},</if>
<if test="measure != null">measure = #{measure},</if> <if test="measure != null">measure = #{measure},</if>
<if test="classify != null">classify = #{classify},</if> <if test="classify != null">classify = #{classify},</if>

Loading…
Cancel
Save