You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by al...@apache.org on 2015/12/10 18:48:40 UTC

ambari git commit: AMBARI-14324. Users with non-administrator permissions should not be presented with an option to edit stack repository URLs

Repository: ambari
Updated Branches:
  refs/heads/trunk 5de1d0547 -> 9df68b978


AMBARI-14324. Users with non-administrator permissions should not be presented with an option to edit stack repository URLs


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

Branch: refs/heads/trunk
Commit: 9df68b97804e9f56234823e74b98ce31fba88a6c
Parents: 5de1d05
Author: Alex Antonenko <hi...@gmail.com>
Authored: Thu Dec 10 19:35:05 2015 +0200
Committer: Alex Antonenko <hi...@gmail.com>
Committed: Thu Dec 10 19:48:35 2015 +0200

----------------------------------------------------------------------
 ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs     | 2 +-
 .../app/views/main/admin/stack_upgrade/upgrade_version_box_view.js | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/9df68b97/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs b/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
index 59eb33f..3b5f6d3 100644
--- a/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
+++ b/ambari-web/app/templates/main/admin/stack_upgrade/versions.hbs
@@ -36,7 +36,7 @@
       {{/each}}
     </ul>
   </div>
-  {{#isAuthorized "CLUSTER.UPGRADE_DOWNGRADE_STACK"}}
+  {{#isAuthorized "AMBARI.MANAGE_STACK_VERSIONS"}}
     <button class="btn btn-primary pull-right" {{action goToVersions target="view"}} id="manage-versions-link">
       <i class="icon-external-link"></i>&nbsp;{{t admin.stackVersions.manageVersions}}
     </button>

http://git-wip-us.apache.org/repos/asf/ambari/blob/9df68b97/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 9835af2..b6c5ad9 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
@@ -55,7 +55,7 @@ App.UpgradeVersionBoxView = Em.View.extend({
   }.property('App.upgradeState', 'content.displayName', 'controller.upgradeVersion'),
 
   isRepoUrlsEditDisabled: function () {
-    return ['INSTALLING', 'UPGRADING'].contains(this.get('content.status')) || this.get('isUpgrading');
+    return ['INSTALLING', 'UPGRADING'].contains(this.get('content.status')) || this.get('isUpgrading') || (!App.isAuthorized('AMBARI.MANAGE_STACK_VERSIONS') && this.get('content.status') === 'CURRENT');
   }.property('content.status', 'isUpgrading'),
 
   /**