I'm happy to get on a call with someone to discuss this as we deal with it all the time.
Here is a data structure that would give you all the flexibility you need (I'm a C# guy)
DateTime utcTime = DateTime.UtcNow;
TimeZoneInfo tz = TimeZoneInfo.FindSystemTimeZoneById("Pacific Standard Time");
var record = new YourEntity
{
UtcTime = utcTime,
LocalTime = localTimeWithOffset,
TimeZoneId = tz.Id
};
The reasoning of "it needs to be recorded in the time zone the work was done." Just doesn't hold up for travelers. Perhaps in theory, but not practically.
I just flew west fast enough that now when I try to track time and say "Start stopwatch at end of last tag" I get -38:16 displayed. Which of course is ludicrous.
I do report my time on a weekly basis, and I always report it in the time zone I live in. Even if I tried to report it based on the time zone the work was done in I don't think the software is capable of it! I just tried to generate a timesheet when I worked in two time zones in one week and it's just scrambled.
I've read the comments about wanting to report for the time zone you're in. But with the great internet I have on all my flights what am I supposed to do if I'm crossing 10 time zones? I know the response will be "Just pick either the departure or landing." But I have a 6 hour layover in Chicago when I travelled from Denver to London. On top of that, it means you can't use the "Set time zone automatically" feature in Windows 11. I take off from Denver, then my inflight internet is routed through San Francisco, so my clock changes and hour, then routed through Chicago. I used to have that set, but I have switched to always manually adjusting it due to ManicTime.
I'm happy to get on a call with someone to discuss this as we deal with it all the time.
Here is a data structure that would give you all the flexibility you need (I'm a C# guy)
DateTime utcTime = DateTime.UtcNow;
TimeZoneInfo tz = TimeZoneInfo.FindSystemTimeZoneById("Pacific Standard Time");
DateTimeOffset localTimeWithOffset = TimeZoneInfo.ConvertTime(utcTime, tz);
var record = new YourEntity
{
UtcTime = utcTime,
LocalTime = localTimeWithOffset,
TimeZoneId = tz.Id
};
The reasoning of "it needs to be recorded in the time zone the work was done." Just doesn't hold up for travelers. Perhaps in theory, but not practically.
I just flew west fast enough that now when I try to track time and say "Start stopwatch at end of last tag" I get -38:16 displayed. Which of course is ludicrous.
I do report my time on a weekly basis, and I always report it in the time zone I live in. Even if I tried to report it based on the time zone the work was done in I don't think the software is capable of it! I just tried to generate a timesheet when I worked in two time zones in one week and it's just scrambled.
I've read the comments about wanting to report for the time zone you're in. But with the great internet I have on all my flights what am I supposed to do if I'm crossing 10 time zones? I know the response will be "Just pick either the departure or landing." But I have a 6 hour layover in Chicago when I travelled from Denver to London. On top of that, it means you can't use the "Set time zone automatically" feature in Windows 11. I take off from Denver, then my inflight internet is routed through San Francisco, so my clock changes and hour, then routed through Chicago. I used to have that set, but I have switched to always manually adjusting it due to ManicTime.