Merged API-STRIKES-BACK (5.2.0) to HEAD (5.2)

125537 jvonka: RA-779 / RA-780: Sites API - additional tests, also add skipConfiguration (pending open question)


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@127534 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Jamal Kaabi-Mofrad
2016-06-02 21:18:56 +00:00
parent fdfe515a29
commit de7b79f001
3 changed files with 82 additions and 60 deletions

View File

@@ -65,4 +65,5 @@ public interface Sites
String PARAM_PERMANENT = "permanent";
String PARAM_SKIP_ADDTOFAVORITES = "skipAddToFavorites";
String PARAM_SKIP_SURF_CONFIGURATION = "skipConfiguration";
}

View File

@@ -864,7 +864,7 @@ public class SitesImpl implements Sites
/**
* Create default/preset (Share) site - with DocLib container/component
* Create default/fixed preset (Share) site - with DocLib container/component
*
* @param site
* @return
@@ -893,8 +893,13 @@ public class SitesImpl implements Sites
String siteId = siteInfo.getShortName();
// import default surf config
importSite(siteId);
// default false (if not provided)
boolean skipShareSurfConfig = Boolean.valueOf(parameters.getParameter(PARAM_SKIP_SURF_CONFIGURATION));
if (skipShareSurfConfig == false)
{
// import default/fixed preset Share surf config
importSite(siteId);
}
// pre-create doclib
siteService.createContainer(siteId, SiteService.DOCUMENT_LIBRARY, ContentModel.TYPE_FOLDER, null);