mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-20 13:33:34 -07:00
Added toastr, fullcalendar, start of API for Calendar.
Sending headers for DownloadString and DownloadFile in addition to DownloadStream.
This commit is contained in:
parent
f568fdad6a
commit
6296e425d3
15 changed files with 5624 additions and 82 deletions
35
NzbDrone.Backbone/Calendar/CalendarCollectionView.js
Normal file
35
NzbDrone.Backbone/Calendar/CalendarCollectionView.js
Normal file
|
@ -0,0 +1,35 @@
|
|||
'use strict';
|
||||
|
||||
define(['app', 'Calendar/CalendarItemView'], function (app) {
|
||||
NzbDrone.Calendar.CalendarCollectionView = Backbone.Marionette.CompositeView.extend({
|
||||
itemView: NzbDrone.Calendar.CalendarItemView,
|
||||
template: 'Calendar/CalendarCollectionTemplate',
|
||||
itemViewContainer: 'table',
|
||||
|
||||
ui: {
|
||||
calendar: '#calendar'
|
||||
},
|
||||
|
||||
initialize: function () {
|
||||
this.collection = new NzbDrone.Calendar.CalendarCollection();
|
||||
this.collection.fetch();
|
||||
this.collection.bind('reset', this.addAll);
|
||||
},
|
||||
render: function() {
|
||||
this.ui.calendar.fullCalendar({
|
||||
header: {
|
||||
left: 'prev,next today',
|
||||
center: 'title',
|
||||
right: 'month,basicWeek,basicDay',
|
||||
ignoreTimezone: false
|
||||
},
|
||||
selectable: true,
|
||||
selectHelper: true,
|
||||
editable: true
|
||||
});
|
||||
},
|
||||
addAll: function(){
|
||||
this.el.fullCalendar('addEventSource', this.collection.toJSON());
|
||||
}
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue