Repository: ambari Updated Branches: refs/heads/trunk 29d301099 -> 7f0ef185c
AMBARI-9978. Installer Step 3: User is blocked on step 3 due to js error, back and next buttons disabled (alexantonenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/7f0ef185 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/7f0ef185 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/7f0ef185 Branch: refs/heads/trunk Commit: 7f0ef185c5d218eee19efe9b36864e26e312d916 Parents: 29d3010 Author: Alex Antonenko <[email protected]> Authored: Sun Mar 8 13:13:12 2015 +0200 Committer: Alex Antonenko <[email protected]> Committed: Sun Mar 8 18:31:51 2015 +0200 ---------------------------------------------------------------------- ambari-web/app/controllers/wizard/step3_controller.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/7f0ef185/ambari-web/app/controllers/wizard/step3_controller.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/controllers/wizard/step3_controller.js b/ambari-web/app/controllers/wizard/step3_controller.js index 796438d..21f9e33 100644 --- a/ambari-web/app/controllers/wizard/step3_controller.js +++ b/ambari-web/app/controllers/wizard/step3_controller.js @@ -1005,9 +1005,10 @@ App.WizardStep3Controller = Em.Controller.extend({ if (data.Requests.inputs.indexOf("last_agent_env_check") != -1) { this.set('stopChecking', true); this.set('hostsPackagesData', data.tasks.map(function (task) { + var installed_packages = Em.get(task, 'Tasks.structured_out.installed_packages'); return { hostName: Em.get(task, 'Tasks.host_name'), - installedPackages: Em.get(task, 'Tasks.structured_out.installed_packages') + installedPackages: installed_packages ? installed_packages : [] } })); this.getHostInfo(); @@ -1479,9 +1480,9 @@ App.WizardStep3Controller = Em.Controller.extend({ }, this); //parse all package warnings for host - var hostPackagesData = hostsPackagesData.findProperty('hostName', _host.Hosts.host_name); - if (hostPackagesData) { - hostPackagesData.installedPackages.forEach(function (_package) { + var _hostPackagesData = hostsPackagesData.findProperty('hostName', _host.Hosts.host_name); + if (_hostPackagesData) { + _hostPackagesData.installedPackages.forEach(function (_package) { warning = warningCategories.packagesWarnings[_package.name]; if (warning) { warning.hosts.push(_host.Hosts.host_name);
