| Index: app/views/ghost-inspector.js |
| === modified file 'app/views/ghost-inspector.js' |
| --- app/views/ghost-inspector.js 2013-08-14 15:31:50 +0000 |
| +++ app/views/ghost-inspector.js 2013-08-26 14:16:34 +0000 |
| @@ -121,13 +121,22 @@ |
| container, '.service-config .config-field'); |
| } |
| + // Deploy needs constraints in simple key:value object. |
| + var constraints = utils.getElementsValuesMapping( |
| + container, '.constraint-field'); |
| + |
| options.env.deploy( |
| model.get('id'), |
| serviceName, |
| config, |
| this.viewletManager.configFileContent, |
| numUnits, |
| - Y.bind(this._deployCallbackHandler, this, serviceName, config)); |
| + constraints, |
| + Y.bind(this._deployCallbackHandler, |
| + this, |
| + serviceName, |
| + config, |
| + constraints)); |
| }, |
| /** |
| @@ -225,10 +234,10 @@ |
| @method _deployCallbackHandler |
| @param {String} serviceName The service name. |
| - @param {Object} config The configuration oject of the service. |
| + @param {Object} config The configuration object of the service. |
| @param {Y.EventFacade} e The event facade from the deploy event. |
| */ |
| - _deployCallbackHandler: function(serviceName, config, e) { |
| + _deployCallbackHandler: function(serviceName, config, constraints, e) { |
| var options = this.options, |
| db = options.db, |
| ghostService = options.ghostService; |
| @@ -283,7 +292,8 @@ |
| id: serviceName, |
| pending: false, |
| loading: false, |
| - config: config |
| + config: config, |
| + constraints: constraints |
| }); |
| this.closeInspector(); |
| @@ -291,4 +301,7 @@ |
| }; |
| +}, '0.1.0', { |
| + requires: [ |
| + ] |
| }); |