Timeline for Adding events according to user's timezone through API
Current License: CC BY-SA 3.0
5 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jul 3, 2017 at 22:41 | comment | added | jasep |
Thanks a lot! The pytz library was just what I needed. I ended up using timezone(TimezoneSidKey).utcoffset(mytime) to get the offset and convert my time to UTC before inserting it.
|
|
Jul 1, 2017 at 6:10 | answer | added | Charles T | timeline score: 0 | |
Jul 1, 2017 at 0:36 | comment | added | sfdcfox♦ | You'll probably want to take a peek at pytz which provides timezone to tzinfo-style conversions. So, your basic process will indeed be (a) get user's TimezoneSidKey, (b) convert events to UTC, and (c) insert/update records, just as you'd already guessed. | |
Jun 30, 2017 at 23:35 | review | First posts | |||
Jul 1, 2017 at 2:57 | |||||
Jun 30, 2017 at 23:34 | history | asked | jasep | CC BY-SA 3.0 |