| | |
| | | LEFT JOIN ywxt.sg_report_user userR ON report.id = userR.report_id |
| | | WHERE |
| | | 1 = 1 and report."STATUS" != 4 |
| | | <if test="dto.selfUnit != null and dto.selfUnit.size>0"> |
| | | and |
| | | <foreach collection="dto.selfUnit" item="item" index="index" open="(" separator="or" close=")"> |
| | | si.SELF_UNIT Like CONCAT(CONCAT('%', #{item}), '%') |
| | | </foreach> |
| | | </if> |
| | | <if test="dto.userUnit != null and dto.userUnit.size>0"> |
| | | and si.CONTROL_UNIT in |
| | | <foreach collection="dto.userUnit" item="item" index="index" open="(" separator="," close=")"> |
| | | #{item} |
| | | and |
| | | <foreach collection="dto.userUnit" item="item" index="index" open="(" separator="or" close=")"> |
| | | si.CONTROL_UNIT Like CONCAT(CONCAT('%', #{item}), '%') |
| | | </foreach> |
| | | </if> |
| | | <if test="dto.countryUnit != null and dto.countryUnit.size>0"> |