ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From onechipore...@apache.org
Subject ambari git commit: AMBARI-11387. Step7 is not loading because of js-error (onechiporenko)
Date Tue, 26 May 2015 10:08:36 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk d935afd25 -> d0580393b


AMBARI-11387. Step7 is not loading because of js-error (onechiporenko)


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

Branch: refs/heads/trunk
Commit: d0580393b31184ccf5cb62206fc5a9e87d4fd830
Parents: d935afd
Author: Oleg Nechiporenko <onechiporenko@apache.org>
Authored: Tue May 26 13:05:06 2015 +0300
Committer: Oleg Nechiporenko <onechiporenko@apache.org>
Committed: Tue May 26 13:08:00 2015 +0300

----------------------------------------------------------------------
 ambari-web/app/utils/config.js | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/d0580393/ambari-web/app/utils/config.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/utils/config.js b/ambari-web/app/utils/config.js
index a069a72..e324cf5 100644
--- a/ambari-web/app/utils/config.js
+++ b/ambari-web/app/utils/config.js
@@ -500,16 +500,18 @@ App.config = Em.Object.create({
     var mergedConfigs = [];
     var contentProperties = advancedConfigs ? this.createContentProperties(advancedConfigs)
: [];
     var preDefinedConfigs = this.get('preDefinedSiteProperties').concat(contentProperties);
-
+    var self = this;
     storedConfigs = (storedConfigs) ? storedConfigs : [];
 
     var preDefinedNames = preDefinedConfigs.mapProperty('name');
     var storedNames = storedConfigs.mapProperty('name');
     var names = preDefinedNames.concat(storedNames).uniq();
-    var configTypes = Em.keys(App.StackService.find().filter(function(service) {
+    var configTypes = App.StackService.find().filter(function(service) {
       return selectedServiceNames.contains(service.get('serviceName'));
-    }).mapProperty('configTypes'))
-      .uniq().compact().filter(function(configType) { return !!configType; });
+    }).map(function(item) {
+      return Em.keys(item.get('configTypes'));
+    }).reduce(function(p,c) { return p.concat(c); })
+    .uniq().compact().filter(function(configType) { return !!configType; });
 
     names.forEach(function (name) {
       var storedCfgs = storedConfigs.filterProperty('name', name);
@@ -517,7 +519,7 @@ App.config = Em.Object.create({
       var preDefinedConfig = preDefinedConfigs.filterProperty('name', name);
       preDefinedConfig.forEach(function (_preDefinedConfig) {
         if (selectedServiceNames.contains(_preDefinedConfig.serviceName) || _preDefinedConfig.serviceName
=== 'MISC') {
-          if (_preDefinedConfig.serviceName != 'MISC' && _preDefinedConfig.filename
&& !configTypes.contains(_preDefinedConfig.filename)) {
+          if (_preDefinedConfig.serviceName != 'MISC' && _preDefinedConfig.filename
&& !configTypes.contains(self.getConfigTagFromFileName(_preDefinedConfig.filename)))
{
             return;
           }
           preDefinedCfgs.push(_preDefinedConfig);


Mime
View raw message