09-21-2016 04:50 AM
Hi,
I have a requirement where a node can have key / value paired properties, first I thought about the aspects but the properties which client want is bit different !!
What they want is a property where they can have any key and value property (key can be anything).
so I have created a web script which will add the custom property like this
Map<QName, Serializable> propsMap = new HashMap<QName, Serializable>(); propsMap.put(QName.createQName("key"), "value");
nodeService.addProperties(new NodeRef("some node ref"), propsMap);
I was successful creating properties like this !!, but they want to search based on these properties
After that I have done little bit research and came to know that, In order to perform search operation the property should be present in alfresco dictionary model
Now my question is, Is there any way I can have properties (which are specific to each node and not available to other nodes) and perform search operation ??
Any help would be great !!
10-13-2016 12:17 PM
No. The properties need to be registered properly via your custom model in order to be searchable.
but: you could define a property and put your key and value as value in there.
propsMap.put(QName.createQName("your_fixed_key"), key + ":" + value);
10-13-2016 12:17 PM
No. The properties need to be registered properly via your custom model in order to be searchable.
but: you could define a property and put your key and value as value in there.
propsMap.put(QName.createQName("your_fixed_key"), key + ":" + value);
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.