From 14b1aaecb3cb1042663135038bc1e81208a7ef6f Mon Sep 17 00:00:00 2001
From: Administrator <1144154118@qq.com>
Date: 星期三, 26 七月 2023 09:42:21 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
ard-work/src/main/resources/mapper/app/ArdAppTaskMapper.xml | 44 ++++++++++++++++++++++++++++++++++++++++----
1 files changed, 40 insertions(+), 4 deletions(-)
diff --git a/ard-work/src/main/resources/mapper/app/ArdAppTaskMapper.xml b/ard-work/src/main/resources/mapper/app/ArdAppTaskMapper.xml
index 297f886..b12a14b 100644
--- a/ard-work/src/main/resources/mapper/app/ArdAppTaskMapper.xml
+++ b/ard-work/src/main/resources/mapper/app/ArdAppTaskMapper.xml
@@ -32,6 +32,8 @@
<result property="text" column="sub1_text"/>
<result property="voice" column="sub1_voice"/>
<result property="taskId" column="sub1_task_id"/>
+ <result property="status" column="sub1_status"/>
+ <result property="clockInPicUrl" column="sub1_clock_in_pic_url"/>
</resultMap>
<resultMap type="ArdAppTaskPic" id="ArdAppTaskPicResult">
<result property="id" column="sub2_id"/>
@@ -69,6 +71,13 @@
<if test="name != null and name != ''">and name like '%'||#{name}||'%'</if>
<if test="text != null and text != ''">and text = #{text}</if>
<if test="voice != null and voice != ''">and voice = #{voice}</if>
+ <if test="params.beginTime != null and params.beginTime != ''"><!-- 寮�濮嬫椂闂存绱� -->
+ and create_time >= to_timestamp(#{params.beginTime},'yyyy-MM-DD HH24:MI:ss')
+ </if>
+ <if test="params.endTime != null and params.endTime != ''"><!-- 缁撴潫鏃堕棿妫�绱� -->
+ and create_time <= to_timestamp(#{params.endTime},'yyyy-MM-DD HH24:MI:ss')
+ </if>
+ <if test="userId != null and userId != ''">and user_id = #{userId}</if>
<!-- 鏁版嵁鑼冨洿杩囨护 -->
${params.dataScope}
</where>
@@ -94,11 +103,19 @@
c.altitude as sub1_altitude,
c.user_id as sub1_user_id,
c.text as sub1_text,
- c.voice as sub1_voice
+ c.voice as sub1_voice,
+ c.status as sub1_status,
+ c.clock_in_pic_url as sub1_clock_in_pic_url
from ard_app_task a
left join ard_app_task_pic b on b.task_id = a.id
left join ard_app_task_detail c on c.task_id = a.id
where c.user_id = #{userId}
+ <if test="params.beginTime != null and params.beginTime != ''"><!-- 寮�濮嬫椂闂存绱� -->
+ and a.create_time >= to_timestamp(#{params.beginTime},'yyyy-MM-DD HH24:MI:ss')
+ </if>
+ <if test="params.endTime != null and params.endTime != ''"><!-- 缁撴潫鏃堕棿妫�绱� -->
+ and a.create_time <= to_timestamp(#{params.endTime},'yyyy-MM-DD HH24:MI:ss')
+ </if>
</select>
<select id="selectArdAppTaskById" parameterType="String" resultMap="ArdAppTaskSubResult">
select a.id,
@@ -163,7 +180,9 @@
c.altitude as sub_altitude,
c.user_id as sub_user_id,
c.text as sub_text,
- c.voice as sub_voice
+ c.voice as sub_voice,
+ c.status as sub_status,
+ c.clock_in_pic_url as sub_clock_in_pic_url
from ard_app_task a
left join ard_app_task_detail c on c.task_id = a.id
where a.id = #{id}
@@ -260,16 +279,18 @@
</delete>
<insert id="batchArdAppTaskDetail">
- insert into ard_app_task_detail( id, name, longitude, latitude, altitude, user_id, text, voice, task_id) values
+ insert into ard_app_task_detail( id, name, longitude, latitude, altitude, user_id, text, voice, task_id,status,clock_in_pic_url) values
<foreach item="item" index="index" collection="list" separator=",">
( #{item.id}, #{item.name}, #{item.longitude}, #{item.latitude}, #{item.altitude}, #{item.userId},
- #{item.text}, #{item.voice}, #{item.taskId})
+ #{item.text}, #{item.voice}, #{item.taskId}, #{item.status}, #{item.clockInPicUrl})
</foreach>
</insert>
<update id="updateArdAppTaskDetail" parameterType="ArdAppTaskDetail">
update ard_app_task_detail
<trim prefix="SET" suffixOverrides=",">
+ <if test="status != null">status = #{status},</if>
+ <if test="clockInPicUrl != null">clock_in_pic_url = #{clockInPicUrl},</if>
<if test="text != null">text = #{text},</if>
<if test="voice != null">voice = #{voice},</if>
</trim>
@@ -286,4 +307,19 @@
from ard_app_task_detail_pic
where task_detail_id = #{taskDetailId}
</delete>
+ <select id="selectArdAppTaskDetailById" parameterType="String" resultType="ArdAppTaskDetail">
+ select
+ c.id,
+ c.name,
+ c.longitude,
+ c.latitude,
+ c.altitude,
+ c.user_id,
+ c.text,
+ c.voice,
+ c.status,
+ c.clock_in_pic_url
+ from ard_app_task_detail c
+ where c.id = #{id}
+ </select>
</mapper>
\ No newline at end of file
--
Gitblit v1.9.3