Since we are pre-fetching all holds for these grids, we know
the totalCount and thus we can make the grid behave better.
Avoid the weirdness described in bug
1739648, which this patch
depends on.
Signed-off by: Cesar Velez <cesar.velez@equinoxinitiative.org>
hold_ids = hold_ids.concat(list);
});
+ $scope.hold_grid_data_provider.grid.totalCount = hold_ids.length;
+
// Set the max value of the progress bar to the lesser of
// the total number of holds to fetch or the page size
// of the grid.
egProgressDialog.update(
{max : hold_ids.length});
-
var holds_fetched = 0;
fetchHolds().then(deferred.resolve, null,
function(hold_data) {
}
hold_ids = ids;
+ $scope.gridDataProvider.grid.totalCount = hold_ids.length;
egProgressDialog.update(
{max : hold_ids.length});