I am using SmartClient_v121p_2020-04-14_PowerEdition. I have a ListGrid backed by a DataSource. The user can drag and drop rows within the grid to specify a certain order of records. I need retrieve the records in the specified order for processing.
If I try doing a dataSource.getCacheData(), the data is returned in its original order.
If I do a grid.selectAllRecords() and then grid.getSelectedRecords(), the array of ListGridRecords returned is in the proper order that I need. However, it seems like there should be a more direct way of getting the records out of the grid.
In going through the debugger and also by looking at the documentation, there is a data attribute on ListGrid. By accessing that attribute, I'm not quite getting what I need. However, I can do grid.data.allRows and I do get what I need. But, since I didn't see "allRows" in the documentation, I feel as though that is not the proper retrieval method.
Is there a more direct way to get the ListGridRecords out of the ListGrid that ensures that I am getting the records in the order that it is shown in the grid?
If I try doing a dataSource.getCacheData(), the data is returned in its original order.
If I do a grid.selectAllRecords() and then grid.getSelectedRecords(), the array of ListGridRecords returned is in the proper order that I need. However, it seems like there should be a more direct way of getting the records out of the grid.
In going through the debugger and also by looking at the documentation, there is a data attribute on ListGrid. By accessing that attribute, I'm not quite getting what I need. However, I can do grid.data.allRows and I do get what I need. But, since I didn't see "allRows" in the documentation, I feel as though that is not the proper retrieval method.
Is there a more direct way to get the ListGridRecords out of the ListGrid that ensures that I am getting the records in the order that it is shown in the grid?
Comment