. Added "Content Forms" folder to the Data Dictionary on bootstrap

. Added the usual helper methods to get assoc name for the new folder

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3974 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2006-09-29 13:30:28 +00:00
parent 1ccb876188
commit 01b40b303a

View File

@@ -76,6 +76,7 @@ public class Application
private static String scriptsFolderName; private static String scriptsFolderName;
private static String guestHomeFolderName; private static String guestHomeFolderName;
private static String websitesFolderName; private static String websitesFolderName;
private static String contentFormsFolderName;
/** /**
* Private constructor to prevent instantiation of this class * Private constructor to prevent instantiation of this class
@@ -458,6 +459,22 @@ public class Application
return getWebsitesFolderName(FacesContextUtils.getRequiredWebApplicationContext(context)); return getWebsitesFolderName(FacesContextUtils.getRequiredWebApplicationContext(context));
} }
/**
* @return the WCM Content Forms folder name
*/
public static String getContentFormsFolderName(ServletContext context)
{
return getContentFormsFolderName(WebApplicationContextUtils.getRequiredWebApplicationContext(context));
}
/**
* @return the WCM Content Forms folder name
*/
public static String getContentFormsFolderName(FacesContext context)
{
return getContentFormsFolderName(FacesContextUtils.getRequiredWebApplicationContext(context));
}
/** /**
* Set the language locale for the current user context * Set the language locale for the current user context
* *
@@ -879,6 +896,24 @@ public class Application
return websitesFolderName; return websitesFolderName;
} }
/**
* Returns the WCM Content Forms folder name
*
* @param context The Spring context
* @return The WCM Content Forms folder name
*/
private static String getContentFormsFolderName(WebApplicationContext context)
{
if (contentFormsFolderName == null)
{
ImporterBootstrap bootstrap = (ImporterBootstrap)context.getBean(BEAN_IMPORTER_BOOTSTRAP);
Properties configuration = bootstrap.getConfiguration();
contentFormsFolderName = configuration.getProperty("spaces.content_forms.childname");
}
return contentFormsFolderName;
}
/** /**
* Retrieves the configured error page for the application * Retrieves the configured error page for the application
* *