Calendar planner view shows event title instead of timespan for events > 8 hours

This commit is contained in:
Nathan Gray 2016-04-18 19:03:35 +00:00
parent a77b41c651
commit 3b864e4e54
3 changed files with 25 additions and 3 deletions

View File

@ -402,9 +402,17 @@ var et2_calendar_event = (function(){ "use strict"; return et2_valueWidget.exten
}
visible_lines = Math.max(1,visible_lines);
if(this.getParent() && this.getParent().instanceOf(et2_calendar_daycol))
{
this.div.toggleClass('calendar_calEventSmall',visible_lines < 4);
this.div
.attr('data-visible_lines', visible_lines);
}
else if (this.getParent() && this.getParent().instanceOf(et2_calendar_planner_row))
{
// Less than 8 hours is small
this.div.toggleClass('calendar_calEventSmall',this.options.value.end_m - this.options.value.start_m < 480);
}
if(this.body.height() > this.div.height() - this.title.height() && visible_lines >= 4)

View File

@ -815,6 +815,12 @@ Hide subsequent headers in week view with non-consolidated owners
.calendar_calEventSmall .calendar_calEventBody {
padding-top: 4em;
}
.calendar_plannerRowWidget .calendar_calEvent:not(.calendar_calEventSmall) .calendar_calTimespan {
display: none;
}
.calendar_plannerRowWidget .calendar_calEvent:not(.calendar_calEventSmall) .calendar_calEventHeader .calendar_calEventTitle {
display: inline;
}
/* Events as displayed in a list, not sized by time */
.calendar_calTimeGridList .calendar_calTimeGridScroll {

View File

@ -792,6 +792,12 @@ Hide subsequent headers in week view with non-consolidated owners
.calendar_calTimeGrid:not(.calendar_calTimeGridList) .calendar_calEventSmall .calendar_calEventBody {
padding-top: 4em;
}
.calendar_plannerRowWidget .calendar_calEvent:not(.calendar_calEventSmall) .calendar_calTimespan {
display: none;
}
.calendar_plannerRowWidget .calendar_calEvent:not(.calendar_calEventSmall) .calendar_calEventHeader .calendar_calEventTitle {
display: inline;
}
/* Events as displayed in a list, not sized by time */
.calendar_calTimeGridList .calendar_calTimeGridScroll {
overflow-y: hidden;
@ -2532,3 +2538,5 @@ div#calendar-container div.calendar table tbody tr.rowhilite td {
#calendar_merge {
margin: 9px 0 0 0;
}
/* ########################################################################################
/* * Calendar END */