支付
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,298 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zhwl.passflow.mapper.ZdyDevicePassflowCountLogMapper">
|
||||
|
||||
<resultMap type="ZdyDevicePassflowCountLog" id="ZdyDevicePassflowCountLogResult">
|
||||
<result property="logId" column="log_id"/>
|
||||
<result property="sn" column="sn"/>
|
||||
<result property="type" column="type"/>
|
||||
<result property="time" column="time"/>
|
||||
<result property="dataTime" column="data_time"/>
|
||||
<result property="createdTime" column="created_time"/>
|
||||
<result property="passflowType" column="passflow_type"/>
|
||||
<result property="longitude" column="longitude"/>
|
||||
<result property="latitude" column="latitude"/>
|
||||
<result property="name" column="name"/>
|
||||
<result property="allIn" column="all_in"/>
|
||||
<result property="allOut" column="all_out"/>
|
||||
<result property="passflowIn" column="passflow_in"/>
|
||||
<result property="passflowOut" column="passflow_out"/>
|
||||
<result property="ip" column="ip"/>
|
||||
<result property="op" column="op"/>
|
||||
<result property="realNum" column="real_num"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="sendInfo" column="send_info"/>
|
||||
<result property="reqInfo" column="req_info"/>
|
||||
<result property="deptId" column="dept_id"/>
|
||||
<result property="passflowName" column="passflow_name"/>
|
||||
<result property="scenicId" column="scenic_id"/>
|
||||
<result property="scenicName" column="scenic_name"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectZdyDevicePassflowCountLogVo">
|
||||
select p.passflow_name,cl.log_id,
|
||||
cl.sn,
|
||||
cl.type, cl.time, cl.data_time,cl.created_time, cl.passflow_type, cl.longitude, cl.latitude, cl.name, cl.all_in, cl.all_out, cl.passflow_in, cl.passflow_out, cl.ip, cl.op, cl.real_num,cl.send_info,cl.req_info, cl.create_by, cl.create_time, cl.update_by, cl.update_time, cl.remark,cl.dept_id,
|
||||
cl.scenic_id,
|
||||
zs.scenic_name
|
||||
from zdy_device_passflow_count_log cl
|
||||
left join zdy_device_passflow p on cl.sn = p.sn
|
||||
left join zdy_scenic zs on zs.id = cl.scenic_id
|
||||
</sql>
|
||||
|
||||
<select id="selectZdyDevicePassflowCountLogList" parameterType="ZdyDevicePassflowCountLog"
|
||||
resultMap="ZdyDevicePassflowCountLogResult">
|
||||
<include refid="selectZdyDevicePassflowCountLogVo"/>
|
||||
left join sys_dept d on cl.dept_id = d.dept_id
|
||||
<where>
|
||||
<if test="sn != null and sn != ''">
|
||||
and cl.sn = #{sn}
|
||||
</if>
|
||||
<if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
|
||||
and cl.data_time between #{params.beginDataTime} and #{params.endDataTime}
|
||||
</if>
|
||||
<if test="passflowName != null and passflowName != ''">
|
||||
and p.passflow_name like concat('%', #{passflowName}, '%')
|
||||
</if>
|
||||
<if test="passflowOut != null">
|
||||
and cl.passflow_out > #{passflowOut}
|
||||
</if>
|
||||
${params.dataScope}
|
||||
</where>
|
||||
order by cl.create_time desc
|
||||
</select>
|
||||
|
||||
<select id="selectZdyDevicePassflowCountLogByLogId" parameterType="Long"
|
||||
resultMap="ZdyDevicePassflowCountLogResult">
|
||||
<include refid="selectZdyDevicePassflowCountLogVo"/>
|
||||
where cl.log_id = #{logId}
|
||||
</select>
|
||||
|
||||
<insert id="insertZdyDevicePassflowCountLog" parameterType="ZdyDevicePassflowCountLog" useGeneratedKeys="true"
|
||||
keyProperty="logId">
|
||||
insert into zdy_device_passflow_count_log
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">sn,
|
||||
</if>
|
||||
<if test="type != null">type,
|
||||
</if>
|
||||
<if test="time != null">time,
|
||||
</if>
|
||||
<if test="dataTime != null">data_time,
|
||||
</if>
|
||||
<if test="createdTime != null">created_time,
|
||||
</if>
|
||||
<if test="passflowType != null">passflow_type,
|
||||
</if>
|
||||
<if test="longitude != null">longitude,
|
||||
</if>
|
||||
<if test="latitude != null">latitude,
|
||||
</if>
|
||||
<if test="name != null">name,
|
||||
</if>
|
||||
<if test="allIn != null">all_in,
|
||||
</if>
|
||||
<if test="allOut != null">all_out,
|
||||
</if>
|
||||
<if test="passflowIn != null">passflow_in,
|
||||
</if>
|
||||
<if test="passflowOut != null">passflow_out,
|
||||
</if>
|
||||
<if test="ip != null">ip,
|
||||
</if>
|
||||
<if test="op != null">op,
|
||||
</if>
|
||||
<if test="realNum != null">real_num,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
</if>
|
||||
<if test="updateBy != null">update_by,
|
||||
</if>
|
||||
<if test="updateTime != null">update_time,
|
||||
</if>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
<if test="sendInfo != null">send_info,
|
||||
</if>
|
||||
<if test="reqInfo != null">req_info,
|
||||
</if>
|
||||
<if test="deptId != null">dept_id,
|
||||
</if>
|
||||
<if test="scenicId != null">scenic_id,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">#{sn},
|
||||
</if>
|
||||
<if test="type != null">#{type},
|
||||
</if>
|
||||
<if test="time != null">#{time},
|
||||
</if>
|
||||
<if test="dataTime != null">#{dataTime},
|
||||
</if>
|
||||
<if test="createdTime != null">#{createdTime},
|
||||
</if>
|
||||
<if test="passflowType != null">#{passflowType},
|
||||
</if>
|
||||
<if test="longitude != null">#{longitude},
|
||||
</if>
|
||||
<if test="latitude != null">#{latitude},
|
||||
</if>
|
||||
<if test="name != null">#{name},
|
||||
</if>
|
||||
<if test="allIn != null">#{allIn},
|
||||
</if>
|
||||
<if test="allOut != null">#{allOut},
|
||||
</if>
|
||||
<if test="passflowIn != null">#{passflowIn},
|
||||
</if>
|
||||
<if test="passflowOut != null">#{passflowOut},
|
||||
</if>
|
||||
<if test="ip != null">#{ip},
|
||||
</if>
|
||||
<if test="op != null">#{op},
|
||||
</if>
|
||||
<if test="realNum != null">#{realNum},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
<if test="sendInfo != null">#{sendInfo},
|
||||
</if>
|
||||
<if test="reqInfo != null">#{reqInfo},
|
||||
</if>
|
||||
<if test="deptId != null">#{deptId},
|
||||
</if>
|
||||
<if test="scenicId != null">#{scenicId},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateZdyDevicePassflowCountLog" parameterType="ZdyDevicePassflowCountLog">
|
||||
update zdy_device_passflow_count_log
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="sn != null">sn =
|
||||
#{sn},
|
||||
</if>
|
||||
<if test="type != null">type =
|
||||
#{type},
|
||||
</if>
|
||||
<if test="time != null">time =
|
||||
#{time},
|
||||
</if>
|
||||
<if test="dataTime != null">data_time =
|
||||
#{dataTime},
|
||||
</if>
|
||||
<if test="createdTime != null">created_time =
|
||||
#{createdTime},
|
||||
</if>
|
||||
<if test="passflowType != null">passflow_type =
|
||||
#{passflowType},
|
||||
</if>
|
||||
<if test="longitude != null">longitude =
|
||||
#{longitude},
|
||||
</if>
|
||||
<if test="latitude != null">latitude =
|
||||
#{latitude},
|
||||
</if>
|
||||
<if test="name != null">name =
|
||||
#{name},
|
||||
</if>
|
||||
<if test="allIn != null">all_in =
|
||||
#{allIn},
|
||||
</if>
|
||||
<if test="allOut != null">all_out =
|
||||
#{allOut},
|
||||
</if>
|
||||
<if test="passflowIn != null">passflow_in =
|
||||
#{passflowIn},
|
||||
</if>
|
||||
<if test="passflowOut != null">passflow_out =
|
||||
#{passflowOut},
|
||||
</if>
|
||||
<if test="ip != null">ip =
|
||||
#{ip},
|
||||
</if>
|
||||
<if test="op != null">op =
|
||||
#{op},
|
||||
</if>
|
||||
<if test="realNum != null">real_num =
|
||||
#{realNum},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
<if test="sendInfo != null">send_info =
|
||||
#{sendInfo},
|
||||
</if>
|
||||
<if test="reqInfo != null">req_info =
|
||||
#{reqInfo},
|
||||
</if>
|
||||
<if test="deptId != null">dept_id =
|
||||
#{deptId},
|
||||
</if>
|
||||
<if test="scenicId != null">scenic_id =
|
||||
#{scenicId},
|
||||
</if>
|
||||
</trim>
|
||||
where log_id = #{logId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowCountLogByLogId" parameterType="Long">
|
||||
delete
|
||||
from zdy_device_passflow_count_log
|
||||
where log_id = #{logId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowCountLogByLogIds" parameterType="String">
|
||||
delete from zdy_device_passflow_count_log where log_id in
|
||||
<foreach item="logId" collection="array" open="(" separator="," close=")">
|
||||
#{logId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<select id="statisticsPassflowCount" parameterType="DevicePassflowCountReq" resultType="StatisticsPassflowCountVO">
|
||||
select ifnull(sum(cl.passflow_in),0) as passflowIn, ifnull(sum(cl.passflow_out),0) as passflowOut from zdy_device_passflow_count_log cl
|
||||
left join zdy_device_passflow p on p.sn = cl.sn
|
||||
left join sys_dept d on d.dept_id = cl.dept_id
|
||||
<where>
|
||||
<if test="sn != null and sn != ''">
|
||||
and cl.sn = #{sn}
|
||||
</if>
|
||||
<if test="passflowLocation != null and passflowLocation != ''">
|
||||
and p.passflow_location = #{passflowLocation}
|
||||
</if>
|
||||
<if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
|
||||
and cl.data_time between #{params.beginDataTime} and #{params.endDataTime}
|
||||
</if>
|
||||
${params.dataScope}
|
||||
</where>
|
||||
</select>
|
||||
</mapper>
|
@@ -0,0 +1,212 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zhwl.passflow.mapper.ZdyDevicePassflowGpsLogMapper">
|
||||
|
||||
<resultMap type="ZdyDevicePassflowGpsLog" id="ZdyDevicePassflowGpsLogResult">
|
||||
<result property="logId" column="log_id"/>
|
||||
<result property="sn" column="sn"/>
|
||||
<result property="type" column="type"/>
|
||||
<result property="time" column="time"/>
|
||||
<result property="dataTime" column="data_time"/>
|
||||
<result property="createdTime" column="created_time"/>
|
||||
<result property="longitude" column="longitude"/>
|
||||
<result property="latitude" column="latitude"/>
|
||||
<result property="no" column="no"/>
|
||||
<result property="speed" column="speed"/>
|
||||
<result property="direction" column="direction"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="sendInfo" column="send_info"/>
|
||||
<result property="reqInfo" column="req_info"/>
|
||||
<result property="deptId" column="dept_id"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectZdyDevicePassflowGpsLogVo">
|
||||
select gl.log_id,
|
||||
gl.sn,
|
||||
gl.type, gl.time,gl.data_time, gl.created_time, gl.longitude, gl.latitude, gl.no, gl.speed, gl.direction,gl.send_info,gl.req_info, gl.create_by, gl.create_time, gl.update_by, gl.update_time, gl.remark,gl.dept_id
|
||||
from zdy_device_passflow_gps_log gl
|
||||
</sql>
|
||||
|
||||
<select id="selectZdyDevicePassflowGpsLogList" parameterType="ZdyDevicePassflowGpsLog"
|
||||
resultMap="ZdyDevicePassflowGpsLogResult">
|
||||
<include refid="selectZdyDevicePassflowGpsLogVo"/>
|
||||
left join sys_dept d on gl.dept_id = d.dept_id
|
||||
<where>
|
||||
<if test="sn != null and sn != ''">
|
||||
and gl.sn = #{sn}
|
||||
</if>
|
||||
<if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
|
||||
and gl.data_time between #{params.beginDataTime} and #{params.endDataTime}
|
||||
</if>
|
||||
${params.dataScope}
|
||||
</where>
|
||||
order by gl.create_time desc
|
||||
</select>
|
||||
|
||||
<select id="selectZdyDevicePassflowGpsLogByLogId" parameterType="Long"
|
||||
resultMap="ZdyDevicePassflowGpsLogResult">
|
||||
<include refid="selectZdyDevicePassflowGpsLogVo"/>
|
||||
where gl.log_id = #{logId}
|
||||
</select>
|
||||
|
||||
<insert id="insertZdyDevicePassflowGpsLog" parameterType="ZdyDevicePassflowGpsLog" useGeneratedKeys="true"
|
||||
keyProperty="logId">
|
||||
insert into zdy_device_passflow_gps_log
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">sn,
|
||||
</if>
|
||||
<if test="type != null">type,
|
||||
</if>
|
||||
<if test="time != null">time,
|
||||
</if>
|
||||
<if test="dataTime != null">data_time,
|
||||
</if>
|
||||
<if test="createdTime != null">created_time,
|
||||
</if>
|
||||
<if test="longitude != null">longitude,
|
||||
</if>
|
||||
<if test="latitude != null">latitude,
|
||||
</if>
|
||||
<if test="no != null">no,
|
||||
</if>
|
||||
<if test="speed != null">speed,
|
||||
</if>
|
||||
<if test="direction != null">direction,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
</if>
|
||||
<if test="updateBy != null">update_by,
|
||||
</if>
|
||||
<if test="updateTime != null">update_time,
|
||||
</if>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
<if test="sendInfo != null">send_info,
|
||||
</if>
|
||||
<if test="reqInfo != null">req_info,
|
||||
</if>
|
||||
<if test="deptId != null">dept_id,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">#{sn},
|
||||
</if>
|
||||
<if test="type != null">#{type},
|
||||
</if>
|
||||
<if test="time != null">#{time},
|
||||
</if>
|
||||
<if test="dataTime != null">#{dataTime},
|
||||
</if>
|
||||
<if test="createdTime != null">#{createdTime},
|
||||
</if>
|
||||
<if test="longitude != null">#{longitude},
|
||||
</if>
|
||||
<if test="latitude != null">#{latitude},
|
||||
</if>
|
||||
<if test="no != null">#{no},
|
||||
</if>
|
||||
<if test="speed != null">#{speed},
|
||||
</if>
|
||||
<if test="direction != null">#{direction},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
<if test="sendInfo != null">#{sendInfo},
|
||||
</if>
|
||||
<if test="reqInfo != null">#{reqInfo},
|
||||
</if>
|
||||
<if test="deptId != null">#{deptId},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateZdyDevicePassflowGpsLog" parameterType="ZdyDevicePassflowGpsLog">
|
||||
update zdy_device_passflow_gps_log
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="sn != null">sn =
|
||||
#{sn},
|
||||
</if>
|
||||
<if test="type != null">type =
|
||||
#{type},
|
||||
</if>
|
||||
<if test="time != null">time =
|
||||
#{time},
|
||||
</if>
|
||||
<if test="dataTime != null">data_time =
|
||||
#{dataTime},
|
||||
</if>
|
||||
<if test="createdTime != null">created_time =
|
||||
#{createdTime},
|
||||
</if>
|
||||
<if test="longitude != null">longitude =
|
||||
#{longitude},
|
||||
</if>
|
||||
<if test="latitude != null">latitude =
|
||||
#{latitude},
|
||||
</if>
|
||||
<if test="no != null">no =
|
||||
#{no},
|
||||
</if>
|
||||
<if test="speed != null">speed =
|
||||
#{speed},
|
||||
</if>
|
||||
<if test="direction != null">direction =
|
||||
#{direction},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
<if test="sendInfo != null">send_info =
|
||||
#{sendInfo},
|
||||
</if>
|
||||
<if test="reqInfo != null">req_info =
|
||||
#{reqInfo},
|
||||
</if>
|
||||
<if test="deptId != null">dept_id =
|
||||
#{deptId},
|
||||
</if>
|
||||
</trim>
|
||||
where log_id = #{logId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowGpsLogByLogId" parameterType="Long">
|
||||
delete
|
||||
from zdy_device_passflow_gps_log
|
||||
where log_id = #{logId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowGpsLogByLogIds" parameterType="String">
|
||||
delete from zdy_device_passflow_gps_log where log_id in
|
||||
<foreach item="logId" collection="array" open="(" separator="," close=")">
|
||||
#{logId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@@ -0,0 +1,191 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zhwl.passflow.mapper.ZdyDevicePassflowHeartLogMapper">
|
||||
|
||||
<resultMap type="ZdyDevicePassflowHeartLog" id="ZdyDevicePassflowHeartLogResult">
|
||||
<result property="logId" column="log_id"/>
|
||||
<result property="sn" column="sn"/>
|
||||
<result property="type" column="type"/>
|
||||
<result property="time" column="time"/>
|
||||
<result property="dataTime" column="data_time"/>
|
||||
<result property="createdTime" column="created_time"/>
|
||||
<result property="state" column="state"/>
|
||||
<result property="name" column="name"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="sendInfo" column="send_info"/>
|
||||
<result property="reqInfo" column="req_info"/>
|
||||
<result property="deptId" column="dept_id"/>
|
||||
<result property="passflowName" column="passflow_name"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectZdyDevicePassflowHeartLogVo">
|
||||
select p.passflow_name,hl.log_id, hl.sn, hl.type, hl.time, hl.data_time,hl.created_time,hl.name, hl.state,hl.send_info,hl.req_info, hl.create_by, hl.create_time, hl.update_by, hl.update_time, hl.remark,hl.dept_id
|
||||
from zdy_device_passflow_heart_log hl
|
||||
left join zdy_device_passflow p on hl.sn = p.sn
|
||||
</sql>
|
||||
|
||||
<select id="selectZdyDevicePassflowHeartLogList" parameterType="ZdyDevicePassflowHeartLog"
|
||||
resultMap="ZdyDevicePassflowHeartLogResult">
|
||||
<include refid="selectZdyDevicePassflowHeartLogVo"/>
|
||||
left join sys_dept d on hl.dept_id = d.dept_id
|
||||
<where>
|
||||
<if test="sn != null and sn != ''">
|
||||
and hl.sn = #{sn}
|
||||
</if>
|
||||
<if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
|
||||
and hl.data_time between #{params.beginDataTime} and #{params.endDataTime}
|
||||
</if>
|
||||
<if test="passflowName != null and passflowName != ''">
|
||||
and p.passflow_name like concat('%', #{passflowName}, '%')
|
||||
</if>
|
||||
${params.dataScope}
|
||||
</where>
|
||||
order by hl.create_time desc
|
||||
</select>
|
||||
|
||||
<select id="selectZdyDevicePassflowHeartLogByLogId" parameterType="Long"
|
||||
resultMap="ZdyDevicePassflowHeartLogResult">
|
||||
<include refid="selectZdyDevicePassflowHeartLogVo"/>
|
||||
where hl.log_id = #{logId}
|
||||
</select>
|
||||
|
||||
<insert id="insertZdyDevicePassflowHeartLog" parameterType="ZdyDevicePassflowHeartLog" useGeneratedKeys="true"
|
||||
keyProperty="logId">
|
||||
insert into zdy_device_passflow_heart_log
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">sn,
|
||||
</if>
|
||||
<if test="type != null">type,
|
||||
</if>
|
||||
<if test="time != null">time,
|
||||
</if>
|
||||
<if test="dataTime != null">data_time,
|
||||
</if>
|
||||
<if test="createdTime != null">created_time,
|
||||
</if>
|
||||
<if test="name != null">name,
|
||||
</if>
|
||||
<if test="state != null">state,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
</if>
|
||||
<if test="updateBy != null">update_by,
|
||||
</if>
|
||||
<if test="updateTime != null">update_time,
|
||||
</if>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
<if test="sendInfo != null">send_info,
|
||||
</if>
|
||||
<if test="reqInfo != null">req_info,
|
||||
</if>
|
||||
<if test="deptId != null">dept_id,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">#{sn},
|
||||
</if>
|
||||
<if test="type != null">#{type},
|
||||
</if>
|
||||
<if test="time != null">#{time},
|
||||
</if>
|
||||
<if test="dataTime != null">#{dataTime},
|
||||
</if>
|
||||
<if test="createdTime != null">#{createdTime},
|
||||
</if>
|
||||
<if test="name != null">#{name},
|
||||
</if>
|
||||
<if test="state != null">#{state},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
<if test="sendInfo != null">#{sendInfo},
|
||||
</if>
|
||||
<if test="reqInfo != null">#{reqInfo},
|
||||
</if>
|
||||
<if test="deptId != null">#{deptId},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateZdyDevicePassflowHeartLog" parameterType="ZdyDevicePassflowHeartLog">
|
||||
update zdy_device_passflow_heart_log
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="sn != null">sn =
|
||||
#{sn},
|
||||
</if>
|
||||
<if test="type != null">type =
|
||||
#{type},
|
||||
</if>
|
||||
<if test="time != null">time =
|
||||
#{time},
|
||||
</if>
|
||||
<if test="dataTime != null">data_time =
|
||||
#{dataTime},
|
||||
</if>
|
||||
<if test="createdTime != null">created_time =
|
||||
#{createdTime},
|
||||
</if>
|
||||
<if test="name != null">name =
|
||||
#{name},
|
||||
</if>
|
||||
<if test="state != null">state =
|
||||
#{state},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
<if test="sendInfo != null">send_info =
|
||||
#{sendInfo},
|
||||
</if>
|
||||
<if test="reqInfo != null">req_info =
|
||||
#{reqInfo},
|
||||
</if>
|
||||
<if test="deptId != null">dept_id =
|
||||
#{deptId},
|
||||
</if>
|
||||
</trim>
|
||||
where log_id = #{logId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowHeartLogByLogId" parameterType="Long">
|
||||
delete
|
||||
from zdy_device_passflow_heart_log
|
||||
where log_id = #{logId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowHeartLogByLogIds" parameterType="String">
|
||||
delete from zdy_device_passflow_heart_log where log_id in
|
||||
<foreach item="logId" collection="array" open="(" separator="," close=")">
|
||||
#{logId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@@ -0,0 +1,223 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.zhwl.passflow.mapper.ZdyDevicePassflowMapper">
|
||||
|
||||
<resultMap type="ZdyDevicePassflow" id="ZdyDevicePassflowResult">
|
||||
<result property="passflowId" column="passflow_id"/>
|
||||
<result property="sn" column="sn"/>
|
||||
<result property="passflowName" column="passflow_name"/>
|
||||
<result property="passflowType" column="passflow_type"/>
|
||||
<result property="passflowLocation" column="passflow_location"/>
|
||||
<result property="name" column="name"/>
|
||||
<result property="longitude" column="longitude"/>
|
||||
<result property="latitude" column="latitude"/>
|
||||
<result property="status" column="status"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="syncTime" column="sync_time"/>
|
||||
<result property="deptId" column="dept_id"/>
|
||||
<result property="scenicId" column="scenic_id"/>
|
||||
<result property="scenicName" column="scenic_name"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectZdyDevicePassflowVo">
|
||||
select zdp.passflow_id,
|
||||
zdp.sn,
|
||||
zdp.passflow_name,
|
||||
zdp.passflow_type,
|
||||
zdp.passflow_location,
|
||||
zdp.name,
|
||||
zdp.longitude,
|
||||
zdp.latitude,
|
||||
zdp.status,
|
||||
zdp.create_by,
|
||||
zdp.create_time,
|
||||
zdp.update_by,
|
||||
zdp.update_time,
|
||||
zdp.remark,
|
||||
zdp.sync_time,
|
||||
zdp.dept_id,
|
||||
zdp.scenic_id,
|
||||
zs.scenic_name
|
||||
from zdy_device_passflow zdp
|
||||
left join zdy_scenic zs on zs.id = zdp.scenic_id
|
||||
</sql>
|
||||
|
||||
<select id="selectZdyDevicePassflowList" parameterType="ZdyDevicePassflow" resultMap="ZdyDevicePassflowResult">
|
||||
<include refid="selectZdyDevicePassflowVo"/>
|
||||
left join sys_dept d on zdp.dept_id = d.dept_id
|
||||
<where>
|
||||
<if test="passflowName != null and passflowName != ''">
|
||||
and zdp.passflow_name like concat('%', #{passflowName}, '%')
|
||||
</if>
|
||||
<if test="sn != null and sn != ''">
|
||||
and zdp.sn = #{sn}
|
||||
</if>
|
||||
<if test="status != null ">
|
||||
and zdp.status = #{status}
|
||||
</if>
|
||||
<if test="passflowLocation != null and passflowLocation != ''">
|
||||
and zdp.passflow_location = #{passflowLocation}
|
||||
</if>
|
||||
${params.dataScope}
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectZdyDevicePassflowByPassflowId" parameterType="Long"
|
||||
resultMap="ZdyDevicePassflowResult">
|
||||
<include refid="selectZdyDevicePassflowVo"/>
|
||||
where zdp.passflow_id = #{passflowId}
|
||||
</select>
|
||||
|
||||
<select id="selectZdyDevicePassflowBySnAndName" parameterType="String"
|
||||
resultMap="ZdyDevicePassflowResult">
|
||||
<include refid="selectZdyDevicePassflowVo"/>
|
||||
where zdp.sn = #{sn} and zdp.name = #{name}
|
||||
</select>
|
||||
|
||||
<insert id="insertZdyDevicePassflow" parameterType="ZdyDevicePassflow" useGeneratedKeys="true"
|
||||
keyProperty="passflowId">
|
||||
insert into zdy_device_passflow
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">sn,
|
||||
</if>
|
||||
<if test="passflowName != null">passflow_name,
|
||||
</if>
|
||||
<if test="passflowType != null">passflow_type,
|
||||
</if>
|
||||
<if test="passflowLocation != null">passflow_location,
|
||||
</if>
|
||||
<if test="name != null">name,
|
||||
</if>
|
||||
<if test="longitude != null">longitude,
|
||||
</if>
|
||||
<if test="latitude != null">latitude,
|
||||
</if>
|
||||
<if test="status != null">status,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
</if>
|
||||
<if test="updateBy != null">update_by,
|
||||
</if>
|
||||
<if test="updateTime != null">update_time,
|
||||
</if>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
<if test="syncTime != null">sync_time,
|
||||
</if>
|
||||
<if test="deptId != null">dept_id,
|
||||
</if>
|
||||
<if test="scenicId != null">scenic_id,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="sn != null">#{sn},
|
||||
</if>
|
||||
<if test="passflowName != null">#{passflowName},
|
||||
</if>
|
||||
<if test="passflowType != null">#{passflowType},
|
||||
</if>
|
||||
<if test="passflowLocation != null">#{passflowLocation},
|
||||
</if>
|
||||
<if test="name != null">#{name},
|
||||
</if>
|
||||
<if test="longitude != null">#{longitude},
|
||||
</if>
|
||||
<if test="latitude != null">#{latitude},
|
||||
</if>
|
||||
<if test="status != null">#{status},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
<if test="syncTime != null">#{syncTime},
|
||||
</if>
|
||||
<if test="deptId != null">#{deptId},
|
||||
</if>
|
||||
<if test="scenicId != null">#{scenicId},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateZdyDevicePassflow" parameterType="ZdyDevicePassflow">
|
||||
update zdy_device_passflow
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="sn != null">sn =
|
||||
#{sn},
|
||||
</if>
|
||||
<if test="passflowName != null">passflow_name =
|
||||
#{passflowName},
|
||||
</if>
|
||||
<if test="passflowType != null">passflow_type =
|
||||
#{passflowType},
|
||||
</if>
|
||||
<if test="passflowLocation != null">passflow_location =
|
||||
#{passflowLocation},
|
||||
</if>
|
||||
<if test="name != null">name =
|
||||
#{name},
|
||||
</if>
|
||||
<if test="longitude != null">longitude =
|
||||
#{longitude},
|
||||
</if>
|
||||
<if test="latitude != null">latitude =
|
||||
#{latitude},
|
||||
</if>
|
||||
<if test="status != null">status =
|
||||
#{status},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
<if test="syncTime != null">sync_time =
|
||||
#{syncTime},
|
||||
</if>
|
||||
<if test="deptId != null">dept_id =
|
||||
#{deptId},
|
||||
</if>
|
||||
<if test="scenicId != null">scenic_id =
|
||||
#{scenicId},
|
||||
</if>
|
||||
</trim>
|
||||
where passflow_id = #{passflowId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowByPassflowId" parameterType="Long">
|
||||
delete
|
||||
from zdy_device_passflow
|
||||
where passflow_id = #{passflowId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteZdyDevicePassflowByPassflowIds" parameterType="String">
|
||||
delete from zdy_device_passflow where passflow_id in
|
||||
<foreach item="passflowId" collection="array" open="(" separator="," close=")">
|
||||
#{passflowId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
Reference in New Issue
Block a user