For the managed package runtime, enable users to select from a list of times by adding the Time element to your Omniscript. Format the display and set the time intervals.
This information is for Omnistudio for Managed Packages. For Omnistudio on standard runtime, see Omnistudio Help.
- Drag a Time element from the Build panel onto the canvas.
- In the Properties panel, give the element a name in the Name field.
- In Field Label, enter a label visible to the user.
-
In Minimum Time, enter the earliest time the user can select, such as 12:00 am.
Note
The format entered must be the same as in the Time Format field. For example, to set the minimum time to midnight, if the Time Format is hh:mm a, you must enter 12:00 am.
-
In Maximum Time, enter the latest time the user can select, such as 08:00 pm.
Note
The format entered must be the same as in the Time Format field. For example, to set the maximum time to 8pm, if the Time Format is hh:mm a, you must enter 08:00 pm.
-
In Time Format, enter the format to display the time, such as hh:mm a, which is the default.
Note
Enter h or hh for hour, m or mm for minute, s or ss for seconds, and a for am/pm. A single letter, such as h or m, has no leading zero. Remove the a to display 24 hour time. For example, hh:mm a displays
03:30 pm, h:mm a displays3:30 pm, and hh:mm:ss. displays15:30 01. For more format options, see Day.js. - In Time Interval, enter the intervals within an hour the user can select from the time dropdown. For example, enter 15 for 15 minute periods within the hour such as 12:00, 12:15, 12:30, 12:45, and so on. The default interval is 30.
-
(Optional) In the Advanced Options section, update values for the following properties:
-
Data Type: Specifies how to display the time in the Data JSON.
-
If set to String, the Model Time Format is applied. String is the default data type.
-
If set to Date, the time is encoded as an ISO 8601 time.
-
-
Model Time Format: Specifies how the time is formatted in the Data JSON when Data Type is set to String. The default format is HH:mm:ss.sss'Z'. For more format options, see Day.js.
-
- (Optional) For additional properties, see Common Omniscript Element Properties Definitions (Managed Package).
- Time Properties (Managed Package)
For the managed package runtime, time properties are configurable from the Properties panel when you select a Time element. With the Time element, enable users to select a time from a dropdown list in your Omniscript.