[feat]Restrict fullcalendar to display time from the start hour to end hour of a conference
This commit is contained in:
parent
e9145f8940
commit
657c9fdfb8
2 changed files with 5 additions and 1 deletions
|
|
@ -4,7 +4,10 @@ $( document ).ready(function() {
|
||||||
let fullcalData = $('#fullcalendar');
|
let fullcalData = $('#fullcalendar');
|
||||||
|
|
||||||
var calendar = new FullCalendar.Calendar(calendarEl, {
|
var calendar = new FullCalendar.Calendar(calendarEl, {
|
||||||
|
expandRows: true,
|
||||||
allDaySlot: false,
|
allDaySlot: false,
|
||||||
|
slotMinTime: fullcalData.data('startHour') + ':00:00',
|
||||||
|
slotMaxTime: fullcalData.data('endHour') + ':00:00',
|
||||||
timeZone: 'UTC', // TODO: Events are stored in conference's timezone implicitly (UTC+0) in the database
|
timeZone: 'UTC', // TODO: Events are stored in conference's timezone implicitly (UTC+0) in the database
|
||||||
initialDate: fullcalData.data('day'),
|
initialDate: fullcalData.data('day'),
|
||||||
initialView: 'resourceTimeGridDay',
|
initialView: 'resourceTimeGridDay',
|
||||||
|
|
|
||||||
|
|
@ -6,4 +6,5 @@
|
||||||
= @conference.title
|
= @conference.title
|
||||||
|
|
||||||
#vert-schedule-full-calendar
|
#vert-schedule-full-calendar
|
||||||
#fullcalendar{ data: { rooms: @rooms, events: @event_schedules, day: @day } }
|
#fullcalendar{ data: { rooms: @rooms, events: @event_schedules, day: @day, |
|
||||||
|
'start-hour': @conference.start_hour, 'end-hour': @conference.end_hour } }
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue