Files
dss/static/js/app/views/activity/activityListView.js
2013-06-19 19:24:50 +01:00

47 lines
1.7 KiB
JavaScript
Executable File

// Generated by CoffeeScript 1.6.2
(function() {
var __hasProp = {}.hasOwnProperty,
__extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
define(['marionette', 'models/activity/activityCollection', 'views/activity/activityItemView', 'text!/tpl/ActivityListView'], function(Marionette, ActivityCollection, ActivityItemView, Template) {
var ActivityListView, _ref;
ActivityListView = (function(_super) {
__extends(ActivityListView, _super);
function ActivityListView() {
_ref = ActivityListView.__super__.constructor.apply(this, arguments);
return _ref;
}
ActivityListView.prototype.template = _.template(Template);
ActivityListView.prototype.tagName = "ul";
ActivityListView.prototype.className = "activity-listing media-list";
ActivityListView.prototype.itemView = ActivityItemView;
ActivityListView.prototype.itemViewContainer = "#activity-list-container-ul";
ActivityListView.prototype.initialize = function() {
var _this = this;
console.log("ActivityListView: initialize");
this.collection = new ActivityCollection;
this.collection.fetch({
success: function() {
console.log("ActivityListView: Collection fetched");
console.log(_this.collection);
}
});
};
return ActivityListView;
})(Marionette.CompositeView);
return ActivityListView;
});
}).call(this);