AnsweredAssumed Answered

Access file of the new page after a custom action - Alfresco

Question asked by pat9rv3sousa on Oct 31, 2015
Latest reply on Nov 2, 2015 by muralidharand
I make an action for documents :

<action id="documents-document" type="javascript" label="actions.documents-document" icon="documents-document">
<param name="function">onActionDocument</param>
<permission allow="true">Write</permission>

In this action, I want to call a new page created with Aikau -> something like this ->

But, I want to access the document in the new page… On the function onActionDocument I access document like:

(function() {"registerAction",
actionName: "onActionDocument",
fn: function JSC_onActionDocument(file) {

But, I have another JS, FTL and XML for the new page… And in this files, how can I access the file? I try to make a POST and, now, a GET Request and pass the parameter on the URL like this:


I put in the JS of the new page something like :

var a = file

but when the page is open, I obtain the 500 error Internal Server and I got "file is undefined".

How can I pass this file to the new page?