Quellcode durchsuchen

过滤掉已删除机构,添加模糊查询用户组名称

hym vor 4 Jahren
Ursprung
Commit
1c3b407cda

+ 3 - 3
user_center/src/main/resources/mapper/OrgMapper.xml

@@ -278,8 +278,8 @@
     </select>
     <select id="findOrgType" resultType="com.huaxu.entity.Org">
         select a.ORG_TYPE ,  b.ORG_TYPE parentType,c.ORG_TYPE childType
-         from uims_org a left join uims_org b on a.PARENT_ORG_ID=b.ID
-        left join uims_org c on a.id=c.PARENT_ORG_ID
-        where a.id=#{id} limit 1
+         from uims_org a left join uims_org b  ON (a.PARENT_ORG_ID=b.ID and b.status=1)
+                         LEFT JOIN uims_org c ON (a.id=c.PARENT_ORG_ID and c.status=1)
+        where a.id=#{id}  limit 1
     </select>
 </mapper>

+ 1 - 1
user_center/src/main/resources/mapper/UserGroupMapper.xml

@@ -157,7 +157,7 @@
                 and TENANT_ID = #{userGroup.tenantId}
             </if>
             <if test="userGroup.groupName != null and userGroup.groupName != ''">
-                and GROUP_NAME = #{userGroup.groupName}
+                and GROUP_NAME  like concat('%', #{userGroup.groupName}, '%')
             </if>
             <if test="userGroup.groupState != null">
                 and GROUP_STATE = #{userGroup.groupState}