2014-07-26 09:01:53 +00:00
|
|
|
define(function (require) {
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
var $ = require('jquery'),
|
|
|
|
_ = require('underscore'),
|
|
|
|
Backbone = require('backbone'),
|
|
|
|
Marionette = require('marionette'),
|
2015-08-15 15:12:50 +00:00
|
|
|
UploadView = require('app/views/missions/upload'),
|
|
|
|
WorkshopView = require('app/views/missions/workshop'),
|
2014-07-26 09:01:53 +00:00
|
|
|
ListView = require('app/views/missions/list'),
|
|
|
|
tpl = require('text!tpl/missions/index.html');
|
|
|
|
|
2017-10-05 20:55:57 +00:00
|
|
|
return Marionette.LayoutView.extend({
|
2014-07-26 09:01:53 +00:00
|
|
|
template: _.template(tpl),
|
|
|
|
|
|
|
|
regions: {
|
2015-08-15 15:12:50 +00:00
|
|
|
uploadView: "#upload",
|
|
|
|
workshopView: "#workshop",
|
2014-07-26 09:01:53 +00:00
|
|
|
listView: "#list",
|
|
|
|
},
|
|
|
|
|
|
|
|
onRender: function() {
|
2015-08-15 15:12:50 +00:00
|
|
|
this.uploadView.show(new UploadView({missions: this.options.missions}));
|
|
|
|
this.workshopView.show(new WorkshopView({missions: this.options.missions}));
|
2014-07-26 09:01:53 +00:00
|
|
|
this.listView.show(new ListView({collection: this.options.missions}));
|
|
|
|
},
|
|
|
|
});
|
|
|
|
|
|
|
|
});
|