Repository: ambari Updated Branches: refs/heads/branch-1.6.1 bb9ec2a49 -> aa698147f
AMBARI-6313. Add Host wizard: Browser Refresh is not handled gracefully. (jaimin) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/aa698147 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/aa698147 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/aa698147 Branch: refs/heads/branch-1.6.1 Commit: aa698147fba78af8c5e1d479dea4783bbfd82278 Parents: bb9ec2a Author: Jaimin Jetly <jai...@hortonworks.com> Authored: Mon Jul 7 15:04:57 2014 -0700 Committer: Jaimin Jetly <jai...@hortonworks.com> Committed: Mon Jul 7 15:05:11 2014 -0700 ---------------------------------------------------------------------- ambari-web/app/controllers/main/host/add_controller.js | 4 ++-- ambari-web/app/views/main/host/add_view.js | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/aa698147/ambari-web/app/controllers/main/host/add_controller.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/controllers/main/host/add_controller.js b/ambari-web/app/controllers/main/host/add_controller.js index 4ec6920..058cfe2 100644 --- a/ambari-web/app/controllers/main/host/add_controller.js +++ b/ambari-web/app/controllers/main/host/add_controller.js @@ -346,11 +346,11 @@ App.AddHostController = App.WizardController.extend({ this.loadServices(); this.loadMasterComponentHosts(); this.loadSlaveComponentHosts(); - this.load('hosts',true); + this.load('hosts'); case '2': this.loadServices(); case '1': - this.load('hosts',true); + this.load('hosts'); this.load('installOptions'); this.load('cluster'); } http://git-wip-us.apache.org/repos/asf/ambari/blob/aa698147/ambari-web/app/views/main/host/add_view.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/views/main/host/add_view.js b/ambari-web/app/views/main/host/add_view.js index 0faeb76..8f3cae1 100644 --- a/ambari-web/app/views/main/host/add_view.js +++ b/ambari-web/app/views/main/host/add_view.js @@ -58,7 +58,11 @@ App.AddHostView = Em.View.extend({ }, willInsertElement: function () { - this.loadHosts(); + if (this.get('controller').getDBProperty('hosts')) { + this.set('isLoaded', true); + } else { + this.loadHosts(); + } }, loadHosts: function () {