You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by xi...@apache.org on 2014/07/02 02:15:45 UTC

[1/2] git commit: AMBARI-6345. active host table column CSS cleanup.(xiwang)

Repository: ambari
Updated Branches:
  refs/heads/branch-1.6.1 1acfd8607 -> 6a3a6edb5


AMBARI-6345. active host table column CSS cleanup.(xiwang)


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

Branch: refs/heads/branch-1.6.1
Commit: eb460a0b6a37ab8a61c4e5337cf4fe9cca9f3512
Parents: 1acfd86
Author: Xi Wang <xi...@apache.org>
Authored: Tue Jul 1 13:49:57 2014 -0700
Committer: Xi Wang <xi...@apache.org>
Committed: Tue Jul 1 17:14:39 2014 -0700

----------------------------------------------------------------------
 ambari-web/app/styles/application.less | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/eb460a0b/ambari-web/app/styles/application.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less
index 81293c3..424681b 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -3271,9 +3271,7 @@ table.graphs {
         color: #555555;
         text-decoration: none;
         background-color: #e5e5e5;
-        -webkit-box-shadow: inset 0 5px 8px rgba(0, 0, 0, 0.100);
-        -moz-box-shadow: inset 0 5px 8px rgba(0, 0, 0, 0.100);
-        box-shadow: inset 0 5px 8px rgba(0, 0, 0, 0.100);
+        border-radius: 0px;
       }
     }
 
@@ -4460,9 +4458,7 @@ ul.filter {
         color: #555555;
         text-decoration: none;
         background-color: #e5e5e5;
-        -webkit-box-shadow: inset 0 5px 8px rgba(0, 0, 0, 0.100);
-        -moz-box-shadow: inset 0 5px 8px rgba(0, 0, 0, 0.100);
-        box-shadow: inset 0 5px 8px rgba(0, 0, 0, 0.100);
+        border-radius: 0px;
       }
     }
 


[2/2] git commit: AMBARI-6348. Switching to host config group should spin since it takes a while.(xiwang)

Posted by xi...@apache.org.
AMBARI-6348. Switching to host config group should spin since it takes a while.(xiwang)


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

Branch: refs/heads/branch-1.6.1
Commit: 6a3a6edb5a501fa0f1ed09784840d9a1d84c0b63
Parents: eb460a0
Author: Xi Wang <xi...@apache.org>
Authored: Tue Jul 1 16:47:47 2014 -0700
Committer: Xi Wang <xi...@apache.org>
Committed: Tue Jul 1 17:14:53 2014 -0700

