Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Jignesh Vachhani
get users by site role id
February 27, 2013 6:34 AM
Answer

Jignesh Vachhani

Rank: Liferay Master

Posts: 785

Join Date: March 10, 2008

Recent Posts

Hi All

Does any body knows how to fetch users by site role id ?
I know there is one method available in UserLocalServiceImpl but it returns user for regular role id only.
Jignesh Vachhani
RE: get users by site role id
February 27, 2013 10:12 PM
Answer

Jignesh Vachhani

Rank: Liferay Master

Posts: 785

Join Date: March 10, 2008

Recent Posts

Guys it can be done using


userGroupRoles = UserGroupRoleLocalServiceUtil.getUserGroupRolesByGroupAndRole(userId, groupId);

for(UserGroupRole userGroupRole:userGroupRoles){
User oneUser=userGroupRole.getUser();
}