04-24-2018 02:09 AM
Newbie question:
I'm using version of Aflresco Community - 5.2.0 (r135134-b14)
I'm custmizing page of the document-details.
I would like to use categoryService in rule definition, but I do not know how to realize it.
ex)
NodeRef newCategory = categoryService.createCategory(yearsCategory, "1901");
As far as I know ,can do with Alfresco Share Javascript API.
How do I use ?
Please how should I solve this problem?
Thanks in advanced.
04-25-2018 03:08 AM
Hi Yoshida,
I think you can try Alfresco JavaScript Classification API
And there is a method called createSubCategory
Only one thing, you'll have to know the category NodeRef before you write your scripts.
Example code:
var category = classification.getCategory(nodeRef);
if (category !== null)
{
category.createSubCategory(name);
}
Explore our Alfresco products with the links below. Use labels to filter content by product module.