Homec4science

Prepare event dates for EditEngine/API

Authored by epriestley <git@epriestley.com> on Jul 12 2016, 00:29.

Description

Prepare event dates for EditEngine/API

Summary:
Ref T9275. Currently, the "Start Date", "End Date", and "Recurrence End Date" transcations take a complex value (AphrontFormDateControlValue) and reduce it to an epoch.

Do this a little earlier, since the API will be much more usable if it just passes in epoch timestamps.

Events also have some logic where they rewrite the from date and to date on the actual object for all day events, then undo the changes later. Specifically, if you have an all-day event on "July 24th", the exact start and end times vary based on who is looking at it. Instead of overwriting the persistent dateFrom and dateTo properties, add separate viewer properties to make it easier to keep this stuff straight.

Since this means all-day events get stored in UTC, we need to query/fetch (and then discard) slightly more events. This is perfectly and much simpler to do.

The one weird "UTC" hack in here will get nuked when this moves to EditEngine properly.

Test Plan: Edited times for normal events and all-day events.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T9275

Differential Revision: https://secure.phabricator.com/D16274

Details

Committed
epriestley <git@epriestley.com>Jul 13 2016, 16:42
Pushed
aubortJan 31 2017, 17:16
Parents
rPH3a09bb577e0a: Create separate "Accept" and "Decline" transactions for Calendar
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHc09e87073311: Prepare event dates for EditEngine/API (authored by epriestley <git@epriestley.com>).Jul 13 2016, 16:42