So I basically added a calendar view and added those required data source methods, plus the didSelectDate delegate method. Here is my (simplified) didSelectDate method:
func calendar(calendar: FSCalendar, didSelectDate date: NSDate) {
print(date)
}
When I was in Hong Kong (UTC+8), the method always printed yyyy-mm-dd 16:00:00 +0000
Now I traveled to the UK (UTC+1), the method now prints yyyy-mm-dd 23:00:00 +0000
Why is the time component different in different time zones? I mean, the user is selecting a date, the time component should be a constant regardless of the time zone!
Can you change all the time components to 00:00:00? This makes it easier to access dictionaries and stuff with the date parameter.
So I basically added a calendar view and added those required data source methods, plus the
didSelectDatedelegate method. Here is my (simplified)didSelectDatemethod:When I was in Hong Kong (UTC+8), the method always printed yyyy-mm-dd 16:00:00 +0000
Now I traveled to the UK (UTC+1), the method now prints yyyy-mm-dd 23:00:00 +0000
Why is the time component different in different time zones? I mean, the user is selecting a date, the time component should be a constant regardless of the time zone!
Can you change all the time components to 00:00:00? This makes it easier to access dictionaries and stuff with the
dateparameter.