From ea5ec6b78771ae4c8b9b552a5ab3a03e04ebe7b4 Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Mon, 27 Oct 2014 15:02:21 +0000 Subject: [PATCH] Set show calendar body description according to calendar interval --- calendar/inc/class.calendar_uiviews.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/calendar/inc/class.calendar_uiviews.inc.php b/calendar/inc/class.calendar_uiviews.inc.php index 7e2f23d1c3..b40e202ec5 100644 --- a/calendar/inc/class.calendar_uiviews.inc.php +++ b/calendar/inc/class.calendar_uiviews.inc.php @@ -1809,9 +1809,9 @@ class calendar_uiviews extends calendar_ui (isset($data['border']) ? '&border='.urlencode($data['border']) : '')); } */ - // Add event description to cal event view body if the event is long enough (3 hours or whole day event) + // Add event description to cal event view body if the event is long enough (ATM 3 times longer than interval) // to be able to show some lines of description text - if ($event['whole_day'] || ($event['end'] - $event['start']) >= 10800) + if ($event['whole_day'] || ($event['end'] - $event['start']) > ($this->cal_prefs['interval'] * 3 * 60)) { $tpl->set_var('bodydescription', !$is_private ? nl2br(html::htmlspecialchars($event['description'])) : ''); }