From: Jan Schneider Date: Sun, 21 Feb 2010 22:21:36 +0000 (+0100) Subject: Fix sorting days in agenda view. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=df7c27998ee61f470d9f4679bc6862dd2d6d69de;p=horde.git Fix sorting days in agenda view. --- diff --git a/kronolith/js/kronolith.js b/kronolith/js/kronolith.js index 23873e19c..b96ece905 100644 --- a/kronolith/js/kronolith.js +++ b/kronolith/js/kronolith.js @@ -663,21 +663,21 @@ KronolithCore = { // Create a copy of the row template. var body = $('kronolithViewAgendaBody'), row = $('kronolithAgendaTemplate').cloneNode(true); - row.removeAttribute('id'); // Fill week number and day cells. - row.down() + row.store('date', date) + .down() .setText(this.parseDate(date).toString('D')) - .store('date', date) .next() .writeAttribute('id', 'kronolithAgendaDay' + date); + row.removeAttribute('id'); // Insert row. var nextRow; body.childElements().each(function(elm) { - if (elm.down().retrieve('date') > date) { + if (elm.retrieve('date') > date) { nextRow = elm; - return; + throw $break; } }); if (nextRow) {