AnsweredAssumed Answered

Download search result list to a csv

Question asked by artisca on Oct 5, 2018



I have an Alfresco 5.0 that has implemented a button in the search result page that downloads the whole list to a csv file. Now I need to upgrade to Alfresco 5.2 version and have problems to migrate this functionality.


As far as I could figure out, the improvement was making modifications in faceted-search.get.js to add the button


 name: "alfresco/buttons/AlfButton",
 config: {
     id: "onActionExport",
     label: "Descargar resultados en CSV",
     iconImage: url.context + "/res/components/documentlibrary/actions/document-download-16.png",
     type: "action-link",
     permission: "",
     asset: "",
     href: "",
     hasAspect: "",
     notAspect: "",
     publishTopic: "ALF_EXPORT_AS_CSV",
    publishPayload: {
    action: "onActionExport"

and also was added the a new ftl to the search webscript (search.get.js) to generate the csv.


I implemented the button in the same way in Alfresco 5.2 and it shows up, but when I press it, it does not make any request. I have also tried adding the ftl to the webscript but it is no longer in the same site and I have not been able to find it


The aikau version used on the Alfresco 5.0 is the 1.0.54 and in the Alfresco 5.2 is the I don´t know if have been any changes between this versions than can affect this functionality I try to migrate.


Right now I'm stuck with this problem and I need to make it work or find an workaround.


I hope you could help me.