|
|
@ -850,11 +850,16 @@ |
|
|
AND ( |
|
|
AND ( |
|
|
(u.law_certificate_num is not null AND u.law_certificate_num !="") |
|
|
(u.law_certificate_num is not null AND u.law_certificate_num !="") |
|
|
or (d.`zone` = 5 or d.`zone` = 15) |
|
|
or (d.`zone` = 5 or d.`zone` = 15) |
|
|
or EXISTS ( |
|
|
<if test="deptId != null"> |
|
|
SELECT 1 FROM sys_dept anc |
|
|
or EXISTS ( |
|
|
WHERE (anc.`zone` = 5 OR anc.`zone` = 15) |
|
|
SELECT 1 FROM sys_dept anc |
|
|
AND FIND_IN_SET(anc.dept_id, d.ancestors) |
|
|
WHERE (anc.`zone` = 5 OR anc.`zone` = 15) |
|
|
) |
|
|
AND FIND_IN_SET(anc.dept_id, d.ancestors) |
|
|
|
|
|
) |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="deptId == null"> |
|
|
|
|
|
or (d.parent_id in (select dept_id from sys_dept where `zone` = 5 or `zone` = 15)) |
|
|
|
|
|
</if> |
|
|
) |
|
|
) |
|
|
</if> |
|
|
</if> |
|
|
and u.dept_id != 405 |
|
|
and u.dept_id != 405 |
|
|
@ -897,11 +902,16 @@ |
|
|
AND ( |
|
|
AND ( |
|
|
(u.law_certificate_num is not null AND u.law_certificate_num !="") |
|
|
(u.law_certificate_num is not null AND u.law_certificate_num !="") |
|
|
or (d.`zone` = 5 or d.`zone` = 15) |
|
|
or (d.`zone` = 5 or d.`zone` = 15) |
|
|
or EXISTS ( |
|
|
<if test="deptId != null"> |
|
|
SELECT 1 FROM sys_dept anc |
|
|
or EXISTS ( |
|
|
WHERE (anc.`zone` = 5 OR anc.`zone` = 15) |
|
|
SELECT 1 FROM sys_dept anc |
|
|
AND FIND_IN_SET(anc.dept_id, d.ancestors) |
|
|
WHERE (anc.`zone` = 5 OR anc.`zone` = 15) |
|
|
) |
|
|
AND FIND_IN_SET(anc.dept_id, d.ancestors) |
|
|
|
|
|
) |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="deptId == null"> |
|
|
|
|
|
or (d.parent_id in (select dept_id from sys_dept where `zone` = 5 or `zone` = 15)) |
|
|
|
|
|
</if> |
|
|
) |
|
|
) |
|
|
</if> |
|
|
</if> |
|
|
and u.dept_id != 405 |
|
|
and u.dept_id != 405 |
|
|
|