Explorar el Código

AMBARI-3511. Reassign Master: Reusing the wizard has stale values from last iteration of the wizard. (akovalenko)

Aleksandr Kovalenko hace 11 años
padre
commit
84f491ca19

+ 2 - 2
ambari-web/app/controllers/main/service/reassign/step4_controller.js

@@ -32,9 +32,9 @@ App.ReassignMasterWizardStep4Controller = App.HighAvailabilityProgressPageContro
 
   loadStep: function () {
     if (this.get('content.reassign.component_name') === 'NAMENODE' && !App.HostComponent.find().someProperty('componentName', 'SECONDARY_NAMENODE')) {
-      this.get('hostComponents').pushObjects(['NAMENODE', 'ZKFC']);
+      this.set('hostComponents', ['NAMENODE', 'ZKFC']);
     } else {
-      this.get('hostComponents').pushObject(this.get('content.reassign.component_name'));
+      this.set('hostComponents', [this.get('content.reassign.component_name')]);
     }
     this._super();
   },

+ 2 - 2
ambari-web/app/controllers/main/service/reassign/step6_controller.js

@@ -32,9 +32,9 @@ App.ReassignMasterWizardStep6Controller = App.HighAvailabilityProgressPageContro
 
   loadStep: function () {
     if (this.get('content.reassign.component_name') === 'NAMENODE' && !App.HostComponent.find().someProperty('componentName', 'SECONDARY_NAMENODE')) {
-      this.get('hostComponents').pushObjects(['NAMENODE', 'ZKFC']);
+      this.set('hostComponents', ['NAMENODE', 'ZKFC']);
     } else {
-      this.get('hostComponents').pushObject(this.get('content.reassign.component_name'));
+      this.set('hostComponents', [this.get('content.reassign.component_name')]);
     }
     this._super();
   },