Adding custom action to multi-select

cancel
Showing results for 
Search instead for 
Did you mean: 
strugglingdev
Member II

Adding custom action to multi-select

I'm struggling finding examples or instructions on how to add my custom action to the multi-select dropdown. I've managed to get my java amp working on a per document basis - but there doesn't seem to be any actionGroup ID or anything for adding it to that spot. Can anyone give me any guidance or point me in the right direction?

2 Replies
krutik_jayswal
Senior Member II

Re: Adding custom action to multi-select

<module>
<id>Multi actions</id>
<version>${project.version}</version>
<auto-deploy>true</auto-deploy>
<auto-deploy-index>101</auto-deploy-index>
<configurations>
<config evaluator="string-compare" condition="DocumentLibrary" replace="true">
<multi-select>
<action type="action-link" id="onActionDownload" icon="document-download" label="menu.selected-items.download" />
</multi-select>
</config>
</configurations>
</module>

In above code , onActionDownload is a function, which will get called on click of the actions.Yu need to define this function inside javascript file.You can use the existing functions as well.Existing multiselect actions are defined inside share-war\WEB-INF\classes\alfresco\share-documentlibrary-config.xml file.

strugglingdev
Member II

Re: Adding custom action to multi-select

Thanks for the reply Krutik,

I am able to to get my select item showing up in the multi select, and to get it to call some arbitrary registerAction function - but is there a way to call my action defined in the repo side from the javascript? I'm having trouble making the jump from my custom function to my repo action.