|
@@ -618,24 +618,24 @@
|
|
|
<if test="organIdsStr != null and organIdsStr != ''">
|
|
|
AND FIND_IN_SET(tcs.organ_id_,#{organIdsStr})
|
|
|
</if>
|
|
|
- </select>
|
|
|
+ </select>K
|
|
|
<select id="queryInspectionItem" resultType="java.lang.Long">
|
|
|
SELECT DISTINCT ii.id_ FROM inspection_item ii
|
|
|
- WHERE ii.times_ > planned_times_ AND ii.item_ = 'INSPECT' AND ii.memo_ IS NULL
|
|
|
+ WHERE ii.times_ > planned_times_ AND ii.item_ = 'INSPECT' AND ii.memo_ =''
|
|
|
<if test="organIdsStr != null and organIdsStr != ''">
|
|
|
AND FIND_IN_SET(ii.organ_id_,#{organIdsStr})
|
|
|
</if>
|
|
|
</select>
|
|
|
<select id="queryInspectionItemPlan" resultType="java.lang.Long">
|
|
|
SELECT DISTINCT iip.id_ FROM inspection_item_plan iip
|
|
|
- WHERE iip.status_ = 0 AND iip.memo_ IS NULL
|
|
|
+ WHERE iip.status_ = 0 AND iip.memo_ =''
|
|
|
<if test="organIdsStr != null and organIdsStr != ''">
|
|
|
AND FIND_IN_SET(iip.organ_id_,#{organIdsStr})
|
|
|
</if>
|
|
|
</select>
|
|
|
<select id="queryStudentVisit" resultType="java.lang.Long">
|
|
|
SELECT DISTINCT ii.id_ FROM inspection_item ii
|
|
|
- WHERE ii.item_ = 'VISIT' AND ii.memo_ IS NULL
|
|
|
+ WHERE ii.item_ = 'VISIT' AND ii.memo_ =''
|
|
|
AND ii.times_ > (SELECT COUNT(DISTINCT sv.id_) FROM student_visit sv
|
|
|
WHERE sv.teacher_id_ = ii.user_id_ AND DATE_FORMAT(ii.create_time_,'%Y-%m') = DATE_FORMAT(sv.visit_time_,'%Y-%m'))
|
|
|
<if test="organIdsStr != null and organIdsStr != ''">
|
|
@@ -649,7 +649,7 @@
|
|
|
FROM
|
|
|
inspection_item_plan
|
|
|
WHERE
|
|
|
- conclusion_status_ = 1
|
|
|
+ conclusion_status_ = 1 AND memo_=''
|
|
|
<if test="organIds!=null and organIds.size()>0">
|
|
|
AND organ_id_ IN
|
|
|
<foreach collection="organIds" item="organId" open="(" close=")" separator=",">
|