ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rz...@apache.org
Subject ambari git commit: AMBARI-15378 Create multiple version state filters instead of one combined one on host page for version page (Joe Wang via rzang)
Date Thu, 10 Mar 2016 23:09:03 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk a9d562171 -> 171379abd


AMBARI-15378 Create multiple version state filters instead of one combined one on host page
for version page (Joe Wang via rzang)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/171379ab
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/171379ab
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/171379ab

Branch: refs/heads/trunk
Commit: 171379abd1bd525c5ff9693f7e8bc27bc182fec4
Parents: a9d5621
Author: Richard Zang <rzang@apache.org>
Authored: Thu Mar 10 15:08:35 2016 -0800
Committer: Richard Zang <rzang@apache.org>
Committed: Thu Mar 10 15:08:35 2016 -0800

----------------------------------------------------------------------
 ambari-web/app/controllers/main/host.js | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/171379ab/ambari-web/app/controllers/main/host.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/host.js b/ambari-web/app/controllers/main/host.js
index efc0ba2..ec745e7 100644
--- a/ambari-web/app/controllers/main/host.js
+++ b/ambari-web/app/controllers/main/host.js
@@ -528,7 +528,7 @@ App.MainHostController = Em.ArrayController.extend(App.TableServerMixin,
{
     if (Em.isNone(displayName) || Em.isNone(states) || !states.length) return;
     var colPropAssoc = this.get('colPropAssoc');
     var map = this.get('labelValueMap');
-    var displayStates = [];
+    var stateFilterStrs = [];
 
     var versionFilter = {
       iColumn: 16,
@@ -544,12 +544,11 @@ App.MainHostController = Em.ArrayController.extend(App.TableServerMixin,
{
     map["Version State"] = colPropAssoc[stateFilter.iColumn];
     stateFilter.value.forEach(function(state) {
       map[App.HostStackVersion.formatStatus(state)] = state;
-      displayStates.push(App.HostStackVersion.formatStatus(state));
+      stateFilterStrs.push('"Version State": "' + App.HostStackVersion.formatStatus(state)
+ '"');
     });
     var versionFilterStr = '"Stack Version": "' + versionFilter.value + '"';
-    var stateFilterStr = '"Version State": "' + displayStates.join(',') + '"';
     App.db.setFilterConditions(this.get('name'), [versionFilter, stateFilter]);
-    App.db.setComboSearchQuery(this.get('name'), [versionFilterStr, stateFilterStr].join('
'));
+    App.db.setComboSearchQuery(this.get('name'), [versionFilterStr, stateFilterStrs.join('
')].join(' '));
   },
 
   goToHostAlerts: function (event) {


Mime
View raw message