- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2023 03:13 AM
I have a scenario where the timezone source field is selected as the caller's timezone, but the timezone field is empty in user's profile, then how the SLA will run?
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2023 03:22 AM
Hello @amit71
If the timezone is empty, then system timezone will be used. you can find system timezone in system property glide.sys.default.tz
Thanks,
Ali
Thank you,
Ali

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2023 03:22 AM
Hello @amit71
If the timezone is empty, then system timezone will be used. you can find system timezone in system property glide.sys.default.tz
Thanks,
Ali
Thank you,
Ali
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2023 03:31 AM - edited 06-12-2023 03:34 AM
Hi @amit71 ,
Hope you are doing great.
The system timezone is typically set based on the server's location or the organization's standard timezone.
If the timezone field is empty, you would need to handle this situation by either automatically populating the timezone field based on the caller's timezone selection or by prompting the user to provide their timezone information
Reference code snippet that demonstrates how you can populate the timezone field in the user's profile based on their location or other relevant criteria:
// Business rule script to populate timezone field in user's profile
(function executeRule(current) {
var user = new GlideUser(current.user.toString());
if (current.timezone.nil()) {
// Logic to determine the user's timezone based on their location or other criteria
var timezone = determineUserTimezone(user.getPreference('location'));
if (timezone) {
// Set the timezone field in the user's profile
user.setTimeZone(timezone);
user.update();
}
}
})(current);
function determineUserTimezone(location) {
// Custom logic to determine the user's timezone based on their location
// Implement your own code here to map locations to timezones
}
Regards,
Riya Verma