0

I can't find a way to get all the sorted row data in ui-grid when using pagination

$scope.gridApi.core.getVisibleRows() only shows what is visible on the page I am on

$scope.gridApi.grid.rows contains the original data unsorted

Is there anyway to access all the sorted data? I need to display parts of it elsewhere on the page in the exact same sorted state. Thanks.

ten
  • 29
  • 3

1 Answers1

1

I couldn't find anyway to access this data, but I found it could be generated by calling their sort method:

var sorted = grid.sortByColumn(grid.rows);

sorted now has the results I want.

ten
  • 29
  • 3