Browse Source

AMBARI-16993. Misc fixes related to slider while enabling interactive query. (jaimin)

Jaimin Jetly 9 years ago
parent
commit
26d00d9805

+ 1 - 0
ambari-web/app/controllers/wizard/step7/assign_master_controller.js

@@ -158,6 +158,7 @@ App.AssignMasterOnStep7Controller = Em.Controller.extend(App.BlueprintMixin, App
         var value = config.get('initialValue');
         config.set('value', value);
         configWidgetContext.setValue(value);
+        configWidgetContext.sendRequestRorDependentConfigs(config);
         this._super();
       },
       secondary: null,

+ 1 - 1
ambari-web/app/mixins/main/service/configs/component_actions_by_configs.js

@@ -259,7 +259,7 @@ App.ComponentActionsByConfigs = Em.Mixin.create({
 
     return  {
       "type": 'PUT',
-      "uri": App.get('apiPrefix') + "/clusters/" + App.get('clusterName') + "/host_components",
+      "uri": App.get('apiPrefix') + "/clusters/" + App.get('clusterName') + "/hosts/" + hostName + "/host_components",
       "RequestBodyInfo": {
         "RequestInfo": {
           "context": context,

+ 4 - 1
ambari-web/test/controllers/wizard/step7/assign_master_controller_test.js

@@ -148,13 +148,15 @@ describe('App.AssignMasterOnStep7Controller', function () {
         displayName: 'c1'
       }),
       setValue: Em.K,
-      toggleProperty: Em.K
+      toggleProperty: Em.K,
+      sendRequestRorDependentConfigs: Em.K
     });
 
     beforeEach(function() {
       sinon.stub(stringUtils, 'getFormattedStringFromArray');
       sinon.stub(mock, 'setValue');
       sinon.stub(mock, 'toggleProperty');
+      sinon.stub(mock, 'sendRequestRorDependentConfigs');
       sinon.spy(App.ModalPopup, 'show');
     });
 
@@ -162,6 +164,7 @@ describe('App.AssignMasterOnStep7Controller', function () {
       stringUtils.getFormattedStringFromArray.restore();
       mock.setValue.restore();
       mock.toggleProperty.restore();
+      mock.sendRequestRorDependentConfigs.restore();
       App.ModalPopup.show.restore();
     });