数据权限的修改
This commit is contained in:
@@ -47,6 +47,10 @@
|
||||
material m ON i.material_id = m.id AND m.is_deleted = 0
|
||||
WHERE
|
||||
i.is_deleted = 0
|
||||
<!-- 组织数据权限过滤:通过Material表的organizationId过滤 -->
|
||||
<if test="query.organizationId != null and query.organizationId != ''">
|
||||
AND m.organization_id = #{query.organizationId}
|
||||
</if>
|
||||
<if test="query.ownerId != null">
|
||||
AND i.owner_id = #{query.ownerId}
|
||||
</if>
|
||||
@@ -101,6 +105,10 @@
|
||||
LEFT JOIN
|
||||
material m ON i.material_id = m.id AND m.is_deleted = 0
|
||||
WHERE i.is_deleted = 0
|
||||
<!-- 组织数据权限过滤:通过Material表的organizationId过滤 -->
|
||||
<if test="organizationId != null and organizationId != ''">
|
||||
AND m.organization_id = #{organizationId}
|
||||
</if>
|
||||
<if test="ownerId != null">
|
||||
AND i.owner_id = #{ownerId}
|
||||
</if>
|
||||
|
||||
@@ -196,7 +196,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</if>
|
||||
<if test="useStatus != null "> and use_status = #{useStatus}</if>
|
||||
<if test="organizationId != null "> and organization_id = #{organizationId}</if>
|
||||
<if test="organizationName != null "> and organization_id like concat('%', #{organizationName}, '%')</if>
|
||||
<if test="organizationName != null and organizationName != ''"> and organization_name like concat('%', #{organizationName}, '%')</if>
|
||||
<if test="checkoutPersonName != null and checkoutPersonName != ''"> and checkout_person_name like concat('%', #{checkoutPersonName}, '%')</if>
|
||||
<if test="checkoutDateStart != null">
|
||||
AND checkout_date >= #{checkoutDateStart}
|
||||
|
||||
Reference in New Issue
Block a user