JavaScript's built-in Date
class provides with the needed functionality for manipulating and querying date and time data.
Here are examples of how to use the built-in Date
object:
Assuming, Today is 22/05/2023 / or enter date manually via field {Field}.getDay()); // 'DOW': Output: 1
{Field}.getDate()); // 'DAY': Output: 22
{Field}.getMonth() + 1; // 'MONTH': Output: 5 (JS months are 0-11) {Field}.getFullYear(); // 'YEAR': Output: 2023
How to configure
Create a variable - Type number
Create your workflow.
Create a trigger that calculates current day and enters number into your variable.
Set your Show/Hide rules for day of week.
Important Data
This is the numeric translation to days:
0: Sunday
1: Monday
2: Tuesday
3: Wednesday
4: Thursday
5: Friday
6: Saturday