diff --git a/config/alfresco/action-services-context.xml b/config/alfresco/action-services-context.xml index 9a63697a50..f420d37375 100644 --- a/config/alfresco/action-services-context.xml +++ b/config/alfresco/action-services-context.xml @@ -147,10 +147,40 @@ - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/config/alfresco/messages/action-config.properties b/config/alfresco/messages/action-config.properties index 8fdbf0cd38..735f578a1d 100644 --- a/config/alfresco/messages/action-config.properties +++ b/config/alfresco/messages/action-config.properties @@ -1,12 +1,12 @@ -# Action constraints -compare-operations.equals=Equals -compare-operations.contains=Contains -compare-operations.begins=Begins With -compare-operations.ends=Ends With -compare-operations.greater_than=Greater Than -compare-operations.greater_than_equal=Greater Than Or Equal To -compare-operations.less_than=Less Than -compare-operations.less_than_equal=Less Than Or Equal To +# Action parameter constraints +ac-compare-operations.equals=Equals +ac-compare-operations.contains=Contains +ac-compare-operations.begins=Begins With +ac-compare-operations.ends=Ends With +ac-compare-operations.greater_than=Greater Than +ac-compare-operations.greater_than_equal=Greater Than Or Equal To +ac-compare-operations.less_than=Less Than +ac-compare-operations.less_than_equal=Less Than Or Equal To # Action conditions diff --git a/source/java/org/alfresco/repo/action/constraint/ActionParameterConstraintTest.java b/source/java/org/alfresco/repo/action/constraint/ActionParameterConstraintTest.java index 2ab396363a..9f06070d26 100644 --- a/source/java/org/alfresco/repo/action/constraint/ActionParameterConstraintTest.java +++ b/source/java/org/alfresco/repo/action/constraint/ActionParameterConstraintTest.java @@ -39,7 +39,7 @@ import org.alfresco.util.BaseSpringTest; */ public class ActionParameterConstraintTest extends BaseSpringTest { - private static final String COMPARE_OP = "compare-operations"; + private static final String COMPARE_OP = "ac-compare-operations"; private ActionService actionService; @@ -84,4 +84,29 @@ public class ActionParameterConstraintTest extends BaseSpringTest System.out.println(entry.getKey() + " - " + entry.getValue()); } } + + public void testConstraints() + { + testConstraint("ac-aspects"); + testConstraint("ac-types"); + testConstraint("ac-properties"); + testConstraint("ac-mimetypes"); + testConstraint("ac-email-templates"); + testConstraint("ac-scripts"); + } + + private void testConstraint(String name) + { + ParameterConstraint constraint = actionService.getParameterConstraint(name); + assertNotNull(constraint); + assertEquals(name, constraint.getName()); + + Map values = constraint.getAllowableValues(); + assertTrue(values.size()>0); + System.out.println("== " + name + " ==\n"); + for (Map.Entry entry : values.entrySet()) + { + System.out.println(entry.getKey() + " - " + entry.getValue()); + } + } } diff --git a/source/java/org/alfresco/repo/action/constraint/AspectParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/AspectParameterConstraint.java new file mode 100644 index 0000000000..79295d4a0d --- /dev/null +++ b/source/java/org/alfresco/repo/action/constraint/AspectParameterConstraint.java @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2009-2009 Alfresco Software Limited. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + * As a special exception to the terms and conditions of version 2.0 of + * the GPL, you may redistribute this Program in connection with Free/Libre + * and Open Source Software ("FLOSS") applications as described in Alfresco's + * FLOSS exception. You should have received a copy of the text describing + * the FLOSS exception, and it is also available here: + * http://www.alfresco.com/legal/licensing" + */ + +package org.alfresco.repo.action.constraint; + +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; + +import org.alfresco.service.cmr.dictionary.AspectDefinition; +import org.alfresco.service.cmr.dictionary.DictionaryService; +import org.alfresco.service.namespace.QName; + +/** + * Type parameter constraint + * + * @author Roy Wetherall + */ +public class AspectParameterConstraint extends BaseParameterConstraint +{ + /** Name constant */ + public static final String NAME = "ac-aspects"; + + private DictionaryService dictionaryService; + + public void setDictionaryService(DictionaryService dictionaryService) + { + this.dictionaryService = dictionaryService; + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() + */ + protected Map getAllowableValuesImpl() + { + Collection aspects = dictionaryService.getAllAspects(); + Map result = new HashMap(aspects.size()); + for (QName aspect : aspects) + { + AspectDefinition aspectDef = dictionaryService.getAspect(aspect); + if (aspectDef != null && aspectDef.getTitle() != null) + { + result.put(aspect.toPrefixString(), aspectDef.getTitle()); + } + } + return result; + } + + +} diff --git a/source/java/org/alfresco/repo/action/constraint/BaseParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/BaseParameterConstraint.java index dca7e26416..a206abcb12 100644 --- a/source/java/org/alfresco/repo/action/constraint/BaseParameterConstraint.java +++ b/source/java/org/alfresco/repo/action/constraint/BaseParameterConstraint.java @@ -25,9 +25,12 @@ package org.alfresco.repo.action.constraint; +import java.util.Map; + import org.alfresco.repo.action.RuntimeActionService; import org.alfresco.service.cmr.action.ParameterConstraint; import org.springframework.beans.factory.BeanNameAware; +import org.springframework.extensions.surf.util.I18NUtil; /** * Base implementation of a parameter constraint @@ -43,6 +46,9 @@ public abstract class BaseParameterConstraint implements ParameterConstraint, /** Runtime action service */ protected RuntimeActionService actionService; + /** Map of allowable values */ + protected Map allowableValues; + /** * Init method */ @@ -76,4 +82,60 @@ public abstract class BaseParameterConstraint implements ParameterConstraint, { this.name = name; } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() + */ + public Map getAllowableValues() + { + if (this.allowableValues == null) + { + this.allowableValues = getAllowableValuesImpl(); + } + + return this.allowableValues; + } + + /** + * Gets the list of allowable values, calculating them every time it is called. + * + * @return Map map of allowable values + */ + protected abstract Map getAllowableValuesImpl(); + + /** + * Get the I18N display label for a particular key + * + * @param key + * @return String I18N value + */ + protected String getI18NLabel(String key) + { + String result = key.toString(); + StringBuffer longKey = new StringBuffer(name). + append("."). + append(key.toString().toLowerCase()); + String i18n = I18NUtil.getMessage(longKey.toString()); + if (i18n != null) + { + result = i18n; + } + return result; + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getValueDisplayLabel(java.io.Serializable) + */ + public String getValueDisplayLabel(String value) + { + return getAllowableValues().get(value); + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#isValidValue(java.io.Serializable) + */ + public boolean isValidValue(String value) + { + return getAllowableValues().containsKey(value); + } } diff --git a/source/java/org/alfresco/repo/action/constraint/EnumParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/EnumParameterConstraint.java index f0a3b3abf9..8e1d5dd7c2 100644 --- a/source/java/org/alfresco/repo/action/constraint/EnumParameterConstraint.java +++ b/source/java/org/alfresco/repo/action/constraint/EnumParameterConstraint.java @@ -29,7 +29,6 @@ import java.util.HashMap; import java.util.Map; import org.alfresco.error.AlfrescoRuntimeException; -import org.springframework.extensions.surf.util.I18NUtil; /** * Enumerated type parameter constraint @@ -44,9 +43,6 @@ public class EnumParameterConstraint extends BaseParameterConstraint /** Enum clss */ private Class enumClass; - /** Map of allowable values */ - private Map allowableValues; - /** * Set the enum class name * @@ -60,27 +56,24 @@ public class EnumParameterConstraint extends BaseParameterConstraint /** * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() */ - public Map getAllowableValues() - { - if (this.allowableValues == null) - { - // Get the enum class - Class enumClass = getEnumClass(); - - Object[] enumValues = enumClass.getEnumConstants(); - this.allowableValues = new HashMap(enumValues.length); - - for (Object enumValue : enumValues) - { - // Look up the I18N value - String displayLabel = getI18NLabel(enumClass.getName(), enumValue); - - // Add to the map of allowed values - this.allowableValues.put(enumValue.toString(), displayLabel); - } - } + protected Map getAllowableValuesImpl() + { + // Get the enum class + Class enumClass = getEnumClass(); + + Object[] enumValues = enumClass.getEnumConstants(); + Map allowableValues = new HashMap(enumValues.length); - return this.allowableValues; + for (Object enumValue : enumValues) + { + // Look up the I18N value + String displayLabel = getI18NLabel(enumValue.toString()); + + // Add to the map of allowed values + allowableValues.put(enumValue.toString(), displayLabel); + } + + return allowableValues; } /** @@ -116,41 +109,4 @@ public class EnumParameterConstraint extends BaseParameterConstraint } return this.enumClass; } - - /** - * Get the I18N display label for a particular enum value - * - * @param enumClassName - * @param enumValue - * @return - */ - private String getI18NLabel(String enumClassName, Object enumValue) - { - String result = enumValue.toString(); - StringBuffer key = new StringBuffer(name). - append("."). - append(enumValue.toString().toLowerCase()); - String i18n = I18NUtil.getMessage(key.toString()); - if (i18n != null) - { - result = i18n; - } - return result; - } - - /** - * @see org.alfresco.service.cmr.action.ParameterConstraint#getValueDisplayLabel(java.io.Serializable) - */ - public String getValueDisplayLabel(String value) - { - return getAllowableValues().get(value); - } - - /** - * @see org.alfresco.service.cmr.action.ParameterConstraint#isValidValue(java.io.Serializable) - */ - public boolean isValidValue(String value) - { - return getAllowableValues().containsKey(value); - } } diff --git a/source/java/org/alfresco/repo/action/constraint/FolderContentsParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/FolderContentsParameterConstraint.java new file mode 100644 index 0000000000..5d437a639a --- /dev/null +++ b/source/java/org/alfresco/repo/action/constraint/FolderContentsParameterConstraint.java @@ -0,0 +1,121 @@ +/* + * Copyright (C) 2009-2009 Alfresco Software Limited. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + * As a special exception to the terms and conditions of version 2.0 of + * the GPL, you may redistribute this Program in connection with Free/Libre + * and Open Source Software ("FLOSS") applications as described in Alfresco's + * FLOSS exception. You should have received a copy of the text describing + * the FLOSS exception, and it is also available here: + * http://www.alfresco.com/legal/licensing" + */ + +package org.alfresco.repo.action.constraint; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.alfresco.error.AlfrescoRuntimeException; +import org.alfresco.model.ContentModel; +import org.alfresco.service.cmr.dictionary.DictionaryService; +import org.alfresco.service.cmr.repository.ChildAssociationRef; +import org.alfresco.service.cmr.repository.NodeRef; +import org.alfresco.service.cmr.repository.NodeService; +import org.alfresco.service.cmr.repository.StoreRef; +import org.alfresco.service.cmr.search.ResultSet; +import org.alfresco.service.cmr.search.SearchService; +import org.alfresco.service.namespace.QName; +import org.alfresco.service.namespace.RegexQNamePattern; + +/** + * Folder contents parameter constraint + * + * @author Roy Wetherall + */ +public class FolderContentsParameterConstraint extends BaseParameterConstraint +{ + private NodeService nodeService; + + private SearchService searchService; + + private DictionaryService dictionaryService; + + private String searchPath; + + public void setNodeService(NodeService nodeService) + { + this.nodeService = nodeService; + } + + public void setSearchService(SearchService searchService) + { + this.searchService = searchService; + } + + public void setSearchPath(String searchPath) + { + this.searchPath = searchPath; + } + + public void setDictionaryService(DictionaryService dictionaryService) + { + this.dictionaryService = dictionaryService; + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() + */ + protected Map getAllowableValuesImpl() + { + ResultSet resultSet = searchService.query( + StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, + SearchService.LANGUAGE_LUCENE, + "PATH:\"" + searchPath + "\""); + NodeRef rootFolder = null; + if (resultSet.length() == 0) + { + throw new AlfrescoRuntimeException("The path '" + searchPath + "' did not return any results."); + } + else + { + rootFolder = resultSet.getNodeRef(0); + } + + Map result = new HashMap(23); + buildMap(result, rootFolder); + return result; + } + + private void buildMap(Map result, NodeRef folderNodeRef) + { + List assocs = nodeService.getChildAssocs(folderNodeRef, ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL); + for (ChildAssociationRef assoc : assocs) + { + NodeRef nodeRef = assoc.getChildRef(); + QName className = nodeService.getType(nodeRef); + if (dictionaryService.isSubClass(className, ContentModel.TYPE_CONTENT) == true) + { + result.put(nodeRef.toString(), + (String)nodeService.getProperty(nodeRef, ContentModel.PROP_TITLE)); + } + else if (dictionaryService.isSubClass(className, ContentModel.TYPE_FOLDER) == true) + { + buildMap(result, nodeRef); + } + } + } +} diff --git a/source/java/org/alfresco/repo/action/constraint/MimetypeParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/MimetypeParameterConstraint.java new file mode 100644 index 0000000000..56f2e07b6b --- /dev/null +++ b/source/java/org/alfresco/repo/action/constraint/MimetypeParameterConstraint.java @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2009-2009 Alfresco Software Limited. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + * As a special exception to the terms and conditions of version 2.0 of + * the GPL, you may redistribute this Program in connection with Free/Libre + * and Open Source Software ("FLOSS") applications as described in Alfresco's + * FLOSS exception. You should have received a copy of the text describing + * the FLOSS exception, and it is also available here: + * http://www.alfresco.com/legal/licensing" + */ + +package org.alfresco.repo.action.constraint; + +import java.util.Map; + +import org.alfresco.repo.content.MimetypeMap; + +/** + * Mimetype parameter constraint + * + * @author Roy Wetherall + */ +public class MimetypeParameterConstraint extends BaseParameterConstraint +{ + /** Name constant */ + public static final String NAME = "ac-mimetypes"; + + /** Mimetype map */ + private MimetypeMap mimetypeMap; + + /** + * Sets the mimetype map + * + * @param mimetypeMap + */ + public void setMimetypeMap(MimetypeMap mimetypeMap) + { + this.mimetypeMap = mimetypeMap; + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() + */ + protected Map getAllowableValuesImpl() + { + return mimetypeMap.getDisplaysByMimetype(); + } + + +} diff --git a/source/java/org/alfresco/repo/action/constraint/PropertyParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/PropertyParameterConstraint.java new file mode 100644 index 0000000000..7d6fe0d326 --- /dev/null +++ b/source/java/org/alfresco/repo/action/constraint/PropertyParameterConstraint.java @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2009-2009 Alfresco Software Limited. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + * As a special exception to the terms and conditions of version 2.0 of + * the GPL, you may redistribute this Program in connection with Free/Libre + * and Open Source Software ("FLOSS") applications as described in Alfresco's + * FLOSS exception. You should have received a copy of the text describing + * the FLOSS exception, and it is also available here: + * http://www.alfresco.com/legal/licensing" + */ + +package org.alfresco.repo.action.constraint; + +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; + +import org.alfresco.service.cmr.dictionary.DictionaryService; +import org.alfresco.service.cmr.dictionary.PropertyDefinition; +import org.alfresco.service.namespace.QName; + +/** + * Type parameter constraint + * + * @author Roy Wetherall + */ +public class PropertyParameterConstraint extends BaseParameterConstraint +{ + /** Name constant */ + public static final String NAME = "ac-properties"; + + private DictionaryService dictionaryService; + + public void setDictionaryService(DictionaryService dictionaryService) + { + this.dictionaryService = dictionaryService; + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() + */ + protected Map getAllowableValuesImpl() + { + Collection properties = dictionaryService.getAllProperties(null); + Map result = new HashMap(properties.size()); + for (QName property : properties) + { + PropertyDefinition propertyDef = dictionaryService.getProperty(property); + if (propertyDef != null && propertyDef.getTitle() != null) + { + result.put(property.toPrefixString(), propertyDef.getTitle()); + } + } + return result; + } + + +} diff --git a/source/java/org/alfresco/repo/action/constraint/TypeParameterConstraint.java b/source/java/org/alfresco/repo/action/constraint/TypeParameterConstraint.java new file mode 100644 index 0000000000..5985bdb21c --- /dev/null +++ b/source/java/org/alfresco/repo/action/constraint/TypeParameterConstraint.java @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2009-2009 Alfresco Software Limited. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + * As a special exception to the terms and conditions of version 2.0 of + * the GPL, you may redistribute this Program in connection with Free/Libre + * and Open Source Software ("FLOSS") applications as described in Alfresco's + * FLOSS exception. You should have received a copy of the text describing + * the FLOSS exception, and it is also available here: + * http://www.alfresco.com/legal/licensing" + */ + +package org.alfresco.repo.action.constraint; + +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; + +import org.alfresco.service.cmr.dictionary.DictionaryService; +import org.alfresco.service.cmr.dictionary.TypeDefinition; +import org.alfresco.service.namespace.QName; + +/** + * Type parameter constraint + * + * @author Roy Wetherall + */ +public class TypeParameterConstraint extends BaseParameterConstraint +{ + /** Name constant */ + public static final String NAME = "ac-types"; + + private DictionaryService dictionaryService; + + public void setDictionaryService(DictionaryService dictionaryService) + { + this.dictionaryService = dictionaryService; + } + + /** + * @see org.alfresco.service.cmr.action.ParameterConstraint#getAllowableValues() + */ + protected Map getAllowableValuesImpl() + { + Collection types = dictionaryService.getAllTypes(); + Map result = new HashMap(types.size()); + for (QName type : types) + { + TypeDefinition typeDef = dictionaryService.getType(type); + if (typeDef != null && typeDef.getTitle() != null) + { + result.put(type.toPrefixString(), typeDef.getTitle()); + } + } + return result; + } + + +} diff --git a/source/java/org/alfresco/repo/action/evaluator/ComparePropertyValueEvaluator.java b/source/java/org/alfresco/repo/action/evaluator/ComparePropertyValueEvaluator.java index cc5cd67f6e..69a5e20ee9 100644 --- a/source/java/org/alfresco/repo/action/evaluator/ComparePropertyValueEvaluator.java +++ b/source/java/org/alfresco/repo/action/evaluator/ComparePropertyValueEvaluator.java @@ -34,7 +34,6 @@ import org.alfresco.repo.action.ParameterDefinitionImpl; import org.alfresco.repo.action.evaluator.compare.ComparePropertyValueOperation; import org.alfresco.repo.action.evaluator.compare.ContentPropertyName; import org.alfresco.repo.action.evaluator.compare.PropertyValueComparator; -import org.alfresco.repo.node.integrity.IntegrityChecker; import org.alfresco.service.cmr.action.ActionCondition; import org.alfresco.service.cmr.action.ActionServiceException; import org.alfresco.service.cmr.action.ParameterDefinition; @@ -42,7 +41,6 @@ import org.alfresco.service.cmr.dictionary.DataTypeDefinition; import org.alfresco.service.cmr.dictionary.DictionaryService; import org.alfresco.service.cmr.dictionary.PropertyDefinition; import org.alfresco.service.cmr.repository.ContentData; -import org.alfresco.service.cmr.repository.ContentReader; import org.alfresco.service.cmr.repository.ContentService; import org.alfresco.service.cmr.repository.NodeRef; import org.alfresco.service.cmr.repository.NodeService; @@ -164,7 +162,7 @@ public class ComparePropertyValueEvaluator extends ActionConditionEvaluatorAbstr paramList.add(new ParameterDefinitionImpl(PARAM_PROPERTY, DataTypeDefinition.QNAME, false, getParamDisplayLabel(PARAM_PROPERTY))); paramList.add(new ParameterDefinitionImpl(PARAM_CONTENT_PROPERTY, DataTypeDefinition.TEXT, false, getParamDisplayLabel(PARAM_CONTENT_PROPERTY))); paramList.add(new ParameterDefinitionImpl(PARAM_VALUE, DataTypeDefinition.ANY, true, getParamDisplayLabel(PARAM_VALUE))); - paramList.add(new ParameterDefinitionImpl(PARAM_OPERATION, DataTypeDefinition.TEXT, false, getParamDisplayLabel(PARAM_OPERATION), false, "compare-operations")); + paramList.add(new ParameterDefinitionImpl(PARAM_OPERATION, DataTypeDefinition.TEXT, false, getParamDisplayLabel(PARAM_OPERATION), false, "ac-compare-operations")); } /** diff --git a/source/java/org/alfresco/repo/action/evaluator/HasAspectEvaluator.java b/source/java/org/alfresco/repo/action/evaluator/HasAspectEvaluator.java index ec918fc99f..f58b0fd06f 100644 --- a/source/java/org/alfresco/repo/action/evaluator/HasAspectEvaluator.java +++ b/source/java/org/alfresco/repo/action/evaluator/HasAspectEvaluator.java @@ -86,7 +86,7 @@ public class HasAspectEvaluator extends ActionConditionEvaluatorAbstractBase @Override protected void addParameterDefinitions(List paramList) { - paramList.add(new ParameterDefinitionImpl(PARAM_ASPECT, DataTypeDefinition.QNAME, true, getParamDisplayLabel(PARAM_ASPECT))); + paramList.add(new ParameterDefinitionImpl(PARAM_ASPECT, DataTypeDefinition.QNAME, true, getParamDisplayLabel(PARAM_ASPECT), false, "ac-aspects")); } }