From: Jan Schneider Date: Thu, 24 Jun 2010 21:37:06 +0000 (+0200) Subject: Fix some issues with the agenda view. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=94c27575fb95330bd6104c79c41215a54b9f7fc3;p=horde.git Fix some issues with the agenda view. --- diff --git a/kronolith/js/kronolith.js b/kronolith/js/kronolith.js index a7916f57c..fd8ccae83 100644 --- a/kronolith/js/kronolith.js +++ b/kronolith/js/kronolith.js @@ -1168,7 +1168,7 @@ KronolithCore = { loadCalendar: function(type, calendar) { if (Kronolith.conf.calendars[type][calendar].show && - $w('day week month year').include(this.view)) { + $w('day week month year agenda').include(this.view)) { var dates = this.viewDates(this.date, this.view); this.deleteCache(null, [type, calendar]); this.loadEvents(dates[0], dates[1], this.view, [[type, calendar]]); @@ -1194,6 +1194,7 @@ KronolithCore = { switch (this.view) { case 'month': + case 'agenda': if (Object.isUndefined(this.ecache.get(type)) || Object.isUndefined(this.ecache.get(type).get(calendar))) { this.loadCalendar(type, calendar); @@ -1201,7 +1202,7 @@ KronolithCore = { var allEvents = $('kronolithBody').select('div').findAll(function(el) { return el.retrieve('calendar') == type + '|' + calendar; }); - if (Kronolith.conf.max_events) { + if (this.view == 'month' && Kronolith.conf.max_events) { var dates = this.viewDates(this.date, this.view); if (elt.hasClassName('kronolithCalOff')) { var day, more, events, calendars = []; @@ -1427,6 +1428,7 @@ KronolithCore = { if (this.view == 'day' || this.view == 'week' || this.view == 'month' || + this.view == 'agenda' || (this.view == 'year' && !$H(this.eventsLoading).size())) { this.insertEvents(dates, this.view, r.response.cal); } @@ -1506,7 +1508,7 @@ KronolithCore = { } this.holidays.push(event.key); } - if (Kronolith.conf.max_events) { + if (view == 'month' && Kronolith.conf.max_events) { more = $('kronolithMonthDay' + date).down('.kronolithMore'); if (more) { more.purge();