供应商查询 sql 修改

This commit is contained in:
YY
2025-07-03 19:17:25 +08:00
parent 9e238c8597
commit 1a52fa54b9

View File

@ -974,7 +974,7 @@
JOIN cosco_blacklist cb ON cb.id = b.blacklist_id JOIN cosco_blacklist cb ON cb.id = b.blacklist_id
WHERE b.supplier_id = csb.id WHERE b.supplier_id = csb.id
AND cb.approve_status = 1 AND cb.approve_status = 1
AND cb.restore_approve_status != 1 AND (cb.restore_approve_status is null or cb.restore_approve_status!=1)
-- 添加当前部门及上级部门id -- 添加当前部门及上级部门id
<if test="vo.blackListDept != null and vo.blackListDept.size > 0"> <if test="vo.blackListDept != null and vo.blackListDept.size > 0">
AND cb.dept_id IN AND cb.dept_id IN
@ -983,6 +983,7 @@
</foreach> </foreach>
</if> </if>
) )
and cas.access_status=1
<if test="vo.name!=null and vo.name!=''"> <if test="vo.name!=null and vo.name!=''">
and csb.name like concat('%',#{vo.name},'%') and csb.name like concat('%',#{vo.name},'%')
</if> </if>