search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

DayBeginsHour

Asked by Anonymous
8 years ago.

I would like to set the start time of the calendar to be h:mm. I need the calendar to start at partial hours like 6:45 and set intervals of 20 minutes. The start of the calendar day may be any time but the interval should continue from that time.

Answer posted by Dan Letecky [DayPilot]
8 years ago.

Unfortunately minute precision for the calendar start is not supported in the Calendar at the moment. In the Scheduler you can create a custom timeline (http://doc.daypilot.org/scheduler/timeline/) with an arbitrary start.

Answer posted by Anonymous
8 years ago.

That's what I thought. I figured out a workaround though that will get me by since the startHour will accept a decimal. I needed a timeslot to put events that were booked before the start of day since these were imported from another source.

var intervalMinutes = 18;
var intervalDecimalEquiv = 1 - (intervalMinutes / 60);
var startHour = parseFloat((startTime.hour() - 1) + intervalDecimalEquiv);

This allows me to determine the day start to allow one slot "before Day" to put events booked before the start of day. I can then change the event start of any event starting before the start of day to match this new slot.

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.