Updated Branches:
  refs/heads/trunk 2a04b7a42 -> 22b35866e

AMBARI-3255. Read-only views of security admin tab became editable after 
visiting other tabs on admin page. (onechiporenko)


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

Branch: refs/heads/trunk
Commit: 22b35866ede3f0f261e7eefc14f807fd0797138c
Parents: 2a04b7a
Author: Oleg Nechiporenko <[email protected]>
Authored: Tue Sep 17 13:51:40 2013 +0300
Committer: Oleg Nechiporenko <[email protected]>
Committed: Tue Sep 17 14:06:13 2013 +0300

----------------------------------------------------------------------
 ambari-web/app/templates/common/configs/service_config.hbs | 2 +-
 ambari-web/app/views/common/configs/services_config.js     | 8 +++++---
 2 files changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/22b35866/ambari-web/app/templates/common/configs/service_config.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/common/configs/service_config.hbs 
b/ambari-web/app/templates/common/configs/service_config.hbs
index fc7e554..cee34b6 100644
--- a/ambari-web/app/templates/common/configs/service_config.hbs
+++ b/ambari-web/app/templates/common/configs/service_config.hbs
@@ -26,7 +26,7 @@
                <i class="icon-caret-right pull-left"></i>
              {{/if}}
              <i class="icon-refresh"></i>
-             <strong>Restart Service</strong> 
{{selectedService.restartRequiredMessage}}
+             <strong>{{t 
dashboard.services.configs.popup.restartService.header}}</strong> 
{{selectedService.restartRequiredMessage}}
          </div>
          <div class="service-body">
            <ul>

http://git-wip-us.apache.org/repos/asf/incubator-ambari/blob/22b35866/ambari-web/app/views/common/configs/services_config.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/common/configs/services_config.js 
b/ambari-web/app/views/common/configs/services_config.js
index 6f01a02..f87d58f 100644
--- a/ambari-web/app/views/common/configs/services_config.js
+++ b/ambari-web/app/views/common/configs/services_config.js
@@ -273,9 +273,7 @@ App.ServiceConfigsByCategoryView = Ember.View.extend({
     var configs = this.get('serviceConfigs');
     var canEdit = this.get('canEdit');
     if (!canEdit && configs) {
-      configs.forEach(function (config) {
-        config.set('isEditable', false);
-      });
+      configs.setEach('isEditable', false);
     }
   },
 
@@ -352,11 +350,15 @@ App.ServiceConfigsByCategoryView = Ember.View.extend({
 
   didInsertElement: function () {
     var isCollapsed = (this.get('category.name').indexOf('Advanced') != -1);
+    var self = this;
     this.set('category.isCollapsed', isCollapsed);
     if (isCollapsed) {
       this.$('.accordion-body').hide();
     }
     this.updateReadOnlyFlags();
+    Em.run.next(function() {
+      self.updateReadOnlyFlags();
+    });
   },
   childView: App.ServiceConfigsOverridesView,
   changeFlag: Ember.Object.create({

Reply via email to