LEFT | RIGHT |
1 'use strict'; | 1 'use strict'; |
2 | 2 |
3 | 3 |
4 /** | 4 /** |
5 * SubApp for the Browser | 5 * SubApp for the Browser |
6 * | 6 * |
7 * @module juju | 7 * @module juju |
8 * @submodule subapps | 8 * @submodule subapps |
9 * | 9 * |
10 */ | 10 */ |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 * @method renderCharmDetails | 274 * @method renderCharmDetails |
275 * @param {Request} req current request object. | 275 * @param {Request} req current request object. |
276 * @param {Response} res current response object. | 276 * @param {Response} res current response object. |
277 * @param {function} next callable for the next route in the chain. | 277 * @param {function} next callable for the next route in the chain. |
278 * | 278 * |
279 */ | 279 */ |
280 renderCharmDetails: function(req, res, next) { | 280 renderCharmDetails: function(req, res, next) { |
281 var charmID = req.params.id; | 281 var charmID = req.params.id; |
282 var extraCfg = { | 282 var extraCfg = { |
283 charmID: charmID, | 283 charmID: charmID, |
284 container: Y.Node.create('<div class="charmview"/>') | 284 container: Y.Node.create('<div class="charmview"/>'), |
| 285 deploy: this.get('deploy') |
285 }; | 286 }; |
286 | 287 |
287 // The details view needs to know if we're using a fullscreen template | 288 // The details view needs to know if we're using a fullscreen template |
288 // or the sidebar version. | 289 // or the sidebar version. |
289 if (this._viewState.viewmode === 'fullscreen') { | 290 if (this._viewState.viewmode === 'fullscreen') { |
290 extraCfg.isFullscreen = true; | 291 extraCfg.isFullscreen = true; |
291 } | 292 } |
292 | 293 |
293 // Gotten from the sidebar creating the cache. | 294 // Gotten from the sidebar creating the cache. |
294 var model = this._cacheCharms.getById(charmID); | 295 var model = this._cacheCharms.getById(charmID); |
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
539 }, | 540 }, |
540 | 541 |
541 /** | 542 /** |
542 @attribute urlNamespace | 543 @attribute urlNamespace |
543 @default 'charmstore' | 544 @default 'charmstore' |
544 @type {String} | 545 @type {String} |
545 | 546 |
546 */ | 547 */ |
547 urlNamespace: { | 548 urlNamespace: { |
548 value: 'charmstore' | 549 value: 'charmstore' |
549 } | 550 }, |
| 551 |
| 552 /** |
| 553 The "deploy" function prompts the user for service configuration and |
| 554 deploys a service. |
| 555 |
| 556 @attribute deploy |
| 557 @default undefined |
| 558 @type {Function} |
| 559 |
| 560 */ |
| 561 deploy: {} |
550 | 562 |
551 } | 563 } |
552 }); | 564 }); |
553 | 565 |
554 }, '0.1.0', { | 566 }, '0.1.0', { |
555 requires: [ | 567 requires: [ |
556 'juju-charm-store', | 568 'juju-charm-store', |
557 'juju-models', | 569 'juju-models', |
558 'querystring-parse', | 570 'querystring-parse', |
559 'sub-app', | 571 'sub-app', |
560 'subapp-browser-charmview', | 572 'subapp-browser-charmview', |
561 'subapp-browser-editorial', | 573 'subapp-browser-editorial', |
562 'subapp-browser-fullscreen', | 574 'subapp-browser-fullscreen', |
563 'subapp-browser-searchview', | 575 'subapp-browser-searchview', |
564 'subapp-browser-sidebar' | 576 'subapp-browser-sidebar' |
565 ] | 577 ] |
566 }); | 578 }); |
LEFT | RIGHT |