From 8d813889b4a2db8aaa25e12c62513e17b3b7ea04 Mon Sep 17 00:00:00 2001 From: Alan Davis Date: Sat, 15 Mar 2014 07:09:44 +0000 Subject: [PATCH] Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud) 64446: Merged WAT1 (4.3/Cloud) to HEAD-BUG-FIX (4.3/Cloud) 63151: Reverted most of the ACE-493 implementation, committed in r62555, as a new Get sites webscript for the site admins, implemented in r63040. Also, modified the existing tests for the Get sites webscript. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@64592 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261 --- .../repo/site/script/ScriptSiteService.java | 33 ------------------- 1 file changed, 33 deletions(-) diff --git a/source/java/org/alfresco/repo/site/script/ScriptSiteService.java b/source/java/org/alfresco/repo/site/script/ScriptSiteService.java index 281b6f4ba1..95e9d2ec21 100644 --- a/source/java/org/alfresco/repo/site/script/ScriptSiteService.java +++ b/source/java/org/alfresco/repo/site/script/ScriptSiteService.java @@ -202,39 +202,6 @@ public class ScriptSiteService extends BaseScopableProcessorExtension } } - /** - * Retrieves the sites available in the repository based on the user's access right. For example, - * Site Administrator can access all the sites (Public, MODERATED and PRIVATE). The returned list can optionally - * be filtered by name and site preset. If no filters are specified then all the available sites are returned. - * - * NOTE: If the filter starts with a * a Lucene based search will be performed, this may discover a wider range - * of results i.e. those sites that contain the search term as opposed to those that start with the search term, - * but newly created sites may not be found until the underlying search indexes are updated. - * - * @param filter inclusion filter for returned sites. Only sites whose cm:name OR cm:title - * OR cm:description start with the filter string will be returned. - * @param sitePresetFilter site preset filter - * @param size max results size crop if >0 - * @return Site[] a list of the site filtered as appropriate - */ - public Site[] getSitesAsSiteAdmin(final String filter, final String sitePresetFilter, final int size) - { - if (siteService.isSiteAdmin(AuthenticationUtil.getFullyAuthenticatedUser())) - { - return AuthenticationUtil.runAs(new AuthenticationUtil.RunAsWork() - { - public Site[] doWork() throws Exception - { - return getSites(filter, sitePresetFilter, size); - } - }, AuthenticationUtil.getAdminUserName()); - } - else - { - return getSites(filter, sitePresetFilter, size); - } - } - /** * List the sites available in the repository. The returned list can optionally be filtered by name and site * preset.