The default bug view has changed. See this FAQ.

Calendar events show up on wrong day when printing

RESOLVED FIXED in 4.0.0.1

Status

Calendar
Printing
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: Stephen.Ditch, Assigned: Decathlon)

Tracking

Lightning 3.3
4.0.0.1

Details

(Whiteboard: [timezone])

Attachments

(3 attachments, 1 obsolete attachment)

(Reporter)

Description

2 years ago
User Agent: Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; WOW64; Trident/6.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; .NET4.0C; .NET4.0E; InfoPath.3)

Steps to reproduce:

My timezone is set to America/New York.  I create an event on a single day to start at 8PM and end at 9PM


Actual results:

The event shows up on the correct day however when going to print either the Monthly Grid or the Weekly Planner the event shows up on the following day.  


Expected results:

The issue is at 8PM Eastern time is 12AM GMT(UTC) so the event is actually considing itself on the following day.  The time shows correct on the printout but the day is not compensating for the timezone making it appear on the following day from 8PM to 9PM

Comment 1

2 years ago
I currently can't reproduce this issue. Do you have calendar.icaljs (->config editor) enabled or disabled?
Flags: needinfo?(Stephen.Ditch)

Updated

2 years ago
Whiteboard: [timezone]
(Reporter)

Comment 2

2 years ago
calendar.icaljs is set to a value of false
Flags: needinfo?(Stephen.Ditch)
(Reporter)

Comment 3

2 years ago
Created attachment 8591636 [details]
New Event on calendar

Created for 8pm-9pm America/New York on April 23
(Reporter)

Comment 4

2 years ago
Created attachment 8591637 [details]
newevent-calendarprintviews.png

Only the list view shows the event on the correct day (April 23) the weekly planner and monthly grid move the event to the following day (April 24)
(Reporter)

Comment 5

2 years ago
ics data for the calendar event (April 23 from 8pm to 9pm America/New York)

BEGIN:VCALENDAR
PRODID:-//Mozilla.org/NONSGML Mozilla Calendar V1.1//EN
VERSION:2.0
BEGIN:VEVENT
CREATED:20150413T125116Z
LAST-MODIFIED:20150413T125154Z
DTSTAMP:20150413T125154Z
UID:2caf0f7c-9b33-4e64-b7a9-7da46e965646
SUMMARY:New Event
PRIORITY:5
DTSTART:20150424T000000Z
DTEND:20150424T010000Z
SEQUENCE:0
X-MICROSOFT-CDO-BUSYSTATUS:BUSY
END:VEVENT
END:VCALENDAR
(Reporter)

Comment 6

2 years ago
Also able to replicate this issue with with Thunderbird 38.0 beta 3 with Lightning 4.0b3
(Assignee)

Comment 7

2 years ago
I can confirm this behavior but I think it has already been reported before, though I'm not able to find a previous bug.

To reproduce:
- set the timezone in Lightning to America/New York;
- import the calendar in comment 5;
- display the print dialog with the Weekly Planner layout and set the Custom date range in the week with the event.

It is caused by the fact that the day boxes in the Weekly layout have the default timezone (America/New york), instead the events are placed inside the day with their own timezone (UTC) but show the start/end time with the default timezone.
Assignee: nobody → bv1578
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
(Assignee)

Updated

2 years ago
Duplicate of this bug: 1163123
(Assignee)

Comment 9

2 years ago
Created attachment 8604532 [details] [diff] [review]
patch - v1

The boxDateKey variable gets a wrong value and the items get placed in wrong position inside the dayTable without the timezone correction.
Attachment #8604532 - Flags: review?(philipp)
(Reporter)

Comment 10

2 years ago
(In reply to Decathlon from comment #9)
> Created attachment 8604532 [details] [diff] [review]
> patch - v1
> 
> The boxDateKey variable gets a wrong value and the items get placed in wrong
> position inside the dayTable without the timezone correction.

I can confirm the patch worked correctly on Thunderbird 24.2.0 with Lightning 2.6.4. for the Weekly Planner.  A similar change will also need to be done with calMonthGridPrinter.js as the Monthly Grid has the same original issue.

I will next test the patch on Thunderbird 38.0b4 with Lightning 4.0b3
(Assignee)

Comment 11

2 years ago
Comment on attachment 8604532 [details] [diff] [review]
patch - v1

(In reply to Stephen.Ditch from comment #10)
>  A similar change will also need to
> be done with calMonthGridPrinter.js as the Monthly Grid has the same
> original issue.

You are right, I will attach an updated patch.
Attachment #8604532 - Flags: review?(philipp)
(Reporter)

Comment 12

2 years ago
For some reason I can't get the same patch to work with Thunderbird 38.0b4 with Lightning 4.0b4.  The calendar events after 8pm are showing up on the following day.  Patch worked perfect on 24.2.0 with Lightning 2.6.4, strange.
(Reporter)

Comment 13

2 years ago
(In reply to Stephen.Ditch from comment #12)
> For some reason I can't get the same patch to work with Thunderbird 38.0b4
> with Lightning 4.0b4.  The calendar events after 8pm are showing up on the
> following day.  Patch worked perfect on 24.2.0 with Lightning 2.6.4, strange.

Correction, the patch DOES work on Thunderbird 38.0b4 with Lightning 4.0b4.  There was some confusion with the new integration of Lightning in the distribution\extensions folder as this copied the pre-patched calWeekPrinter.js to the profile.  Once I copied the updated file to the individual profile, it functioned correctly.
(Assignee)

Comment 14

2 years ago
Created attachment 8606711 [details] [diff] [review]
patch-v2

The monthly grid needs exactly the same adjustment about timezones.
Attachment #8604532 - Attachment is obsolete: true
Attachment #8606711 - Flags: review?(philipp)
Attachment #8606711 - Flags: review?(philipp) → review+
Comment on attachment 8606711 [details] [diff] [review]
patch-v2

Review of attachment 8606711 [details] [diff] [review]:
-----------------------------------------------------------------

I'm also fine taking this for beta, if we are quick.
Attachment #8606711 - Flags: approval-calendar-beta+
Attachment #8606711 - Flags: approval-calendar-aurora+
Keywords: checkin-needed
(Reporter)

Comment 16

2 years ago
Tested patch-v2 on Thunderbird 38.0b4 with Lightning 4.0b4, and events after 8PM on both the Monthly Grid and Weekly Planner are displaying on the correct day!  Thanks!
Pushed to comm-central changeset bf2473395e2b
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 4.3
Backported to releases/comm-aurora changeset 10ff342eb381
Target Milestone: 4.3 → 4.2
Backported to releases/comm-beta changeset 3450fc9588a9
Target Milestone: 4.2 → 4.1
Backported to releases/comm-beta changeset 05001d19f200 (THUNDERBIRD_38_VERBRANCH)
Target Milestone: 4.1 → 4.0
You need to log in before you can comment on or make changes to this bug.