Skip to content

Commit

Permalink
avoid a bunch of exceptions with the new ng-grid and jmx
Browse files Browse the repository at this point in the history
  • Loading branch information
jstrachan committed Apr 30, 2013
1 parent 6b5b075 commit f6bcf85
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
Expand Up @@ -28,7 +28,7 @@
</div>
<div class="span6">
<div class="control-group">
<input class="span12 search-query" type="text" ng-model="$parent.searchText" placeholder="search">
<input class="span12 search-query" type="text" ng-model="$parent.gridOptions.filterOptions.filterText" placeholder="search">
</div>
</div>
</div>
Expand Up @@ -9,7 +9,7 @@
</div>
<div class="span6">
<div class="control-group">
<input type="text" class="span12 search-query" ng-model="$parent.searchText" placeholder="search">
<input type="text" class="span12 search-query" ng-model="$parent.gridOptions.filterOptions.filterText" placeholder="search">
</div>
</div>
</div>
7 changes: 5 additions & 2 deletions hawtio-web/src/main/webapp/app/jmx/js/attributes.ts
Expand Up @@ -16,6 +16,7 @@ module Jmx {
$scope.selectedItems = [];
$scope.selectCheckBox = true;

/*
var SelectToggle = function(scope) {
var self = this;
self.scope = scope;
Expand All @@ -37,12 +38,12 @@ module Jmx {
}
}
};

$scope.selectToggle = new SelectToggle($scope);
*/

$scope.gridOptions = {
selectedItems: $scope.selectedItems,
plugins: [$scope.selectToggle],
//plugins: [$scope.selectToggle],
showFilter: false,
//showColumnMenu: false,
canSelectRows: false,
Expand Down Expand Up @@ -84,11 +85,13 @@ module Jmx {

// TODO - maybe there's a better way to determine when to enable selections

/*
if (answer.startsWith("app/camel") && workspace.selection.children.length > 0) {
$scope.selectToggle.setSelect(true);
} else {
$scope.selectToggle.setSelect(false);
}
*/
return answer;
};

Expand Down

0 comments on commit f6bcf85

Please sign in to comment.