fix: 查询失败的任务患者根据时间,不止创建,也根据同步时间

master
wyb 3 months ago
parent 4ecbbe1902
commit 844c7b15cc

@ -70,10 +70,21 @@
</select>
<select id="findFailedTaskPatId" resultType="java.lang.String">
select patient_id
from docus_archivefile.af_collect_task
where create_time >=#{startDate}
and sysflag = #{collectorId}
and state not in('3','4')
from (
select patient_id
from docus_archivefile.af_collect_task
where create_time >= #{startDate}
and sysflag = #{collectorId}
and state not in ('3', '4')
union
select patient_id
from docus_archivefile.af_collect_task
where sync_time >= #{startDate}
and sysflag = #{collectorId}
and state not in ('3', '4')
) t1
group by patient_id
</select>
<select id="getZyPatientIdsByYzyJzh" resultType="com.docus.server.archive.entity.BasicExtend">

Loading…
Cancel
Save