ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yus...@apache.org
Subject git commit: AMBARI-4417. "services actions" menu UI. (sposetti via yusaku)
Date Tue, 28 Jan 2014 03:08:08 GMT
Updated Branches:
  refs/heads/trunk 7b9682f81 -> 682ef9984


AMBARI-4417. "services actions" menu UI. (sposetti via yusaku)


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

Branch: refs/heads/trunk
Commit: 682ef9984ef1ac246a63c2ab0acded3f6f4c0a0e
Parents: 7b9682f
Author: Yusaku Sako <yusaku@hortonworks.com>
Authored: Mon Jan 27 19:07:20 2014 -0800
Committer: Yusaku Sako <yusaku@hortonworks.com>
Committed: Mon Jan 27 19:07:49 2014 -0800

----------------------------------------------------------------------
 ambari-web/app/messages.js                              | 12 ++++++------
 ambari-web/app/styles/application.less                  |  1 -
 .../app/templates/common/rolling_restart_view.hbs       |  3 ++-
 ambari-web/app/templates/main/host/details.hbs          |  3 ++-
 ambari-web/app/templates/main/service/item.hbs          |  3 ++-
 ambari-web/app/views/main/host/details.js               |  8 ++++----
 ambari-web/app/views/main/service/item.js               |  8 ++++----
 7 files changed, 20 insertions(+), 18 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/messages.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 5e9a68f..99967dc 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -1787,19 +1787,19 @@ Em.I18n.translations = {
   'mirroring.dateOrder.error': 'End Date must be after Start Date',
   'mirroring.required.invalidNumberError' : 'Enter valid number',
 
-  'rollingrestart.dialog.title': 'Rolling Restart {0}s',
+  'rollingrestart.dialog.title': 'Restart {0}s',
   'rollingrestart.dialog.primary': 'Trigger Restart',
   'rollingrestart.notsupported.hostComponent': 'Rolling restart not supported for {0} components',
-  'rollingrestart.dialog.msg.restart': 'This will restart {0} {1} in batches to keep your
cluster operational and minimize downtime.',
-  'rollingrestart.dialog.msg.restart.plural': 'This will restart {0} {1}s in batches to keep
your cluster operational and minimize downtime.',
+  'rollingrestart.dialog.msg.restart': 'This will restart {0} {1} at a time.',
+  'rollingrestart.dialog.msg.restart.plural': 'This will restart {0} {1}s at a time.',
   'rollingrestart.dialog.msg.noRestartHosts': 'There are no {0}s to do rolling restarts',
-  'rollingrestart.dialog.msg.maintainance': 'Note: {0} {1} in Maintainance Mode will not
be restarted',
-  'rollingrestart.dialog.msg.maintainance.plural': 'Note: {0} {1}s in Maintainance Mode will
not be restarted',
+  'rollingrestart.dialog.msg.maintainance': 'Note: {0} {1} in Out of Service Mode will not
be restarted',
+  'rollingrestart.dialog.msg.maintainance.plural': 'Note: {0} {1}s in Out of Service Mode
will not be restarted',
   'rollingrestart.dialog.msg.componentsAtATime': '{0}s at a time',
   'rollingrestart.dialog.msg.timegap.prefix': 'Wait ',
   'rollingrestart.dialog.msg.timegap.suffix': 'seconds between batches ',
   'rollingrestart.dialog.msg.toleration.prefix': 'Tolerate up to ',
-  'rollingrestart.dialog.msg.toleration.suffix': 'failures',
+  'rollingrestart.dialog.msg.toleration.suffix': 'restart failures',
   'rollingrestart.dialog.err.invalid.batchsize': 'Invalid restart batch size: {0}',
   'rollingrestart.dialog.err.invalid.waitTime': 'Invalid wait time between batches: {0}',
   'rollingrestart.dialog.err.invalid.toleratesize': 'Invalid failure toleration count: {0}',

http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/styles/application.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less
index a11e846..7bc6599 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -5219,7 +5219,6 @@ i.icon-asterisks {
     }
     tr:last-of-type {
       td {
-        text-align: center;
         input {
           vertical-align: top;
         }

http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/templates/common/rolling_restart_view.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/rolling_restart_view.hbs b/ambari-web/app/templates/common/rolling_restart_view.hbs
index 8b38044..673673e 100644
--- a/ambari-web/app/templates/common/rolling_restart_view.hbs
+++ b/ambari-web/app/templates/common/rolling_restart_view.hbs
@@ -44,7 +44,8 @@
       <td>{{t rollingrestart.dialog.msg.toleration.suffix}}</td>
     </tr>
     <tr>
-      <td colspan="3">
+      <td>&nbsp;</td>
+      <td colspan="2">
         {{view Ember.Checkbox checkedBinding="view.staleConfigsOnly"}}
         {{view.staleConfigsOnlyMessage}}
       </td>

http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/templates/main/host/details.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/host/details.hbs b/ambari-web/app/templates/main/host/details.hbs
index e976fd3..d889ea8 100644
--- a/ambari-web/app/templates/main/host/details.hbs
+++ b/ambari-web/app/templates/main/host/details.hbs
@@ -38,7 +38,8 @@
 				        <!-- dropdown menu links -->
 				        {{#each option in view.maintenance}}
 				        <li {{bindAttr class="controller.isStopDisabled:disabled"}}>
-				          <a {{action "doAction" option target="controller" href=true}}>{{option.label}}</a>
+				          <a {{action "doAction" option target="controller" href=true}}><i {{bindAttr
class="option.cssClass"}}></i>
+{{option.label}}</a>
 				        </li>
 				        {{/each}}
 				      </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/templates/main/service/item.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/item.hbs b/ambari-web/app/templates/main/service/item.hbs
index eb7ac4e..05cd306 100644
--- a/ambari-web/app/templates/main/service/item.hbs
+++ b/ambari-web/app/templates/main/service/item.hbs
@@ -70,7 +70,8 @@
         <!-- Other service actions -->
         {{#each option in view.maintenance}}
         <li {{bindAttr class="option.disabled:disabled"}}>
-          <a {{action "doAction" option target="controller" href=true}}>{{option.label}}</a>
+          <a {{action "doAction" option target="controller" href=true}}><i {{bindAttr
class="option.cssClass"}}></i>
+{{option.label}}</a>
         </li>
         {{/each}}
       </ul>

http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/views/main/host/details.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/host/details.js b/ambari-web/app/views/main/host/details.js
index 074c7a9..006297a 100644
--- a/ambari-web/app/views/main/host/details.js
+++ b/ambari-web/app/views/main/host/details.js
@@ -28,10 +28,10 @@ App.MainHostDetailsView = Em.View.extend({
 
   maintenance: function(){
     return [
-         {action: 'startAllComponents', 'label': this.t('hosts.host.details.startAllComponents')},
-         {action: 'stopAllComponents', 'label': this.t('hosts.host.details.stopAllComponents')},
-         {action: 'restartAllComponents', 'label': this.t('hosts.host.details.restartAllComponents')},
-         {action: 'deleteHost', 'label': this.t('hosts.host.details.deleteHost')}];
+      {action: 'startAllComponents', cssClass: 'icon-play enabled', 'label': this.t('hosts.host.details.startAllComponents')},
+      {action: 'stopAllComponents', cssClass: 'icon-stop enabled', 'label': this.t('hosts.host.details.stopAllComponents')},
+      {action: 'restartAllComponents', cssClass: 'icon-forward enabled', 'label': this.t('hosts.host.details.restartAllComponents')},
+      {action: 'deleteHost', cssClass: 'icon-remove enabled', 'label': this.t('hosts.host.details.deleteHost')}];
   }.property('controller.content'),
   didInsertElement: function() {
     App.tooltip($("[rel='HealthTooltip']"));

http://git-wip-us.apache.org/repos/asf/ambari/blob/682ef998/ambari-web/app/views/main/service/item.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/service/item.js b/ambari-web/app/views/main/service/item.js
index 546afa1..1f1c3ab 100644
--- a/ambari-web/app/views/main/service/item.js
+++ b/ambari-web/app/views/main/service/item.js
@@ -29,12 +29,12 @@ App.MainServiceItemView = Em.View.extend({
     var disabled = this.get('controller.isStopDisabled');
     var serviceName = service.get('serviceName');
     // Restart All action
-    options.push({action:'restartAllHostComponents', context: serviceName, 'label': Em.I18n.t('restart.service.all'),
disabled: false});
+    options.push({action:'restartAllHostComponents', cssClass: 'icon-forward', context: serviceName,
'label': Em.I18n.t('restart.service.all'), disabled: false});
     // Rolling Restart action
     var rrComponentName = batchUtils.getRollingRestartComponentName(serviceName);
     if (rrComponentName) {
       var label = Em.I18n.t('rollingrestart.dialog.title').format(App.format.role(rrComponentName));
-      options.push({action:'rollingRestart', context: rrComponentName, 'label': label, disabled:
false});
+      options.push({action:'rollingRestart', cssClass: 'icon-time', context: rrComponentName,
'label': label, disabled: false});
     }
     // Service Check and Reassign Master actions
     switch (serviceName) {
@@ -47,13 +47,13 @@ App.MainServiceItemView = Em.View.extend({
         if (App.supports.reassignMaster && hosts > 1) {
           allMasters.forEach(function (hostComponent) {
             if (App.reassignableComponents.contains(hostComponent)) {
-              options.push({action: 'reassignMaster', context: hostComponent,
+              options.push({action: 'reassignMaster', context: hostComponent, cssClass: 'icon-share-alt',

                 'label': Em.I18n.t('services.service.actions.reassign.master').format(App.format.role(hostComponent)),
disabled: false});
             }
           })
         }
       default:
-        options.push({action: 'runSmokeTest', 'label': Em.I18n.t('services.service.actions.run.smoke'),
disabled:disabled});
+        options.push({action: 'runSmokeTest', cssClass: 'icon-thumbs-up-alt', 'label': Em.I18n.t('services.service.actions.run.smoke'),
disabled:disabled});
     }
     return options;
   }.property('controller.content', 'controller.isStopDisabled'),


Mime
View raw message