Export all records with aldeed:tabular

Hi,

I’m using aldeed:tabular in my app and it works fine. But now I’m trying to export all records with Buttons Extensions, but not works.

I think that this happen because aldeed:tabular load limited data. Only data for one page.

Someone already created any functions to export all data?

Thanks.

1 Like

I did a workaround to resolv fast:

buttons: [
    {
      text: "Export to CSV",
      action: function(e, dt, node, config) {
        Meteor.call("getData", function(error, result) {
          if (error) {
            console.log(error)
          } else {
            var csv = Papa.unparse(result);
            $.fn.dataTable.fileSave(
                new Blob([csv]),
                "Links_" + Date.now() + ".csv"
              );
          }
        });
      }
    }
  ]

I hope it helps someone.

I found this package DynamicTables, someone already use it ?

Hey, I use (and wrote) that package for around 30 different tables in a production system, some of which use the advanced search and export functionality - the documentation I wrote is a little out of date - so if you decide to use it shoot me a message as there are a couple of options you may need to apply.

I want, please. Thank you

@raragao - I’m working on a new version of this package that will be slightly more performant. It’s probably best if you wait for that. I expect to have it ready in the next week.

@raragao I published the new version today - the only thing you need to know really is that if you use a publication that returns an array of cursors, or utilise the compositePublicationNames property - you must also specify a “good” sort (one where preferably there aren’t multiple valid orderings of documents).

Let me know how you get on with it.

I’ll test it soon. Thanks.