Closed Bug 396877 Opened 19 years ago Closed 19 years ago

Deleting a task from tasklist -> no agenda update

Categories

(Calendar :: Calendar Frontend, defect)

defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: andreas.treumann, Assigned: michael.buettner)

Details

Attachments

(1 file)

STEPS TO REPRODUCE: =================== 1. create a task with a start date 2. restart Thunderbird/Lightning 3. delete this task from the tasklist RESULT: ======= - no agenda update, the agenda shows the deleted task EXPECTED RESULT: ================ - the agenda should not display the deleted task REPRODUCIBLE: ============= - always Same scenario without the restart works.
Summary: Deleting a task from tasklist -> no update agenda → Deleting a task from tasklist -> no agenda update
I can confirm this but only for tasks with a start date in the past. This also explains the necessary restart to reproduce it, see Bug 394054. Right after creation past tasks are not displayed in the Agenda.
Attached patch patch v1 — — Splinter Review
The agenda gets notified but it fails to find the occurrence to delete since it starts the query with a date/time of the current time. It would well be the case that the items displayed in the agenda don't fall into this timespan.
Assignee: nobody → michael.buettner
Status: NEW → ASSIGNED
Attachment #281653 - Flags: review?(daniel.boelzle)
Comment on attachment 281653 [details] [diff] [review] patch v1 >- var occs = item.getOccurrencesBetween(this.agendaTreeView.today.start, >+ var queryStart = this.agendaTreeView.today.start.clone(); >+ queryStart.isDate = true; >+ var occs = item.getOccurrencesBetween(queryStart, > this.agendaTreeView.soon.end, {}); I know this works, but with respect bug 388656 (meaning essentially that DATE values don't/shouldn't specify a point in time), I'd prefer to explicitly set the time part to 0, i.e. queryStart.hour = 0; queryStart.minute = 0; queryStart.second = 0; r=dbo, but please try out the above approach whether it fixes the bug, too.
Attachment #281653 - Flags: review?(daniel.boelzle) → review+
(In reply to comment #3) > I know this works, but with respect bug 388656 (meaning essentially that DATE > values don't/shouldn't specify a point in time), I'd prefer to explicitly set > the time part to 0. Interestingly enough, this was indeed my first attempt but decided to set the date/time to date. But thinking twice, you're right. > but please try out the above approach whether it fixes the bug, too. That's needless to say, isn't it? :-)
patch checked in on trunk and MOZILLA_1_8_BRANCH -> FIXED
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
This patch doesn't fix the issue completely. The Agenda also shows task with a past start *date* and time in the Today section (Bug 394054). Deleting such a task in the Task list will not update the Agenda.
Target Milestone: --- → 0.7
Version: Trunk → unspecified
I think that the bug should be fixed in a different way: 1) When the today-pane shows the current date ("ShowsToday-mode) the "starttime" of the agenda-pane should be the current time and only events with a start or end-date after the current time should be displayed in the agenda-pane 2) 'Tomorrow' and "Soon" should always start at midnight. 3) if the today-pane is not in "ShowsToday-mode" all dates should start at midnight. Currently the agenda-pane does not reflect this behaviour.
I suggest to leave this issue as fixed and implement a common solution to bug 394054
Checked in latest nightly build -> task is fixed and verified.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: