Open
Description
Deleting gird rows with gridOptions.data.splice
does not update girdFooter selected row counts.
See http://plnkr.co/edit/a7GogUdI5nDUvc2KN1Rt?p=preview
Example is a fork of Tutorial: 210 Selection.
$scope.deleteSelected = function() {
var rowsToDelete;
rowsToDelete = $scope.gridApi.selection.getSelectedRows();
if (rowsToDelete.length) {
rowEntity = rowsToDelete[0];
rowIndexToDelete = $scope.gridOptions.data.indexOf(rowEntity);
$scope.gridOptions.data.splice(rowIndexToDelete, 1);
}
}
Steps to reproduce
- select row
- press 'Delete selected row' button, which fires $scope.deleteSelected
- footer still indicates deleted row is selected (selected row count does not decrement)