From eb845e8be695ed1280a7cbf854a4d1dedf9db30d Mon Sep 17 00:00:00 2001
From: 陈昶聿 <chychen@nbjetron.com>
Date: 星期五, 30 十月 2026 15:02:55 +0800
Subject: [PATCH] 【丽水】/smartor/serviceSubtask/getSfStatisticsHyperlink 和 /smartor/serviceSubtask/getSfStatistics 统计的时候,对于 service_subtask.current_preachForm 为空的数据 当成 service_subtask.preachform 字符串的第一个执行方式、首次待随访全部(visitCount = 1 && sendstate in (1、2、3、7)) 区别于原先的待随访,这个是给市一使用的                                                                                                                                                                                            再次待随访全部(visitCount > 1 && sendstate in (1、2、3、7)) 区别于原先的待随访,这个是给市一使用的                                                                                                                                                                                            首次待随访待发送(visitCount = 1 && sendstate in (1、2))                                                                                                                                                                                            再次待随访待发送(visitCount > 1 && sendstate in (1、2))                                                                                                                                                                                            首次待随访已发送(visitCount = 1 && sendstate = in (3、7))                                                                                                                                                                                            再次待随访已发送(visitCount > 1 && sendstate = in (3、7))                                                                                                                                                                                            首次已发送(visitCount = 1 && sendstate = 3)                                                                                                                                                                                            再次已发送(visitCount > 1 && sendstate = 3)

---
 smartor/src/main/resources/mapper/smartor/ServiceTaskScheduleMapper.xml |   30 ++++++++++++++++++++++++++++++
 1 files changed, 30 insertions(+), 0 deletions(-)

diff --git a/smartor/src/main/resources/mapper/smartor/ServiceTaskScheduleMapper.xml b/smartor/src/main/resources/mapper/smartor/ServiceTaskScheduleMapper.xml
index 878fb33..c21a7ad 100644
--- a/smartor/src/main/resources/mapper/smartor/ServiceTaskScheduleMapper.xml
+++ b/smartor/src/main/resources/mapper/smartor/ServiceTaskScheduleMapper.xml
@@ -17,6 +17,10 @@
         <result property="nextExecuteTime" column="next_execute_time"/>
         <result property="scheduleBenchmark" column="schedule_benchmark"/>
         <result property="scheduleBenchmarkCustomTime" column="schedule_benchmark_custom_time"/>
+        <result property="deptCodes" column="dept_codes"/>
+        <result property="wardCodes" column="ward_codes"/>
+        <result property="icd10Codes" column="icd10_codes"/>
+        <result property="oplevelCodes" column="oplevel_codes"/>
         <result property="remark" column="remark"/>
         <result property="delFlag" column="del_flag"/>
         <result property="createBy" column="create_by"/>
@@ -40,6 +44,10 @@
                next_execute_time,
                schedule_benchmark,
                schedule_benchmark_custom_time,
+               dept_codes,
+               ward_codes,
+               icd10_codes,
+               oplevel_codes,
                remark,
                del_flag,
                create_by,
@@ -69,6 +77,10 @@
         where del_flag = '0'
         <if test="taskid != null">and taskid = #{taskid}</if>
         <if test="scheduleStyle != null">and schedule_style = #{scheduleStyle}</if>
+        <if test="deptCode != null">and INSTR(dept_codes,  #{deptCode}) > 0</if>
+        <if test="wardCode != null">and INSTR(ward_codes,  #{wardCode}) > 0</if>
+        <if test="icd10Code != null">and INSTR(icd10_codes,  #{icd10Code}) > 0</if>
+        <if test="oplevelCode != null">and INSTR(oplevel_codes,  #{oplevelCode}) > 0</if>
         <if test="orgid != null and orgid != ''">and orgid = #{orgid}</if>
         <if test="campusid != null and campusid != ''">and campusid = #{campusid}</if>
         order by id desc
@@ -89,6 +101,10 @@
             <if test="nextExecuteTime != null">next_execute_time,</if>
             <if test="scheduleBenchmark != null">schedule_benchmark,</if>
             <if test="scheduleBenchmarkCustomTime != null">schedule_benchmark_custom_time,</if>
+            <if test="deptCodes != null">dept_codes,</if>
+            <if test="wardCodes != null">ward_codes,</if>
+            <if test="icd10Codes != null">icd10_codes,</if>
+            <if test="oplevelCodes != null">oplevel_codes,</if>
             <if test="remark != null">remark,</if>
             <if test="delFlag != null">del_flag,</if>
             <if test="createBy != null">create_by,</if>
@@ -110,6 +126,10 @@
             <if test="nextExecuteTime != null">#{nextExecuteTime},</if>
             <if test="scheduleBenchmark != null">#{scheduleBenchmark},</if>
             <if test="scheduleBenchmarkCustomTime != null">#{scheduleBenchmarkCustomTime},</if>
+            <if test="deptCodes != null">#{deptCodes},</if>
+            <if test="wardCodes != null">#{wardCodes},</if>
+            <if test="icd10Codes != null">#{icd10Codes},</if>
+            <if test="oplevelCodes != null">#{oplevelCodes},</if>
             <if test="remark != null">#{remark},</if>
             <if test="delFlag != null">#{delFlag},</if>
             <if test="createBy != null">#{createBy},</if>
@@ -137,6 +157,10 @@
             <if test="scheduleBenchmarkCustomTime != null">
                 schedule_benchmark_custom_time = #{scheduleBenchmarkCustomTime},
             </if>
+            <if test="deptCodes != null">dept_codes = #{deptCodes},</if>
+            <if test="wardCodes != null">ward_codes = #{wardCodes},</if>
+            <if test="icd10Codes != null">icd10_codes = #{icd10Codes},</if>
+            <if test="oplevelCodes != null">oplevel_codes = #{oplevelCodes},</if>
             <if test="remark != null">remark = #{remark},</if>
             <if test="delFlag != null">del_flag = #{delFlag},</if>
             <if test="updateBy != null">update_by = #{updateBy},</if>
@@ -162,6 +186,12 @@
           and del_flag = '0'
     </update>
 
+    <delete id="hardDeleteByTaskid" parameterType="Long">
+        delete from service_task_schedule
+        where del_flag = '0'
+        and taskid = #{taskid}
+    </delete>
+
     <select id="selectActiveCycleSchedules" resultMap="ServiceTaskScheduleResult">
         <include refid="selectServiceTaskScheduleVo"/>
         where del_flag = '0'

--
Gitblit v1.9.3