I calculate the offset based on the DST rule (here UK):
Flow.DSToffset = if (Flow.StartDateTimeUtc >= MakeDateTime(Year(Flow.StartDateTimeUtc), 3, 31 - (DayOfWeek(MakeDateTime(Year(Flow.StartDateTimeUtc),3,31))-1)) and Flow.StartDateTimeUtc <= MakeDateTime(Year(Flow.StartDateTimeUtc), 10, 31 - (DayOfWeek(MakeDateTime(Year(Flow.StartDateTimeUtc),10,31))-1)), 1, 0)
I then check if the time is within my criteria (here M-F after 6pm, Sat after 5pm, or Sun), taking DST offset into account:
(DayOfWeek(Flow.StartDateTimeUtc) > 1 and DayOfWeek(Flow.StartDateTimeUtc) < 7 and Hour(Flow.StartDateTimeUtc) >= (18-Flow.DSToffset)) or (DayOfWeek(Flow.StartDateTimeUtc) == 7 and Hour(Flow.StartDateTimeUtc) >= (17-Flow.DSToffset)) or (DayOfWeek(Flow.StartDateTimeUtc) == 1)(edited for subtraction instead of addition)------------------------------
Sven Schiller
Kognitiv
------------------------------
Original Message:
Sent: 03-14-2019 16:52
From: Kymberli O'Hagan
Subject: Buildig
I'll take a look at these articles, thank you
------------------------------
Kymberli O'Hagan
Alberta Motor Association
Original Message:
Sent: 03-14-2019 13:48
From: Melissa Bailey
Subject: Buildig
Are you taking your timezone offset into account? Flow.StartDateTimeUtc returns the time in UTC, not your current timezone. For example, I'm located in Indiana and my offset is +4. So 1pm my time is actually 17:00 UTC.
https://help.mypurecloud.com/articles/datetime-values-in-architect-flows-and-daylight-savings-time-dst-calculations/ has a couple examples of how to account for timezone & daylight savings time.
------------------------------
Melissa Bailey
Genesys - Employees
Original Message:
Sent: 03-14-2019 13:38
From: Kymberli O'Hagan
Subject: Buildig
Is anyone aware of a way to accomplish the following within an in-queue flow .....
We want to offer a callback but only Monday to Friday between 9:00am - 4:00pm.
Below is an image of what is currently built - but not working.
#ArchitectureandDesign
------------------------------
Kymberli O'Hagan
------------------------------