mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Merged 1.4 to HEAD
svn merge svn://svn.alfresco.com:3691/alfresco/BRANCHES/V1.4@4392 svn://svn.alfresco.com:3691/alfresco/BRANCHES/V1.4@4399 . svn resolved root\projects\repository\source\java\org\alfresco\repo\jscript\Node.java git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@4660 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -130,12 +130,20 @@ public class LinkCategoryActionExecuter extends ActionExecuterAbstractBase
|
||||
{
|
||||
// Append the category value to the existing values
|
||||
Serializable value = this.nodeService.getProperty(actionedUponNodeRef, categoryProperty);
|
||||
Collection<NodeRef> categories = DefaultTypeConverter.INSTANCE.getCollection(NodeRef.class, value);
|
||||
if (categories.contains(categoryValue) == false)
|
||||
Collection<NodeRef> categories = null;
|
||||
if (value == null)
|
||||
{
|
||||
categories.add(categoryValue);
|
||||
this.nodeService.setProperty(actionedUponNodeRef, categoryProperty, (Serializable)categories);
|
||||
categories = DefaultTypeConverter.INSTANCE.getCollection(NodeRef.class, categoryValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
categories = DefaultTypeConverter.INSTANCE.getCollection(NodeRef.class, value);
|
||||
if (categories.contains(categoryValue) == false)
|
||||
{
|
||||
categories.add(categoryValue);
|
||||
}
|
||||
}
|
||||
this.nodeService.setProperty(actionedUponNodeRef, categoryProperty, (Serializable)categories);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user