Currently there are some interactions between the queryscript business logic and the display of results. I think it would be good if results are 'self contained' in that they contain the metadata needed to display them and interact with them, including table structure, clicking to document details (#5), and pagination.
So every result should be structured to have 'metadata' and 'results' keys, where the metadata contains all needed information on columns, pagination, possible actions, etc.
Currently there are some interactions between the queryscript business logic and the display of results. I think it would be good if results are 'self contained' in that they contain the metadata needed to display them and interact with them, including table structure, clicking to document details (#5), and pagination.
So every result should be structured to have 'metadata' and 'results' keys, where the metadata contains all needed information on columns, pagination, possible actions, etc.