private List<String> searchTrashedResources(String resourceTypeCode, String text, UserDetails currentUser) throws ApsSystemException {
List<String> allowedGroups = new ArrayList<String>();
List<Group> userGroups = this.getAuthorizationManager().getGroupsOfUser(currentUser);
for (int i=0; i<userGroups.size(); i++) {
Group group = userGroups.get(i);
if (group.getName().equals(Group.ADMINS_GROUP_NAME)) {
allowedGroups.clear();
break;
} else {
allowedGroups.add(group.getName());
}
}
List<String> resourcesId = this.getTrashedResourceManager().searchTrashedResourceIds(resourceTypeCode, text, allowedGroups);
return resourcesId;
}