From 77a1874f7d908e0773e78ce683cf6ed5c889d38c Mon Sep 17 00:00:00 2001 From: haozq <1611483981@qq.com> Date: Sat, 23 Mar 2024 18:26:24 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=9F=E8=83=BD=E5=BC=80=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../background/mapper/DutyPlanMapper.java | 8 +-- .../main/resources/mapper/DutyPlanMapper.xml | 61 ++++++++----------- .../main/resources/mapper/TaskCheckMapper.xml | 58 ++++++++++++++++++ 3 files changed, 85 insertions(+), 42 deletions(-) create mode 100644 securitycontrol-model/securitycontrol-background/src/main/resources/mapper/TaskCheckMapper.xml diff --git a/securitycontrol-model/securitycontrol-background/src/main/java/com/securitycontrol/background/mapper/DutyPlanMapper.java b/securitycontrol-model/securitycontrol-background/src/main/java/com/securitycontrol/background/mapper/DutyPlanMapper.java index 9f9a2fc..559582d 100644 --- a/securitycontrol-model/securitycontrol-background/src/main/java/com/securitycontrol/background/mapper/DutyPlanMapper.java +++ b/securitycontrol-model/securitycontrol-background/src/main/java/com/securitycontrol/background/mapper/DutyPlanMapper.java @@ -16,13 +16,7 @@ import java.util.Map; */ @Repository(value = "DutyPlanMapper") public interface DutyPlanMapper { - /** - * DD - * - * @param vo - * @return - */ - int addDutyPlan(DutyPlanVo vo); + /** * 获取班组列表 diff --git a/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/DutyPlanMapper.xml b/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/DutyPlanMapper.xml index 5793a81..7230261 100644 --- a/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/DutyPlanMapper.xml +++ b/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/DutyPlanMapper.xml @@ -3,19 +3,20 @@ - - - INSERT INTO tb_duty_plan + + + replace into tb_duty_plan - create_day, - type, - mon, - tue, - wed, - thu, - fri, - sat, - sun, + create_day, + type, + mon, + tue, + wed, + thu, + fri, + sat, + sun, + update_time #{createDay}, @@ -25,22 +26,11 @@ #{wed}, #{thu}, #{fri}, + #{sat}, #{sun}, + now() - - - UPDATE tb_duty_plan - - mon = #{mon}, - tue = #{tue}, - wed = #{wed}, - thu = #{thu}, - fri = #{fri}, - sat = #{sat}, - sun = #{sun}, - - WHERE create_day = #{createDay} and type=#{type} - + @@ -56,14 +46,15 @@ tdp.sat as sat, tdp.sun as sun FROM tb_duty_plan tdp - - - AND tdp.create_day=#{createDay} - - - AND tdp.type=#{type} - - - oreder by create_time + where tdp.del_flag=0 + + AND tdp.create_day=#{createDay} + + + AND tdp.type=#{type} + + + ORDER by create_time + \ No newline at end of file diff --git a/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/TaskCheckMapper.xml b/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/TaskCheckMapper.xml new file mode 100644 index 0000000..ff1760a --- /dev/null +++ b/securitycontrol-model/securitycontrol-background/src/main/resources/mapper/TaskCheckMapper.xml @@ -0,0 +1,58 @@ + + + + + replace into t_class_metting_check + (class_id,is_xs,user_id,check_time,create_day) values (#{classId},0,#{userId},0,CURRENT_DATE()) + + + DELETE FROM t_class_metting_check WHERE class_id = #{classId} and user_id=#{userId} + + + DELETE FROM t_class_metting_check WHERE user_id=#{userId} + + + + + \ No newline at end of file