- adding aspect to webapp nodes to differentiate them from ordinary folders in the avm_webapps directory

- refactoring of generate and regenerate calls to take a FormInstanceData object
- adding in support for overriding step title and description properties in wizards so as to be able to format them with parameters
- making the step descriptions in create form wizard reiterate the form name so as to give the user better context
- displaying avm task resources in the manage task screen.  still need to get actions working and clean this up a bit.
- making output path patterns sandbox relative
- refactored utility method for combining avm paths sensitive to webapp vs sandbox relative paths.
- adding a default description for generated renditions

todo:
- cleanup some usage of AVMNode from ManageTaskBean
- get actions to appear in manage task screen
- add a multi value property to the web project for all its webapps
- properly use overridden values for forms from the web project settings

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@4687 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Ariel Backenroth
2006-12-21 20:34:00 +00:00
parent ef3b4f793c
commit 2190c4f29d
26 changed files with 544 additions and 267 deletions

View File

@@ -16,8 +16,6 @@
*/
package org.alfresco.web.forms;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import javax.faces.context.FacesContext;
import org.alfresco.model.ContentModel;
import org.alfresco.model.WCMAppModel;
@@ -64,15 +62,22 @@ public class RenditionImpl
nodeService.getProperty(this.nodeRef, ContentModel.PROP_NAME);
}
/** the path relative to the containing webapp */
/** the description of this rendition */
public String getDescription()
{
final NodeService nodeService = this.getServiceRegistry().getNodeService();
return (String)
nodeService.getProperty(this.nodeRef, ContentModel.PROP_DESCRIPTION);
}
public String getWebappRelativePath()
{
final String path = AVMNodeConverter.ToAVMVersionPath(this.nodeRef).getSecond();
final String p = ("[^:]+:/" + AVMConstants.DIR_APPBASE +
"/" + AVMConstants.DIR_WEBAPPS +
"/[^/]+(.*)/" + this.getName());
final Matcher m = Pattern.compile(p).matcher(path);
return m.matches() && m.group(1).length() != 0 ? m.group(1) : "/";
return AVMConstants.getWebappRelativePath(this.getPath());
}
public String getSandboxRelativePath()
{
return AVMConstants.getSandboxRelativePath(this.getPath());
}
public FormInstanceData getPrimaryFormInstanceData()
@@ -115,7 +120,7 @@ public class RenditionImpl
public String getUrl()
{
return AVMConstants.buildAVMAssetUrl(AVMNodeConverter.ToAVMVersionPath(this.nodeRef).getSecond());
return AVMConstants.buildAVMAssetUrl(this.getPath());
}
public String getFileTypeImage()