. "Paste As Link" and link object support in the web-client:

. Filetype icons for PSD (Photoshop) file-format
. Import, Export and Manage Space Users actions added to Forums details page
. Manage Space Users action added to Forum and Topic details pages
. Removed some obsolete JSF navigation outcomes from dialogs/faces-config
. Approx 10% performance improvement when showing large search results pages

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2582 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2006-03-27 15:46:20 +00:00
parent 9be6273144
commit 8187b27ecf
41 changed files with 1578 additions and 199 deletions

View File

@@ -16,10 +16,14 @@
*/
package org.alfresco.web.action.evaluator;
import javax.faces.context.FacesContext;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.dictionary.DictionaryService;
import org.alfresco.service.cmr.security.PermissionService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.bean.repository.Node;
import org.alfresco.web.bean.repository.Repository;
/**
* UI Action Evaluator - Checkout document.
@@ -33,9 +37,13 @@ public final class CheckoutDocEvaluator implements ActionEvaluator
*/
public boolean evaluate(Node node)
{
return (node.hasPermission(PermissionService.CHECK_OUT) &&
DictionaryService dd = Repository.getServiceRegistry(
FacesContext.getCurrentInstance()).getDictionaryService();
return dd.isSubClass(node.getType(), ContentModel.TYPE_CONTENT) &&
((node.hasPermission(PermissionService.CHECK_OUT) &&
(node.isLocked() == false &&
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false));
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false)));
}
}
/*

View File

@@ -19,9 +19,11 @@ package org.alfresco.web.action.evaluator;
import javax.faces.context.FacesContext;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.dictionary.DictionaryService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.app.Application;
import org.alfresco.web.bean.repository.Node;
import org.alfresco.web.bean.repository.Repository;
/**
* UI Action Evaluator - Edit document via CIFS.
@@ -36,19 +38,25 @@ public final class EditDocCIFSEvaluator implements ActionEvaluator
public boolean evaluate(Node node)
{
FacesContext fc = FacesContext.getCurrentInstance();
DictionaryService dd = Repository.getServiceRegistry(fc).getDictionaryService();
boolean result = false;
// if the node is inline editable, the default http behaviour should always be used
if (node.hasAspect(ContentModel.ASPECT_INLINEEDITABLE) == false &&
"webdav".equals(Application.getClientConfig(fc).getEditLinkType()))
if (dd.isSubClass(node.getType(), ContentModel.TYPE_CONTENT))
{
if (node.isWorkingCopyOwner() == true ||
(node.isLocked() == false && node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false))
if (node.hasAspect(ContentModel.ASPECT_INLINEEDITABLE) == false &&
"webdav".equals(Application.getClientConfig(fc).getEditLinkType()))
{
return true;
if (node.isWorkingCopyOwner() == true ||
(node.isLocked() == false && node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false))
{
result = true;
}
}
}
return false;
return result;
}
}
/*

View File

@@ -19,9 +19,11 @@ package org.alfresco.web.action.evaluator;
import javax.faces.context.FacesContext;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.dictionary.DictionaryService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.app.Application;
import org.alfresco.web.bean.repository.Node;
import org.alfresco.web.bean.repository.Repository;
/**
* UI Action Evaluator - Edit document via HTTP or inline edit.
@@ -36,20 +38,26 @@ public final class EditDocHttpEvaluator implements ActionEvaluator
public boolean evaluate(Node node)
{
FacesContext fc = FacesContext.getCurrentInstance();
DictionaryService dd = Repository.getServiceRegistry(fc).getDictionaryService();
boolean result = false;
// if the node is inline editable, the default http behaviour should
// always be used otherwise the configured approach is used
if (node.hasAspect(ContentModel.ASPECT_INLINEEDITABLE) == true ||
"http".equals(Application.getClientConfig(fc).getEditLinkType()))
if (dd.isSubClass(node.getType(), ContentModel.TYPE_CONTENT))
{
if (node.isWorkingCopyOwner() == true ||
(node.isLocked() == false && node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false))
if (node.hasAspect(ContentModel.ASPECT_INLINEEDITABLE) == true ||
"http".equals(Application.getClientConfig(fc).getEditLinkType()))
{
return true;
if (node.isWorkingCopyOwner() == true ||
(node.isLocked() == false && node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false))
{
result = true;
}
}
}
return false;
return result;
}
}
/*

View File

@@ -19,9 +19,11 @@ package org.alfresco.web.action.evaluator;
import javax.faces.context.FacesContext;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.dictionary.DictionaryService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.app.Application;
import org.alfresco.web.bean.repository.Node;
import org.alfresco.web.bean.repository.Repository;
/**
* UI Action Evaluator - Edit document via Webdav.
@@ -36,19 +38,25 @@ public final class EditDocWebDavEvaluator implements ActionEvaluator
public boolean evaluate(Node node)
{
FacesContext fc = FacesContext.getCurrentInstance();
DictionaryService dd = Repository.getServiceRegistry(fc).getDictionaryService();
boolean result = false;
// if the node is inline editable, the default http behaviour should always be used
if (node.hasAspect(ContentModel.ASPECT_INLINEEDITABLE) == false &&
"cifs".equals(Application.getClientConfig(fc).getEditLinkType()))
if (dd.isSubClass(node.getType(), ContentModel.TYPE_CONTENT))
{
if (node.isWorkingCopyOwner() == true ||
(node.isLocked() == false && node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false))
if (node.hasAspect(ContentModel.ASPECT_INLINEEDITABLE) == false &&
"cifs".equals(Application.getClientConfig(fc).getEditLinkType()))
{
return true;
if (node.isWorkingCopyOwner() == true ||
(node.isLocked() == false && node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false))
{
result = true;
}
}
}
return false;
return result;
}
}
/*

View File

@@ -16,9 +16,13 @@
*/
package org.alfresco.web.action.evaluator;
import javax.faces.context.FacesContext;
import org.alfresco.model.ContentModel;
import org.alfresco.service.cmr.dictionary.DictionaryService;
import org.alfresco.web.action.ActionEvaluator;
import org.alfresco.web.bean.repository.Node;
import org.alfresco.web.bean.repository.Repository;
/**
* UI Action Evaluator - Update document content.
@@ -32,9 +36,13 @@ public final class UpdateDocEvaluator implements ActionEvaluator
*/
public boolean evaluate(Node node)
{
return (node.isWorkingCopyOwner() == true ||
DictionaryService dd = Repository.getServiceRegistry(
FacesContext.getCurrentInstance()).getDictionaryService();
return dd.isSubClass(node.getType(), ContentModel.TYPE_CONTENT) &&
((node.isWorkingCopyOwner() == true ||
(node.isLocked() == false &&
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false));
node.hasAspect(ContentModel.ASPECT_WORKING_COPY) == false)));
}
}
/*