Export to excel - filtered list view

0
Hello, I’m using a list view with the list view text box filter to filter the list. I have excel export for that list which contains thousand records. Goal is – Export information to excel, but which was filtered with search buttons. As example I’ve filtered list and got 20 records which I want to have in excel file. Maybe somebody has any ideas how to do this without creation of helpers objects or at least don’t have big impact on performance.  Or has some experience on usage JavaScript for such scenarios?   Thanks in advance.
asked
2 answers
2

With a bit of javascript it should be possible to get the constraint that is applied to the listview.

The following should get you started:

var listViewWidget = dijit.registry.byNode(document.querySelector('.mx-name-listView1'));
console.log(listViewWidget._datasource._constraints);

 

answered
0
  1. If you have custom list view information, to get filtered data and export to excel you can call Nanoflow from the page and collect in string attribute selected filters(Export to Excel button to call nanoflow).
  2. So after you returned constraint from the page, you can call microflow from nanoflow and get information from database by custom Java action with two input parameters.(Entity and JS Constraint)
  3. But of course now with Mendix version 9, easy way would be to use datagrid 2.
answered