Relations Tab for folderish document types
Hi,
i am trying to show the Relations Tab for folderish document types with the following action contribution:
<?xml version="1.0"?>
<component name="net.hra.custom1.actions">
<require>org.nuxeo.ecm.platform.actions.relations.web</require>
<extension target="org.nuxeo.ecm.platform.actions.ActionService" point="actions">
<action id="TAB_RELATIONS" link="/incl/tabs/document_relations.xhtml"
enabled="true" label="action.view.relations" order="55" type="rest_document_link">
<category>VIEW_ACTION_LIST</category>
<filter id="view_relations">
<rule grant="true">
<permission>Read</permission>
</rule>
<rule grant="true">
<facet>Folderish</facet>
</rule>
<rule grant="false">
<type>Server</type>
</rule>
</filter>
</action>
</extension>
</component>
I thought with this contribution the Relations Tab would be shown for every Folderish Document type, but it's not working.
What do i miss here?
Thanks, Max
Ok, overriding the default “TAB RELATIONS” action doesn't work for me, but using a custom action id seems to do the trick. I wanted to have visible TAB RELATIONS for my custom folderish doctype “CFolder”:
<?xml version="1.0"?>
<component name="net.hra.custom1.actions">
<extension target="org.nuxeo.ecm.platform.actions.ActionService" point="actions">
<action id="MY_TAB_RELATIONS" link="/incl/tabs/document_relations.xhtml"
enabled="true" label="action.view.relations" order="55" type="rest_document_link">
<category>VIEW_ACTION_LIST</category>
<filter id="cf_view_relations">
<rule grant="false">
<condition>#{not (currentDocument.type =='CFolder')}</condition>
</rule>
</filter>
</action>
</extension>
</component>
This contribution works for me.
It would be nice to know, why my first approach (complete override of TAB RELATION action) isn't working, can somebody with more insight shed some light to this for me?
Thanks, Max