In my xml file I have two sets of start and end dates for each event.
Set 1 is the normal start_date , end_date
Set 2 simulates all-day event (full day) except where event is multi-day
I would like to use the dates from Set 2 to force displaying events as full day events in Timeline view, but use Set 1 dates everywhere else in the calendar…
If this is not possible, how can I modify timeline js script to always display events as if they were full day events?
function _getX(ev, isEndPoint, step) {
var x = 0;
var date = (isEndPoint) ? ev.timelineend : ev.timelinestart;
if(date.valueOf()>scheduler._max_date.valueOf())
date = scheduler._max_date;
var delta = date - scheduler._min_date_timeline;
if (delta<0) {
column_offset = 0;
} else {
var index = Math.round( delta/(step*scheduler._cols[0]) ); // results varies ~0.9 - ~24.17, e.g. that way we get 1 and 24
if(index>scheduler._cols.length) // if columns really small it's possible to get incorrect index
index = scheduler._cols.length;
for (var k=0; k<index; k++) {
x += scheduler._cols[k];
}
var column_date = scheduler.date.add(scheduler._min_date_timeline, scheduler.matrix[scheduler._mode].x_step*index, scheduler.matrix[scheduler._mode].x_unit);
delta = date - column_date;
var column_offset = Math.floor(delta/step);
}
x += (isEndPoint) ? column_offset-14 : column_offset+1;
return x;
}
but the events now overlap each other across days… hmm. some more experimentation needed methinks… good start for me to build on though.
aha, figured out what is now causing the overlap (which was greatly reduced by your code mods, thank you!). It appears the events are now the exact length they have to be to fit the entire event_text in. I have obviously made a booboo in the css somewhere.