Guided Workflow Screen Components - Date and Time Input
Updated
Overview
The Date and Time Field in a form is an interactive input element designed for users to select or input specific dates, times, or both. It is widely utilized for purposes such as scheduling, setting appointments, meeting deadlines, or collecting time-sensitive information, ensuring precision and efficiency in data input.
Various Fields in Date and Time Input

Show Time: Selecting this checkbox will allow you to display the time within the component.

Enable 24-Hour Format: This checkbox enables you to show the time in a 24-hour format.
Default Timezone: You can select the default time zone based on the region where you will be using this feature.
Include Timezones: All time zones are included by default if no specific options are selected.
Date & Time Format: Sprinklr offers a variety of date and time formats to help you select your preferred options.

Enable Date & Time Conditions: This field allows you to define specific conditions for displaying date and time values. By using a Groovy script, you can configure the display to show dates that are after, before, or within a specified time range.
This toggle also allows you to evaluate and compare different Date & Time inputs within the same screen. Evaluating screen components using separate Decision Box or Update Properties nodes after the screen often causes redundancy and extra configuration effort. The same screen evaluation feature streamlines the process by enabling direct evaluation within the same screen, improving efficiency and reducing complexity.
If there are two Date & Time fields on a screen — the first Date & Time and the second Date & Time — you can ensure that the second Date & Time input is always After, Before, or Within the range of the values entered in the first Date & Time input, depending upon the required use case. For example, if the first date is set to March 26th, 12:30 PM, this feature will enforce that the second date can only be set to after, before, or within the time frame of the first Date & Time input as per the applied configuration (In the screenshot below, the After configuration is applied). This feature ensures logical and sequential data entry. This can be done through the configuration mentioned below.

Configuration:
For example, if you want to ensure that the values of the second Date & Time input are later than the first Date & Time input, navigate to the second Date & Time input field and click the Enable Date & Time Conditions toggle. Once enabled, you can add configuration based on the use case. To do this, select After and apply the appropriate Groovy script (mentioned below) to enforce the rule. This ensures that the date and time in the second date & time input will always be later than those in the first date & time input.
Groovy script example:
return newScreen_5? newScreen_5.DATE_8:null;
Groovy Explanation:
If the newScreen_5 value is not null, then the newScreen_5.DATE_8 is returned; else null value is returned.
The date and time input you want to control should have the Controlling Field set to the API name of the date and time input that is controlling it. For instance, in the provided example, the API Name of the first Date & Time input should be added in the Controlling Field of the second Date & Time input.

Note: The Date and Time input component supports localization for the calendar view. Month names and dates are automatically translated based on the user's locale settings.

Business Hours Type: You can specify business hours in this field, which can be either static or dynamic. Selecting "static" allows you to use the business hours available in the system, while choosing "dynamic" gives you the flexibility to add resources or enter custom code.
Fallback Business Hours: These hours will be considered if the dynamic business hours field is found to be empty.
Note: The fallback Business Hours field will be relevant only for the Dynamic Business Hours.

Enable Reporting: The "Enable Reporting" toggle allows users to specify whether the auto-drafted values in the screen component should be included in reporting. When enabled, this ensures that auto-saved data is captured and made available for analytics, addressing gaps in reporting accuracy caused by un-submitted workflows.
Configure Error Message: This field allows you to create a warning message for users when they do not select the checkbox.
Visibility Conditions: It is a rule or set of rules that determines whether a specific element, field, or component is visible to users in an application or interface. These conditions are typically based on factors such as user roles, permissions, field values, or contextual data. Visibility conditions ensure that users only see relevant information, improving usability and security.
Example
Condition: Display a "Priority Escalation" section if the "Ticket Priority" is set to "High."
Implementation: Visibility Condition: Ticket_Priority == 'High'
Result: The "Priority Escalation" section appears only for high-priority tickets.
Input Disability Condition: It refers to a rule or set of criteria that determines whether a specific element, such as a field, button, or component, should be disabled (i.e., grayed out and non-interactive) in a user interface. It restricts user interaction based on certain conditions, ensuring that actions are contextually valid or preventing errors.
Example:
Based on Field Value:
Condition: Disable the "Submit" button if the "Terms and Conditions" checkbox is unchecked.
Result: The user cannot submit the form until they accept the terms.
Based on User Role:
Condition: Disable the "Delete Record" button for users without "Admin" permissions.
Result: Only admins can delete records, while other users see the button but cannot interact with it.
Based on Data Completeness:
Condition: Disable the "Next" button until all required fields are filled.
Result: Users are prevented from moving forward until they complete the required steps.