modal region is loaded by controller

This commit is contained in:
Keivan Beigi 2013-07-19 16:08:41 -07:00
commit bb86e20bed
3 changed files with 15 additions and 14 deletions

View file

@ -1,11 +1,12 @@
'use strict';
define(
[
'app',
'$',
'marionette',
'bootstrap'
], function ($, Marionette) {
return Marionette.Region.extend({
], function (app, $, Marionette) {
var region = Marionette.Region.extend({
el: '#modal-region',
constructor: function () {
@ -37,4 +38,12 @@ define(
}
});
app.addInitializer(function () {
app.addRegions({
modalRegion : region
});
});
return region;
});