AnsweredAssumed Answered

How to access a node's associations in client-side JavaScript?

Question asked by goldmar on Jul 6, 2013
Latest reply on Jul 8, 2013 by goldmar
Hi guys,

I'm trying to add a feature to Alfresco Share which enables me to set custom folder icons (thumbnails). So far I've added a new subtype to cm:folder which adds a new association to the data model. I can now convert a cm:folder to the subtype and then add the association from the Share user interface.

However, in order to change the displayed folder thumbnail, I need to change renderCellThumbnail in documentlist-view-detailed.js. My problem now is: How do I access the node's associations in client-side JavaScript?

In the server-side JavaScript API (http://wiki.alfresco.com/wiki/4.0_JavaScript_API#ScriptNode_API) a node has a readonly associative array "assocs" which contains the associations of the node. But this is not true on the client side (http://wiki.alfresco.com/wiki/Document_Library_jsNode_Reference) :-(

Regards,
Mark

Outcomes