banana
banana copied to clipboard
Timepicker UTC
Up until this commit 6 months ago:
https://github.com/LucidWorks/banana/commit/1701a62a58048654e086d642ac259533fa6fedae
In the timepicker module the function time_calc() was using moment.utc when getting the date from the time picker control. There are actually still comments in there saying that moment.utc actually fixes some previous bugs. However this was changed six months ago and is actually causing an issue since all of my solr times are stored UTC. When time_cal goes to calculate the to and from the times are incorrect because it is no longer converting to UTC.
Was this just an oversight or was it a purposeful change?
Currently, timepicker module entered time is considered local time. While Solr stores UTC time only, timepicker time is converted to UTC before issuing the query. All panels, i.e. table, filters, ... should display UTC. Hope this makes sense,
Right, that's what I thought it was supposed to be. However, in the change that i mentioned someone took out the .utc() function call so that when time_apply is called it uses the time as is rather than trying to convert it to utc.