Last Comment Bug 787537 - Events that span two or more days are shown incorrect in print output (only shown on first day and with wrong time)
: Events that span two or more days are shown incorrect in print output (only s...
: regression
Product: Calendar
Classification: Client Software
Component: Printing (show other bugs)
: Lightning 1.7
: All All
: -- normal with 1 vote (vote)
: 1.8
Assigned To: Stefan Sitter
: 797855 (view as bug list)
Depends on:
Blocks: 757902
  Show dependency treegraph
Reported: 2012-08-31 12:26 PDT by Stefan Sitter
Modified: 2012-10-04 07:42 PDT (History)
3 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---

regression fix (print on all days) (5.32 KB, patch)
2012-09-06 13:01 PDT, Stefan Sitter
philipp: review+
philipp: approval‑calendar‑aurora+
philipp: approval‑calendar‑beta+
Details | Diff | Splinter Review

Description Stefan Sitter 2012-08-31 12:26:06 PDT
An event that spans two or more days (e.g. 2012-08-30 20:00 to 2012-09-02 12:00) is shown incorrect in "Monthly Grid" and "Weekly Planner" print output.

Actual results:
Event is only shown on 2012-08-30 as "20:00-12:00 Title". This is wrong.

Expected result:
Event should be shown on every day 08-30 to 09-02 and with correct start and end time for this day.
Comment 1 Rene Matteau 2012-09-03 13:06:58 PDT
In our case, the printing (monthly view), a 3 days recurring all day event will print only on the first day as: "All Day-All Day Event name".

A fix would be appreciated. Thanks...
Comment 2 Stefan Sitter 2012-09-06 13:01:15 PDT
Created attachment 658971 [details] [diff] [review]
regression fix (print on all days)

Patch ensures that the event/task is printed on all days. I had to add some special treatment to cover all cases like end time < start time (e.g. 2012-08-30 20:00 to 2012-09-02 12:00) or to not include an additional day for all-day events.
Comment 3 Philipp Kewisch [:Fallen] 2012-09-21 05:58:49 PDT
Comment on attachment 658971 [details] [diff] [review]
regression fix (print on all days)

r=philipp, thanks for the patch!

Very minor nit, could you change:

+            if ( !itemStartDate && !itemEndDate ) {

+            if (!itemStartDate && !itemEndDate) {
Comment 4 Stefan Sitter 2012-09-21 11:04:42 PDT
Pushed to
Comment 5 Stefan Sitter 2012-09-21 11:05:28 PDT
Pushed to
Comment 6 Stefan Sitter 2012-09-21 11:05:51 PDT
Pushed to
Comment 7 Stefan Sitter 2012-10-04 07:42:12 PDT
*** Bug 797855 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.