Problem/Motivation
Currently, when a date is stored into search api it is converted to UTC properly, but never converted back properly.
This stems from getDateRangeFromOccurrenceDeltaIdentifier() where we get the UTC time and, without properly initializing a new daterange, tell it that it's timezone is something else. This can be remedied by passing the UTC timezone as the 3rd argument in \DateTime::createFromFormat.
Steps to reproduce
- Set up an index using occurrences
- Set up a view to display occurrence times
- Look at search results and see time is off (in my case by 4 hours - EDT)
Proposed resolution
Pass UTC timezone during initialization of the datetime, then convert it to the site's timezone.
Issue fork smart_date_recur_search_api-3578625
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
nickdjm