Jelajahi Sumber

修改角色查询用户的方法

hym 4 tahun lalu
induk
melakukan
72ccc31cbf
1 mengubah file dengan 4 tambahan dan 2 penghapusan
  1. 4 2
      user_center/src/main/resources/mapper/RoleMapper.xml

+ 4 - 2
user_center/src/main/resources/mapper/RoleMapper.xml

@@ -280,13 +280,15 @@
          a.update_by as "updateBy",
          com.org_name as "companyOrgName" ,
          dep.org_name as "deptOrgName",
-         userrole.id as roleId
+         userrole.role_id as roleId
      </sql>
     <select id="findUsersByRole" resultType="com.huaxu.entity.UserEntity">
         select 	<include refid="userColumns"/>
          from  uims_user a
         <include refid="sysAreaJoins"/>
-        where a.tenant_id=#{role.tenantId} and userrole.status=1 and a.status=1
+        where a.tenant_id=#{role.tenantId}
+          and userrole.role_id=#{role.id}
+          and userrole.status=1 and a.status=1
     </select>
     <update id="deleteRoleUser">
         update uims_user_role set status=0 where ROLE_ID=#{id}