|
@@ -61,12 +61,15 @@
|
|
GROUP BY dept_name) e ON e.dept_name = a.dept_name
|
|
GROUP BY dept_name) e ON e.dept_name = a.dept_name
|
|
</if>
|
|
</if>
|
|
<if test="mark != null and mark == 'person'">
|
|
<if test="mark != null and mark == 'person'">
|
|
- LEFT JOIN lawenforcement_person p ON p.record_id = a.id AND main_person = 1
|
|
|
|
|
|
+ LEFT JOIN lawenforcement_person p ON p.record_id = a.id
|
|
</if>
|
|
</if>
|
|
<if test="mark != null and mark == 'item'">
|
|
<if test="mark != null and mark == 'item'">
|
|
LEFT JOIN lawenforcement_subitem s ON s.record_id = a.id
|
|
LEFT JOIN lawenforcement_subitem s ON s.record_id = a.id
|
|
</if>
|
|
</if>
|
|
<where>
|
|
<where>
|
|
|
|
+ <if test="mark != null and mark == 'person'">
|
|
|
|
+ AND main_person = 1
|
|
|
|
+ </if>
|
|
<if test="deptName != null and deptName != ''">
|
|
<if test="deptName != null and deptName != ''">
|
|
AND a.dept_name LIKE CONCAT('%', #{deptName}, '%')
|
|
AND a.dept_name LIKE CONCAT('%', #{deptName}, '%')
|
|
</if>
|
|
</if>
|