mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-18 15:33:09 +00:00
[DS-242] Special groups shown for logged in user rather than for user being examined
git-svn-id: http://scm.dspace.org/svn/repo/dspace/trunk@4056 9c30dcfa-912a-0410-8fc2-9e0234be79fd
This commit is contained in:
@@ -119,7 +119,6 @@ public class Group extends DSpaceObject
|
||||
/**
|
||||
* Populate Group with eperson and group objects
|
||||
*
|
||||
* @param context
|
||||
* @throws SQLException
|
||||
*/
|
||||
public void loadData()
|
||||
@@ -473,9 +472,17 @@ public class Group extends DSpaceObject
|
||||
}
|
||||
// Also need to get all "Special Groups" user is a member of!
|
||||
// Otherwise, you're ignoring the user's membership to these groups!
|
||||
Group[] specialGroups = c.getSpecialGroups();
|
||||
for(int j=0; j<specialGroups.length;j++)
|
||||
groupIDs.add(new Integer(specialGroups[j].getID()));
|
||||
// However, we only do this is we are looking up the special groups
|
||||
// of the current user, as we cannot look up the special groups
|
||||
// of a user who is not logged in.
|
||||
if (c.getCurrentUser().getID() == e.getID())
|
||||
{
|
||||
Group[] specialGroups = c.getSpecialGroups();
|
||||
for(Group special : specialGroups)
|
||||
{
|
||||
groupIDs.add(new Integer(special.getID()));
|
||||
}
|
||||
}
|
||||
|
||||
// all the users are members of the anonymous group
|
||||
groupIDs.add(new Integer(0));
|
||||
|
@@ -28,6 +28,7 @@
|
||||
- [DS-216] Migrating items that use additional metadata schemas causes an NPE
|
||||
- [DS-219] Internal Server error - include login details of user
|
||||
- [DS-221] XMLUI 'current activity' recognises Google Chrome as Safari
|
||||
- [DS-242] Special groups shown for logged in user rather than for user being examined
|
||||
|
||||
(Larry Stone)
|
||||
- [DS-193] OAI RDF crosswalk fails when DC value is null
|
||||
|
Reference in New Issue
Block a user