From 3bc7faf3efd9d73cfa1726a553833872881dba3f Mon Sep 17 00:00:00 2001 From: zhangjian <zhangjianrock@163.com> Date: 星期一, 05 六月 2023 16:13:25 +0800 Subject: [PATCH] 视频巡检任务,步骤按相对相机位置顺时针方向转,北 东 南 西 --- ard-work/src/main/resources/mapper/inspect/ArdVideoInspectRecordMapper.xml | 27 ++++++++++++++++++++++++--- 1 files changed, 24 insertions(+), 3 deletions(-) diff --git a/ard-work/src/main/resources/mapper/inspect/ArdVideoInspectRecordMapper.xml b/ard-work/src/main/resources/mapper/inspect/ArdVideoInspectRecordMapper.xml index c08b4cc..a4182a0 100644 --- a/ard-work/src/main/resources/mapper/inspect/ArdVideoInspectRecordMapper.xml +++ b/ard-work/src/main/resources/mapper/inspect/ArdVideoInspectRecordMapper.xml @@ -20,16 +20,34 @@ <select id="selectArdVideoInspectRecordList" parameterType="ArdVideoInspectRecord" resultMap="ArdVideoInspectRecordResult"> <include refid="selectArdVideoInspectRecordVo"/> - <where> + <where> <if test="startTime != null and startTime != ''"> and start_time = #{startTime}</if> - <if test="endTime != null and endTime != ''"> and end_time = #{endTime}</if> + <if test="endTime != null and endTime != ''"> and end_time = #{ejava.util.HashMapndTime}</if> <if test="recordFilePath != null and recordFilePath != ''"> and record_file_path = #{recordFilePath}</if> <if test="stepId != null and stepId != ''"> and step_id = #{stepId}</if> <if test="deptId != null and deptId != ''"> and dept_id = #{deptId}</if> <if test="userId != null and userId != ''"> and user_id = #{userId}</if> </where> </select> - + <!--鎸夋棩鏈熸煡璇�--> + <select id="selectArdVideoInspectRecordListByStartTime" parameterType="ArdVideoInspectRecord" resultType="java.util.HashMap"> + <include refid="selectArdVideoInspectRecordVo"/> + <where> + <if test="startTime != null and startTime != ''">and start_time like ('${startTime}%')</if> + <if test="stepId != null and stepId != ''">and step_id = #{stepId}</if> + </where> + select r.*,s.well_id,w.well_id as well_name from ard_video_inspect_record r ,ard_video_inspect_task_step + s,ard_alarmpoints_well w where start_time like ('${startTime}%') and r.step_id = s.id and s.well_id = w.id + order by start_time desc + </select> + <!--鎸夋湀浠界粺璁℃枃浠舵暟閲�--> + <select id="selectArdVideoInspectRecordCountByStartMonth" parameterType="String" resultType="java.util.HashMap"> + select f.start_date,count(*) from + (select substring(r.start_time,0,11)as start_date,* from ard_video_inspect_record r + where r.start_time like '${startMonth}%') as f + group by f.start_date + </select> + <select id="selectArdVideoInspectRecordById" parameterType="String" resultMap="ArdVideoInspectRecordResult"> <include refid="selectArdVideoInspectRecordVo"/> where id = #{id} @@ -45,6 +63,7 @@ <if test="stepId != null">step_id,</if> <if test="deptId != null">dept_id,</if> <if test="userId != null">user_id,</if> + <if test="wellName != null">well_name,</if> </trim> <trim prefix="values (" suffix=")" suffixOverrides=","> <if test="id != null">#{id},</if> @@ -54,6 +73,7 @@ <if test="stepId != null">#{stepId},</if> <if test="deptId != null">#{deptId},</if> <if test="userId != null">#{userId},</if> + <if test="wellName != null">#{wellName},</if> </trim> </insert> @@ -66,6 +86,7 @@ <if test="stepId != null">step_id = #{stepId},</if> <if test="deptId != null">dept_id = #{deptId},</if> <if test="userId != null">user_id = #{userId},</if> + <if test="wellName != null">well_name = #{wellName},</if> </trim> where id = #{id} </update> -- Gitblit v1.9.3