mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
. Checkpoint of WCM ui work (nothing to see here, move along please, move along)
- "Websites" folder created under root of Company Home during bootstrap - Bootstrap properties and getter helper added to import-export-context & web-client - Beginnings of the Create Website wizard - Action definition added for Create Website action - Beginings of the model for avm webfolders and associated sub-structures git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3763 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -75,6 +75,7 @@ public class Application
|
||||
private static String savedSearchesFolderName;
|
||||
private static String scriptsFolderName;
|
||||
private static String guestHomeFolderName;
|
||||
private static String websitesFolderName;
|
||||
|
||||
/**
|
||||
* Private constructor to prevent instantiation of this class
|
||||
@@ -441,6 +442,22 @@ public class Application
|
||||
return getGuestHomeFolderName(FacesContextUtils.getRequiredWebApplicationContext(context));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the Websites folder name
|
||||
*/
|
||||
public static String getWebsitesFolderName(ServletContext context)
|
||||
{
|
||||
return getWebsitesFolderName(WebApplicationContextUtils.getRequiredWebApplicationContext(context));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the Websites folder name
|
||||
*/
|
||||
public static String getWebsitesFolderName(FacesContext context)
|
||||
{
|
||||
return getWebsitesFolderName(FacesContextUtils.getRequiredWebApplicationContext(context));
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the language locale for the current user context
|
||||
*
|
||||
@@ -827,7 +844,7 @@ public class Application
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the Guest Home folder name name
|
||||
* Returns the Guest Home folder name
|
||||
*
|
||||
* @param context The spring context
|
||||
* @return The Guest Home folder name
|
||||
@@ -844,10 +861,28 @@ public class Application
|
||||
return guestHomeFolderName;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the Websites folder name
|
||||
*
|
||||
* @param context The Spring context
|
||||
* @return The Websites folder name
|
||||
*/
|
||||
private static String getWebsitesFolderName(WebApplicationContext context)
|
||||
{
|
||||
if (websitesFolderName == null)
|
||||
{
|
||||
ImporterBootstrap bootstrap = (ImporterBootstrap)context.getBean(BEAN_IMPORTER_BOOTSTRAP);
|
||||
Properties configuration = bootstrap.getConfiguration();
|
||||
websitesFolderName = configuration.getProperty("spaces.wcm.childname");
|
||||
}
|
||||
|
||||
return websitesFolderName;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves the configured error page for the application
|
||||
*
|
||||
* @param context The Spring contexr
|
||||
* @param context The Spring context
|
||||
* @return The configured error page or null if the configuration is missing
|
||||
*/
|
||||
private static String getErrorPage(WebApplicationContext context)
|
||||
|
@@ -1560,7 +1560,7 @@ public class BrowseBean implements IContextListener
|
||||
/**
|
||||
* Perform navigation to the browse screen if it is not already the current View
|
||||
*/
|
||||
private void navigateBrowseScreen()
|
||||
public void navigateBrowseScreen()
|
||||
{
|
||||
String outcome = null;
|
||||
|
||||
|
@@ -334,12 +334,12 @@ public abstract class BaseContentWizard extends BaseWizardBean
|
||||
protected void saveContent(File fileContent, String strContent) throws Exception
|
||||
{
|
||||
// get the node ref of the node that will contain the content
|
||||
NodeRef containerNodeRef = this.getContainerNodeRef();
|
||||
NodeRef containerNodeRef = getContainerNodeRef();
|
||||
|
||||
FileInfo fileInfo =
|
||||
this.fileFolderService.create(containerNodeRef,
|
||||
this.fileName,
|
||||
Repository.resolveToQName(this.objectType));
|
||||
FileInfo fileInfo = this.fileFolderService.create(
|
||||
containerNodeRef,
|
||||
this.fileName,
|
||||
Repository.resolveToQName(this.objectType));
|
||||
NodeRef fileNodeRef = fileInfo.getNodeRef();
|
||||
|
||||
// set the author aspect
|
||||
|
@@ -278,13 +278,12 @@ public abstract class BaseDialogBean implements IDialogBean
|
||||
FacesContext.getCurrentInstance(), getErrorMessageId()),
|
||||
exception.getMessage());
|
||||
}
|
||||
|
||||
protected NodeRef getContainerNodeRef()
|
||||
{
|
||||
|
||||
protected NodeRef getContainerNodeRef()
|
||||
{
|
||||
String nodeId = this.navigator.getCurrentNodeId();
|
||||
return (nodeId == null
|
||||
? this.nodeService.getRootNode(Repository.getStoreRef())
|
||||
: new NodeRef(Repository.getStoreRef(), nodeId));
|
||||
}
|
||||
|
||||
? this.nodeService.getRootNode(Repository.getStoreRef())
|
||||
: new NodeRef(Repository.getStoreRef(), nodeId));
|
||||
}
|
||||
}
|
||||
|
@@ -16,41 +16,24 @@
|
||||
*/
|
||||
package org.alfresco.web.templating;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.ResourceBundle;
|
||||
|
||||
import javax.faces.context.FacesContext;
|
||||
import javax.faces.event.ValueChangeEvent;
|
||||
import javax.faces.model.SelectItem;
|
||||
|
||||
import org.alfresco.config.Config;
|
||||
import org.alfresco.config.ConfigElement;
|
||||
import org.alfresco.config.ConfigService;
|
||||
import org.alfresco.repo.content.MimetypeMap;
|
||||
import org.alfresco.web.app.AlfrescoNavigationHandler;
|
||||
import org.alfresco.web.app.Application;
|
||||
import org.alfresco.web.bean.repository.Node;
|
||||
import org.alfresco.web.data.IDataContainer;
|
||||
import org.alfresco.web.data.QuickSort;
|
||||
import org.alfresco.web.templating.*;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import java.io.OutputStreamWriter;
|
||||
|
||||
import org.alfresco.model.ContentModel;
|
||||
import org.alfresco.service.cmr.avm.*;
|
||||
import org.alfresco.service.cmr.model.FileInfo;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
import org.alfresco.service.cmr.repository.ContentReader;
|
||||
import org.alfresco.service.cmr.repository.ContentWriter;
|
||||
import java.io.OutputStreamWriter;
|
||||
import org.alfresco.web.app.servlet.FacesHelper;
|
||||
import org.alfresco.repo.avm.AVMContext;
|
||||
import org.alfresco.service.cmr.avm.AVMExistsException;
|
||||
import org.alfresco.service.cmr.avm.AVMNotFoundException;
|
||||
import org.alfresco.service.cmr.avm.AVMService;
|
||||
import org.alfresco.service.cmr.model.FileFolderService;
|
||||
import org.alfresco.service.cmr.repository.*;
|
||||
import org.alfresco.service.cmr.model.FileInfo;
|
||||
import org.alfresco.service.cmr.repository.ChildAssociationRef;
|
||||
import org.alfresco.service.cmr.repository.ContentReader;
|
||||
import org.alfresco.service.cmr.repository.ContentService;
|
||||
import org.alfresco.service.cmr.repository.ContentWriter;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
import org.alfresco.service.cmr.repository.NodeService;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.w3c.dom.Document;
|
||||
import org.alfresco.repo.avm.*;
|
||||
|
||||
/**
|
||||
* temporary home of generate and regenerate functionality until i figure
|
||||
|
Reference in New Issue
Block a user