Date Time picker component specifically picked the data from each device setting

I just made an online attendance app by using glide, but for date time picker component, it picked data from each device’s user setting and the current time could be different to each other (not using google global time).
So my app user could modify their time device to manipulate attendance time.

Can we set the date time picker to pick google global time based on region?

Anyone can help me?
thank you

you can get the user’s time zone offset using JS column

If you are using glide tables as a base, there is an option to ‘Respect time zones’. What this does is store the date in a way where the it will save the user’s local timezone in the data/time, but if another user views the date from a different timezone, it will show the time in respect to their local timezone. Kind of like using universal time. This is useful for events or bookings where you want someone to see the correct time based on their own timezone. However, this may or may not fix your issue. As you observed, time is based on the user’s local device, and I think there is nothing you can do to prevent a user from changing the time on their device while keeping the timezone the same. Sure, you can figure out a user’s timezone offset, but you can’t prevent them from manipulating the time and timezone on their device.

image

Since it sounds like you are using google sheets, I think your best bet is to trigger an onChange event in a script within your google sheet which would write a date to the sheet when a new row is added. That way the sheet has complete control over a date/time that is only added by the script instead of being added by the user when they add a row.

2 Likes