|
@@ -858,22 +858,19 @@
|
|
|
GROUP_CONCAT( DISTINCT c.realname ) realname,
|
|
|
sum( t.score ) sumscore,
|
|
|
GROUP_CONCAT( DISTINCT t.task_rule_id ) task_rule_id
|
|
|
- FROM wm_task t
|
|
|
- LEFT JOIN wm_score_package p ON t.score_package_id = p.id
|
|
|
- JOIN wm_task_type b
|
|
|
- JOIN sys_user c
|
|
|
- JOIN sys_dept d
|
|
|
+ FROM wm_task t, wm_score_package p,wm_task_type b, sys_user c,sys_dept d
|
|
|
WHERE b.id = t.task_type_id
|
|
|
+ and t.score_package_id = p.id
|
|
|
AND c.user_id = t.task_user_id
|
|
|
AND c.dept_id = d.dept_id
|
|
|
+ AND t.enable_flag='0'
|
|
|
+ AND t.del_flag='0'
|
|
|
<if test="query.taskStatus != null and query.taskStatus != ''">
|
|
|
- and t.task_status = #{query.taskStatus}
|
|
|
+ AND t.task_status = #{query.taskStatus}
|
|
|
</if>
|
|
|
<if test="query.taskStatus == null or query.taskStatus == ''">
|
|
|
- and t.task_status = 3
|
|
|
+ AND t.task_status = '3'
|
|
|
</if>
|
|
|
- and t.enable_flag=0
|
|
|
- and t.del_flag=0
|
|
|
<if test="query.id!=null and query.id!=''">
|
|
|
AND t.id in(${query.id})
|
|
|
</if>
|
|
@@ -891,23 +888,20 @@
|
|
|
GROUP_CONCAT( DISTINCT c.realname ) realname,
|
|
|
sum( t.score ) sumscore,
|
|
|
GROUP_CONCAT( DISTINCT t.task_rule_id ) task_rule_id
|
|
|
- FROM wm_task t
|
|
|
- LEFT JOIN wm_score_package p ON t.score_package_id = p.id
|
|
|
- JOIN wm_task_type b
|
|
|
- JOIN sys_user c
|
|
|
- JOIN sys_dept d
|
|
|
+ FROM wm_task t, wm_score_package p, wm_task_type b, sys_user c, sys_dept d
|
|
|
WHERE b.id = t.task_type_id
|
|
|
+ and t.score_package_id = p.id
|
|
|
AND c.user_id = t.task_user_id
|
|
|
AND t.dept_id = d.dept_id
|
|
|
+ AND t.enable_flag='0'
|
|
|
+ AND t.del_flag='0'
|
|
|
+ AND p.package_type2='2'
|
|
|
<if test="query.taskStatus != null and query.taskStatus != ''">
|
|
|
- and t.task_status = #{query.taskStatus}
|
|
|
+ AND t.task_status = #{query.taskStatus}
|
|
|
</if>
|
|
|
<if test="query.taskStatus == null or query.taskStatus == ''">
|
|
|
- and t.task_status = 3
|
|
|
+ AND t.task_status = '3'
|
|
|
</if>
|
|
|
- and t.enable_flag=0
|
|
|
- and t.del_flag=0
|
|
|
- and p.package_type2=2
|
|
|
<if test="query.id!=null and query.id!=''">
|
|
|
AND t.id in(${query.id})
|
|
|
</if>
|
|
@@ -1044,10 +1038,11 @@
|
|
|
|
|
|
<select id="getMaxCreateTime" resultType="java.util.HashMap">
|
|
|
select max(t.lookinto_date) as MaxTime from wm_task t
|
|
|
- where 1=1
|
|
|
- <if test="query.id!=null and query.id!=''">
|
|
|
- AND t.id in(${query.id})
|
|
|
- </if>
|
|
|
+ <where>
|
|
|
+ <if test="query.id!=null and query.id!=''">
|
|
|
+ t.id in(${query.id})
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
</select>
|
|
|
|
|
|
<select id="selectListByWmTask" resultMap="wmTaskMap">
|
|
@@ -1070,7 +1065,7 @@
|
|
|
FROM wm_score_package
|
|
|
WHERE relation_score_id IN
|
|
|
(SELECT id FROM wm_score_package WHERE relation_score_id IN (SELECT id FROM wm_score_package WHERE relation_score_id = #{query.id})))
|
|
|
- AND task_status = 3
|
|
|
+ AND task_status = '3'
|
|
|
AND (
|
|
|
(report_drug_approval_status IN (5, 6) AND report_drug_approval_opinion = 1)
|
|
|
OR (report_one_approval_status IN (5, 6) AND report_one_approval_opinion = 1)
|
|
@@ -1080,14 +1075,17 @@
|
|
|
|
|
|
<select id="selectSettleTask" resultType="java.util.HashMap">
|
|
|
select t.id,
|
|
|
- t.task_type_id as taskTypeId
|
|
|
- ,p.task_type_name as taskTypeName
|
|
|
- ,t.lookinto_date as lookintoDate
|
|
|
- ,c.temp1,c.temp2,c.temp3,c.temp4
|
|
|
+ t.task_type_id as taskTypeId,
|
|
|
+ p.task_type_name as taskTypeName,
|
|
|
+ t.lookinto_date as lookintoDate,
|
|
|
+ c.temp1,
|
|
|
+ c.temp2,
|
|
|
+ c.temp3,
|
|
|
+ c.temp4
|
|
|
from wm_task t
|
|
|
left join wm_task_type p on t.task_type_id=p.id
|
|
|
left join wm_task_content c on c.id=t.task_content_id
|
|
|
- where t.del_flag=0
|
|
|
+ where t.del_flag='0'
|
|
|
<if test="query.id!=null and query.id!=''">
|
|
|
and t.id = #{query.id}
|
|
|
</if>
|
|
@@ -1152,9 +1150,9 @@
|
|
|
wm_task t
|
|
|
LEFT JOIN wm_task_content tc ON tc.id = t.task_content_id
|
|
|
<where>
|
|
|
- t.del_flag = 0
|
|
|
+ t.del_flag = '0'
|
|
|
AND t.real_flag = 0
|
|
|
- AND task_status = 3
|
|
|
+ AND task_status = '3'
|
|
|
AND score_package_id = #{scorePackageId, jdbcType=BIGINT}
|
|
|
<if test="prescriptionNo != null and prescriptionNo != ''">
|
|
|
AND tc.temp3 = #{prescriptionNo, jdbcType=VARCHAR}
|