Added code to check if a group is a VRE

git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/gcube-ckan-datacatalog@129219 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Francesco Mangiacrapa 2016-06-21 15:17:24 +00:00
parent 08d8210c29
commit 9567a9dbc2
2 changed files with 3 additions and 1 deletions

View File

@ -159,6 +159,7 @@ public class GcubeCkanDataCatalogServiceImpl extends RemoteServiceServlet implem
vres+=vre+",";
}
vres = vres.substring(0, vres.length()-1); //remove last ","
vres.toLowerCase(); //A CKAN Organization ID must be lower case
}
logger.debug("List of VREs contains: " +vres);

View File

@ -50,7 +50,8 @@ public class UserUtil {
logger.info("List of VREs for "+userEMail+ " is/are: "+listOfGroups.size());
List<String> vreNames = new ArrayList<String>(listOfGroups.size());
for (GCubeGroup gCubeGroup : listOfGroups) {
vreNames.add(gCubeGroup.getGroupName());
if(groupManager.isVRE(gCubeGroup.getGroupId())) //Is it a VRE?
vreNames.add(gCubeGroup.getGroupName());
}
logger.debug("Returning VRE names: "+vreNames);
return vreNames;