arma-server-web-admin/public/js/app/views/mods/list.js

28 lines
713 B
JavaScript
Raw Normal View History

2014-02-09 03:19:48 +00:00
define(function (require) {
2014-04-05 19:36:34 +00:00
2014-02-09 03:19:48 +00:00
"use strict";
2014-04-05 19:36:34 +00:00
2014-02-09 03:19:48 +00:00
var $ = require('jquery'),
_ = require('underscore'),
Backbone = require('backbone'),
Marionette = require('marionette'),
2014-04-05 19:36:34 +00:00
ListItemView = require('app/views/mods/list_item'),
tpl = require('text!tpl/mods/list.html'),
template = _.template(tpl);
return Marionette.CompositeView.extend({
2014-02-09 03:19:48 +00:00
itemView: ListItemView,
2014-04-05 19:36:34 +00:00
itemViewContainer: "tbody",
template: template,
initialize: function (options) {
this.on("itemview:mods:update", this.update, this);
},
update: function() {
this.collection.fetch();
},
2014-02-09 03:19:48 +00:00
});
});