ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ababiic...@apache.org
Subject ambari git commit: AMBARI-9763 Status icon on service menu disappears for 1-2 sec when turning on/off maintenance state.y (ababiichuk)
Date Tue, 24 Feb 2015 11:17:08 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 3ef3651c6 -> a5daa7b21


AMBARI-9763 Status icon on service menu disappears for 1-2 sec when turning on/off maintenance
state.y (ababiichuk)


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

Branch: refs/heads/trunk
Commit: a5daa7b21b979fde32797c8b415a1f9c7e3801ac
Parents: 3ef3651
Author: aBabiichuk <ababiichuk@cybervisiontech.com>
Authored: Tue Feb 24 12:43:17 2015 +0200
Committer: aBabiichuk <ababiichuk@cybervisiontech.com>
Committed: Tue Feb 24 12:43:35 2015 +0200

----------------------------------------------------------------------
 ambari-web/app/styles/application.less       |  4 ----
 ambari-web/app/styles/common.less            | 25 +++++++++++++++++++++++
 ambari-web/app/views/main/service/service.js | 21 +++++++++----------
 3 files changed, 35 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/a5daa7b2/ambari-web/app/styles/application.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less
index 0f7da8c..98a4941 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -1916,9 +1916,6 @@ a:focus {
   border-collapse: collapse;
   color: #666;
   font-size: 13px;
-  .icon-medkit {
-    color: black!important;
-  }
   tr.component-small {
     font-size: 11px;
   }
@@ -2271,7 +2268,6 @@ a:focus {
   }
   .icon-medkit {
     padding-left:6px;
-    color: black!important;
   }
 }
 .quick-links-wrapper {

http://git-wip-us.apache.org/repos/asf/ambari/blob/a5daa7b2/ambari-web/app/styles/common.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/common.less b/ambari-web/app/styles/common.less
index 61fb791..e9e2528 100644
--- a/ambari-web/app/styles/common.less
+++ b/ambari-web/app/styles/common.less
@@ -17,12 +17,21 @@
  */
 
 /************************************************************************
+* Health status(service/host/host component health)icons class names
+***********************************************************************/
+@health-status-red-icon:  icon-warning-sign;
+@health-status-green-icon:  icon-ok-sign;
+@health-status-yellow-icon:  icon-question-sign;
+@health-status-orange-icon:  icon-minus-sign;
+@maintenance-icon: icon-medkit;
+/************************************************************************
 * Health status(service/host/host component health)icon colors
 ***********************************************************************/
 @health-status-red: #ff0000;
 @health-status-green: #5AB400;
 @health-status-yellow: #FFD13D;
 @health-status-orange: #FF8E00;
+@maintenance-black: #000000;
 /************************************************************************
 * Health status(service/host/host component health)icon colors ends
 ***********************************************************************/
@@ -32,6 +41,22 @@
 @green: #69BE28;
 @blue: #0572ff;
 
+(~".@{health-status-red-icon}") {
+  color: @health-status-red;
+}
+(~".@{health-status-green-icon}") {
+  color: @health-status-green;
+}
+(~".@{health-status-yellow-icon}") {
+  color: @health-status-yellow;
+}
+(~".@{health-status-orange-icon}") {
+  color: @health-status-orange;
+}
+(~".@{maintenance-icon}") {
+  color: @maintenance-black;
+}
+
 @-webkit-keyframes orangePulse {
   from { background-color: #fdb82f; }
   50% { background-color: #fd910e; }

http://git-wip-us.apache.org/repos/asf/ambari/blob/a5daa7b2/ambari-web/app/views/main/service/service.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/service/service.js b/ambari-web/app/views/main/service/service.js
index 2699ddf..d8740ca 100644
--- a/ambari-web/app/views/main/service/service.js
+++ b/ambari-web/app/views/main/service/service.js
@@ -84,24 +84,23 @@ App.MainDashboardServiceHealthView = Em.View.extend({
   }.property('service.healthStatus','service.passiveState','service.serviceName'),
 
   healthStatusClass: function () {
-    switch (this.get('healthStatus')) {
-      case 'health-status-LIVE':
+    if (this.get('service.passiveState') != 'OFF' || App.get('services.clientOnly').contains(this.get('service.serviceName')))
+      return '';
+    switch (this.get('service.healthStatus')) {
+      case 'green':
+      case 'green-blinking':
         return App.healthIconClassGreen;
         break;
-      case 'health-status-DEAD-RED':
+      case 'red':
+      case 'red-blinking':
         return App.healthIconClassRed;
         break;
-      case 'health-status-DEAD-YELLOW':
+      case 'yellow':
         return App.healthIconClassYellow;
-        break;
-      case 'health-status-DEAD-ORANGE':
-        return App.healthIconClassOrange;
-        break;
       default:
-        return "";
-        break;
+        return '';
     }
-  }.property('healthStatus'),
+  }.property('service.healthStatus','service.passiveState','service.serviceName'),
 
   didInsertElement: function () {
     this.updateToolTip();


Mime
View raw message