ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akovale...@apache.org
Subject ambari git commit: AMBARI-21021. Service-level repositories should indicate 'Service' on the UI (alexantonenko)
Date Fri, 21 Jul 2017 12:52:19 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-feature-AMBARI-21450 23db89b4a -> 3430e33fd


AMBARI-21021. Service-level repositories should indicate 'Service' on the UI (alexantonenko)


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

Branch: refs/heads/branch-feature-AMBARI-21450
Commit: 3430e33fdd6f7b266c1d8273f59c41044d9c979b
Parents: 23db89b
Author: Alex Antonenko <aantonenko@hortonworks.com>
Authored: Fri Jul 21 15:51:53 2017 +0300
Committer: Alex Antonenko <aantonenko@hortonworks.com>
Committed: Fri Jul 21 15:51:53 2017 +0300

----------------------------------------------------------------------
 .../templates/main/admin/stack_upgrade/upgrade_version_box.hbs  | 3 +++
 .../views/main/admin/stack_upgrade/upgrade_version_box_view.js  | 2 ++
 ambari-web/test/utils/helper_test.js                            | 5 +++++
 3 files changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/3430e33f/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
index 9a5bf0a..e6b0651 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/upgrade_version_box.hbs
@@ -32,6 +32,9 @@
   {{#if view.isPatch}}
     <i class="icon-umbrella"></i>&nbsp;{{t common.patch}}
   {{/if}}
+  {{#if view.isService}}
+    <i class="icon-umbrella"></i>&nbsp;{{t common.service}}
+  {{/if}}
 </p>
 
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/3430e33f/ambari-web/app/views/main/admin/stack_upgrade/upgrade_version_box_view.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/admin/stack_upgrade/upgrade_version_box_view.js b/ambari-web/app/views/main/admin/stack_upgrade/upgrade_version_box_view.js
index bbd1415..c1d5f38 100644
--- a/ambari-web/app/views/main/admin/stack_upgrade/upgrade_version_box_view.js
+++ b/ambari-web/app/views/main/admin/stack_upgrade/upgrade_version_box_view.js
@@ -71,6 +71,8 @@ App.UpgradeVersionBoxView = Em.View.extend({
 
   isPatch: Em.computed.equal('content.type', 'PATCH'),
 
+  isService: Em.computed.equal('content.type', 'SERVICE'),
+
   /**
    * @type {boolean}
    */

http://git-wip-us.apache.org/repos/asf/ambari/blob/3430e33f/ambari-web/test/utils/helper_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/utils/helper_test.js b/ambari-web/test/utils/helper_test.js
index c5ec897..ca3c372 100644
--- a/ambari-web/test/utils/helper_test.js
+++ b/ambari-web/test/utils/helper_test.js
@@ -256,6 +256,8 @@ describe('utils/helper', function() {
     describe('#App.format', function(){
       describe('#commandDetail()', function() {
         var command = "GANGLIA_MONITOR STOP";
+        var customCommandDetail = "Remove_Logical_Mycomponent Mycomponent";
+        var opsDisplayName = "Remove Logical Mycomponent";
         var ignored = "DECOMMISSION, NAMENODE";
         var removeString = "SERVICE/HDFS STOP";
         var nagiosState = "nagios_update_ignore ACTIONEXECUTE";
@@ -263,6 +265,9 @@ describe('utils/helper', function() {
         it('should convert command to readable info', function() {
           expect(App.format.commandDetail(command)).to.be.equal(' Ganglia Monitor Stop');
         });
+        it('should use display name for operations if specified', function() {
+          expect(App.format.commandDetail(customCommandDetail, null, opsDisplayName)).to.be.equal('
Remove Logical Mycomponent');
+        });
         it('should ignore decommission command', function(){
           expect(App.format.commandDetail(ignored)).to.be.equal('  NameNode');
         });


Mime
View raw message