When I used Sort on on a Template Grid in a data view in a Document Template, the Grid returns blank. When there is no Sort, everything returns as expected

1
I'm working on a PDF document - the customer needs to print out repeated records. I have a pretty standard document generation microflow. The 'printReport' created is a generalisation of FileDocument. When I run this, to produce this document; Everything is fine. However, there's a requirement to sort by a string ID value. When we try and sort by anything, it returns the content from the data view but nothing repeatable from the grid. I've checked security (all has access), other apps where i've done this same behaviour (no major differences), the sort data is populated (it is), that the microflow returns data (it does). Going a bit mental at this point. Anyone had a similar issue?
asked
3 answers
2

I've found the solution...

In my document generation microflow, I was committing the FileDocument object, but not the list - which I loop through to associate to said Document. After committing the list as well as the FileDocument, it now returns data just fine.

I'm still not sure why I don't need to commit the list to just return the associated list, unordered in my document just fine, so if anyone knows why that might be the case let me know!

answered
1

I would make 'tripple' sure that the association project_printreport is filled with a list of projects(and not for example with one object). If that is indeed the case then the sort should work normally.  

If it still does not you could then fill the datagradid with a microflow datasource and sort the data in this microflow. You could debug this as well to double check if your sort works.

answered
0

I've found the solution...

In my document generation microflow, I was committing the FileDocument object, but not the list - which I loop through to associate to said Document. After committing the list as well as the FileDocument, it now returns data just fine.

I'm still not sure why I don't need to commit the list to just return the associated list, unordered in my document just fine, so if anyone knows why that might be the case let me know!

answered