incubator-ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From srima...@apache.org
Subject svn commit: r1467147 - in /incubator/ambari/trunk: CHANGES.txt ambari-web/app/styles/application.less ambari-web/app/templates/common/configs/overrideWindow.hbs ambari-web/app/views/common/configs/services_config.js
Date Fri, 12 Apr 2013 00:24:08 GMT
Author: srimanth
Date: Fri Apr 12 00:24:07 2013
New Revision: 1467147

URL: http://svn.apache.org/r1467147
Log:
AMBARI-1903. Host Exception Popup layout and cosmetic issues. (srimanth)

Modified:
    incubator/ambari/trunk/CHANGES.txt
    incubator/ambari/trunk/ambari-web/app/styles/application.less
    incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs
    incubator/ambari/trunk/ambari-web/app/views/common/configs/services_config.js

Modified: incubator/ambari/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/CHANGES.txt?rev=1467147&r1=1467146&r2=1467147&view=diff
==============================================================================
--- incubator/ambari/trunk/CHANGES.txt (original)
+++ incubator/ambari/trunk/CHANGES.txt Fri Apr 12 00:24:07 2013
@@ -695,6 +695,8 @@ Trunk (unreleased changes):
 
  BUG FIXES
 
+ AMBARI-1903. Host Exception Popup layout and cosmetic issues. (srimanth)
+
  AMBARI-1901. Add additional tests for verifying request behavior based on 
  host role command results. (smohanty)
 

Modified: incubator/ambari/trunk/ambari-web/app/styles/application.less
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/styles/application.less?rev=1467147&r1=1467146&r2=1467147&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/styles/application.less (original)
+++ incubator/ambari/trunk/ambari-web/app/styles/application.less Fri Apr 12 00:24:07 2013
@@ -916,6 +916,23 @@ a:focus {
         clear:both;
       }
       .override-controls{
+        .icon-ok-sign {
+          color: #5AB400;
+        }
+        #filter-dropdown-div {
+          .dropdown-menu {
+            right: 0;
+            left: auto;
+          }
+        }
+        #component-dropdown-div {
+          vertical-align: top; 
+          padding-left: 5px;
+          .dropdown-menu {
+            right: 0;
+            left: auto;
+          }
+        }
         .input-append{
           input{
             -webkit-border-radius: 4px 0 0 4px;
@@ -934,7 +951,7 @@ a:focus {
         }
         .hosts-table-container{
           width:100%;
-          height: 280px;
+          height: 270px;
           overflow: auto;
           border: 1px solid #eee;
         }

Modified: incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs?rev=1467147&r1=1467146&r2=1467147&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs (original)
+++ incubator/ambari/trunk/ambari-web/app/templates/common/configs/overrideWindow.hbs Fri
Apr 12 00:24:07 2013
@@ -28,11 +28,14 @@
         <table style="width: 100%;">
           <tr>
             <td>
-              <a href="#" {{action clearFilters target="view" }}>{{view.hostSelectMessage}}</a>
+              <a href="#" {{action toggleShowSelectedHosts target="view" }}>{{view.hostSelectMessage}}</a>
+              {{#if view.showOnlySelectedHosts}}
+                <i class='icon-ok-sign'></i>
+              {{/if}}
             </td>
             <td width="30%">
               <div class="row">
-                <div class="span2">
+                <div class="span2" id="filter-dropdown-div">
                   <!-- Filter text box with drop-down -->
 		              <div class="input-append">
 		                {{view Ember.TextField valueBinding="view.filterText" id="appendedDropdownButton"
placeholderBinding="view.filterTextPlaceholder" class="span2"}}
@@ -57,7 +60,7 @@
 		                </div>
 		              </div>
                 </div>
-                <div class="span2">
+                <div class="span2" id="component-dropdown-div">
                   <!-- Host-components drop-down -->
 		              <div class="btn-group">
 		                <a class="btn dropdown-toggle" data-toggle="dropdown" href="#">

Modified: incubator/ambari/trunk/ambari-web/app/views/common/configs/services_config.js
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/views/common/configs/services_config.js?rev=1467147&r1=1467146&r2=1467147&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/views/common/configs/services_config.js (original)
+++ incubator/ambari/trunk/ambari-web/app/views/common/configs/services_config.js Fri Apr
12 00:24:07 2013
@@ -375,7 +375,7 @@ App.ServiceConfigsByCategoryView = Ember
         filterText: '',
         filterTextPlaceholder: Em.I18n.t('hosts.selectHostsDialog.filter.placeHolder'),
         availableHosts: availableHosts,
-        filterColumn: null,
+        filterColumn: Ember.Object.create({id:'ip', name:'IP Address', selected:false}),
         filterColumns: Ember.A([
            Ember.Object.create({id:'ip', name:'IP Address', selected:false}),
            Ember.Object.create({id:'cpu', name:'CPU', selected:false}),
@@ -385,11 +385,13 @@ App.ServiceConfigsByCategoryView = Ember
            Ember.Object.create({id:'osArch', name:'OS Architecture', selected:false}),
            Ember.Object.create({id:'osType', name:'OS Type', selected:false})
         ]),
+        showOnlySelectedHosts: false,
         filterComponents: validComponents,
         filterComponent: null,
         filteredHosts: function () {
           var hosts = this.get('availableHosts');
           var filterText = this.get('filterText');
+          var showOnlySelectedHosts = this.get('showOnlySelectedHosts');
           var filteredHosts = Ember.A([]);
           var self = this;
           hosts.forEach(function (host) {
@@ -422,12 +424,15 @@ App.ServiceConfigsByCategoryView = Ember
                 skip = true;
               }
             }
+            if (!skip && showOnlySelectedHosts && !host.get('selected')){
+              skip = true;
+            }
             if (!skip) {
               filteredHosts.pushObject(host);
             }
           });
           return filteredHosts;
-        }.property('availableHosts', 'filterText', 'filterColumn', 'filterComponent', 'filterComponent.componentName'),
+        }.property('availableHosts', 'filterText', 'filterColumn', 'filterComponent', 'filterComponent.componentName',
'showOnlySelectedHosts'),
         hostColumnValue: function(host, column){
           return host.get(column.id);
         },
@@ -471,13 +476,14 @@ App.ServiceConfigsByCategoryView = Ember
             this.get('availableHosts').setEach('selected', false);
           }
         }.observes('allHostsSelected'),
-        clearFilters: function () {
+        toggleShowSelectedHosts: function () {
           var currentFilter = this.get('filterComponent');
           if (currentFilter != null) {
             currentFilter.set('selected', false);
           }
           this.set('filterComponent', null);
           this.set('filterText', null);
+          this.set('showOnlySelectedHosts', !this.get('showOnlySelectedHosts'));
         }
       })
     });



Mime
View raw message