----------------------------------------------------------------------
 ambari-web/app/messages.js                      |  2 ++
 .../common/configs/overriddenProperty.hbs       | 33 +++++++++++---------
 .../common/configs/overriddenProperty_view.js   | 16 +++++++++-
 3 files changed, 36 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/6a3a6edb/ambari-web/app/messages.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 5aed212..b11d951 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1336,6 +1336,8 @@ Em.I18n.translations = {
   'services.service.config_groups.add_config_group_popup.header':'Create New Configuration Group',
   'services.service.config_groups.duplicate_config_group_popup.header':'Duplicate Configuration Group',
   'services.service.config_groups.rename_config_group_popup.header':'Rename Configuration Group',
+  'services.service.config_groups.switchGroupTextFull':'Switch to \'{0}\' host config group',
+  'services.service.config_groups.switchGroupTextShort':'Switch to \'{0}\'',
   'services.reassign.closePopup':'Move {0} wizard is in progress. You must allow the wizard to complete for Ambari to be in usable state. If you choose to quit, you must follow manual instructions to complete or revert move {0} wizard as documented in the Ambari User Guide. Are you sure you want to exit the wizard?',
 
   'services.reassign.step1.header':'Get Started',

http://git-wip-us.apache.org/repos/asf/ambari/blob/6a3a6edb/ambari-web/app/templates/common/configs/overriddenProperty.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/configs/overriddenProperty.hbs b/ambari-web/app/templates/common/configs/overriddenProperty.hbs
index 053015b..8fe54d9 100644
--- a/ambari-web/app/templates/common/configs/overriddenProperty.hbs
+++ b/ambari-web/app/templates/common/configs/overriddenProperty.hbs
@@ -16,22 +16,27 @@
 * limitations under the License.
 }}
 {{#each overriddenSCP in view.serviceConfigProperty.overrides}}
-    {{! Here serviceConfigBinding should ideally be serviceConfigPropertyBinding }}
-    <div {{bindAttr class="overriddenSCP.errorMessage:error: :control-group :overrideField"}}>
-      {{view overriddenSCP.viewClass serviceConfigBinding="overriddenSCP" categoryConfigsBinding="view.categoryConfigs"}}
-      {{#if view.isDefaultGroupSelected}}
-        {{#if overriddenSCP.group}}
-            <a class="action" {{action selectConfigGroup overriddenSCP.group target="controller"}}>{{overriddenSCP.group.displayName}}</a>
-        {{/if}}
+  {{! Here serviceConfigBinding should ideally be serviceConfigPropertyBinding }}
+  <div {{bindAttr class="overriddenSCP.errorMessage:error: :control-group :overrideField"}}>
+    {{view overriddenSCP.viewClass serviceConfigBinding="overriddenSCP" categoryConfigsBinding="view.categoryConfigs"}}
+    {{#if view.isDefaultGroupSelected}}
+      {{#if overriddenSCP.group}}
+        <a rel='SwitchGroupTooltip' {{bindAttr data-original-title="overriddenSCP.group.switchGroupTextFull" }} class="action" {{action selectConfigGroup overriddenSCP.group target="controller"}}>
+          {{overriddenSCP.group.switchGroupTextShort}}
+        </a>
       {{/if}}
+    {{else}}
       {{#if overriddenSCP.isEditable}}
-	      {{#if isNotDefaultValue}}
-	        <a class="action" {{action "doRestoreDefaultValue" this target="view" }} ><i class="icon-undo"></i>{{t common.undo}}</a>
-	      {{/if}}
+        {{#if isNotDefaultValue}}
+          <a class="action" {{action "doRestoreDefaultValue" this target="view" }} ><i class="icon-undo"></i>{{t common.undo}}</a>
+        {{/if}}
         {{#if App.isAdmin}}
-	        <a class="action" {{action "removeOverride" overriddenSCP target="view" }} ><i class="icon-minus-sign"></i>{{t common.remove}}</a>
+          <a class="action" {{action "removeOverride" overriddenSCP target="view" }} ><i class="icon-minus-sign"></i>{{t common.remove}}</a>
         {{/if}}
-	      <span class="help-inline">{{overriddenSCP.errorMessage}}</span>
-	    {{/if}}
-    </div>
+          <span class="help-inline">{{overriddenSCP.errorMessage}}</span>
+      {{else}}
+        <a class="action">{{overriddenSCP.group.switchGroupTextShort}}</a> <i class="icon-spinner"></i>
+      {{/if}}
+    {{/if}}
+  </div>
 {{/each}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/6a3a6edb/ambari-web/app/views/common/configs/overriddenProperty_view.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/common/configs/overriddenProperty_view.js b/ambari-web/app/views/common/configs/overriddenProperty_view.js
index 5c77371..811846e 100644
--- a/ambari-web/app/views/common/configs/overriddenProperty_view.js
+++ b/ambari-web/app/views/common/configs/overriddenProperty_view.js
@@ -23,7 +23,21 @@ App.ServiceConfigView.SCPOverriddenRowsView = Ember.View.extend({
   serviceConfigProperty: null, // is passed dynamically at runtime where ever
   // we are declaring this from configs.hbs ( we are initializing this from UI )
   categoryConfigs: null, // just declared as viewClass need it
-  
+
+  didInsertElement: function (){
+    if (this.get('isDefaultGroupSelected')) {
+      var overrides = this.get('serviceConfigProperty.overrides');
+      overrides.forEach(function(overriddenSCP) {
+        overriddenSCP.get('group').set('switchGroupTextShort',
+          Em.I18n.t('services.service.config_groups.switchGroupTextShort').format(overriddenSCP.get('group.displayName')));
+        overriddenSCP.get('group').set('switchGroupTextFull',
+          Em.I18n.t('services.service.config_groups.switchGroupTextFull').format(overriddenSCP.get('group.displayName')));
+      })
+      this.set('serviceConfigProperty.overrides', overrides);
+      App.tooltip(this.$("[rel='SwitchGroupTooltip']"));
+    }
+  },
+
   removeOverride: function (event) {
     // arg 1 SCP means ServiceConfigProperty
     var scpToBeRemoved = event.contexts[0];