---------

**Commit 1:**
Ensure table updates when page settings update

The entire table should also refresh when one of the options changes. Otherwise,
the rows are not filled in correctly to the bottom of the page.

* Original sha: 0cf2202299
* Authored by Thomas Neirynck <thomas@elastic.co> on 2016-09-21T23:38:29Z
This commit is contained in:
Elastic Jasper 2016-09-22 09:55:07 -04:00
parent 48725a379a
commit 1904f56c73

View file

@ -19,7 +19,13 @@ module.controller('KbnTableVisController', function ($scope, Private) {
$scope.uiState.set('vis.params.sort', newSort);
});
$scope.$watch('esResponse', function (resp, oldResp) {
/**
* Recreate the entire table when:
* - the underlying data changes (esResponse)
* - one of the view options changes (vis.params)
*/
$scope.$watchMulti(['esResponse', 'vis.params'], function ([resp]) {
let tableGroups = $scope.tableGroups = null;
let hasSomeRows = $scope.hasSomeRows = null;