After creating a process you will have the ability to use the drag and drop functionality to add on your canvas actions from the Platform actions section.
The DateTime folder contains actions that can be used while working with dates:
- Week Number - Returns the week number for the given date. The week number indicates where the week falls numerically within a year.
- Today - Displays a string that represent the current date.
- Is Weekend - Verify if it's weekend, by giving the date. Returns true or false.
- Is Working Day - Verify if it's working day, by giving the date.
- Weekday - Displays an integer that represents the day of the week, by giving the date.
- UTC Now - Displays the current UTC.
- Get Day - Returns the day of the date which was input by the user.
- Get Month - Returns the month of the date which was input by the user.
- Date Addition - Returns the date after being modified by the user input.
- Get Hours - Returns the hours of the time interval which was input by the user.
- Get Minutes - Returns the minutes of the time interval which was input by the user.
- Get Year - Returns the year of the date which was input by the user.
- Date Difference - Returns the difference between the second and the first date.
- Time Difference - Returns the difference between the second time interval and the first time interval.
You can create your own custom actions by using these guides. The code used to create the Custom Actions above can be found here.
How to use DateTime actions
To use any of them inside your process you will need to configure it after adding it to the canvas.
1. Drag the Is Weekend action on the canvas.
2. Link the actions.
3. Create a variable of type Boolean by clicking Add variable.
4. Add a date to the Input Date section and the variable you just created as presented in the Is it weekend* section.