You are here:
Reference Elements and Attributes
Know more about elements used in DataDeclaration and the supported formats for date and time.
Required Editions
| Available in Lightning Experience in Enterprise and Unlimited Editions that have Consumer Goods Cloud enabled. |
Data Declaration
List of the attributes supported by the DataDeclaration
element:
| Attribute | Description | Values | Required |
|---|---|---|---|
| name | Unique name of the variable. | String | Yes |
| type | Type of the variable. | String | Yes |
| imageId | Defines the identification name of the image. The ImageId must match the ImageId available in VS Code based Modeler. | String | — |
| mimeType | Defines the type of the image. The supported types are .png and .svg. | String | — |
Additional Date and Time Formats
The table lists the additional formats supported by the dateTimeFormat attribute:
| Format | Description | Sample |
|---|---|---|
| YY | Defines the year in two-digits. | 18 |
| YYYY | Defines the year in four-digits. | 2023 |
| M | Defines the month starting from 1 to 12 without the leading zeros. | 1, 2, 3, …, 12 |
| MM | Defines the month as two-digits with leading zeros. | 01, 02, 03, …, 12 |
| MMM | Defines the month in abbreviated form (3 letters). | Jan, Feb, Mar, Apr, …, Dec |
| MMMM | Defines the full name of the specified month. | January |
| D | Defines the day of the month, starting from 1 to 31, without leading zeros. | 1, 2, 3, …, 31 |
| DD | Defines the day of the month as two-digits, with leading zeros for the single-digit days. | 01, 02, 03, …, 31 |
| d | Defines the day of the week in numeric format, starting from 0 to 6, with Sunday as 0. | 0, 1, 2, 3, 4, 5, 6 |
| dd | Defines the day of the week by using the first two-letters. | Su, Mo, Tu, We, Th, Fr, Sa |
| ddd | Defines the day of the week in abbreviated form. | Sun, Mon, Tue, Wed, Thu, Fri, Sat |
| dddd | Defines the day of the week in full form. | Sunday - Saturday |
| H | Defines the hour in the 24-hour clock format, starting from 0 to 23, without leading zeros for single-digit hours. | 0, 1, 2, …, 23 |
| HH | Defines the hour in the 24-hour clock format, starting from 0 to 23, with leading zeros for the single-digit hours. | 00, 01, 02, …, 23 |
| h | Defines the hour in the 12-hour clock format, starting from 0 to 12, without leading zeros for the single digit. | 1, 2, 3, …, 12 |
| hh | Defines the hour in the 12-hour clock format, starting from 0 to 12, with leading zeros for single-digit hours. | 01, 02, 03, …, 12 |
| m | Defines the minutes, starting from 0 to 59, without leading zeros for the single-digit minutes. | 0, 1, 2, 3, …, 59 |
| mm | Defines the minutes, starting from 0 to 59, with leading zeros for the single-digit minutes. | 00, 01, 02, 03, …, 59 |
| s | Defines the seconds, starting from 0 to 59, without leading zeros for the single-digit minutes. | 0, 1, 2, 3, …, 59 |
| ss | Defines the seconds, starting from 0 to 59, with leading zeros for the single-digit minutes. | 00, 01, 02, 03, …, 59 |
| sss | Defines the milliseconds in three digits, starting from 000 to 999. | 000, 001, 002, …, 999 |
| Z | Defines the UTC (Coordinated Universal Time) time offset for the specified place and date in the ±HH:mm format. | +05:00 |
| ZZ | Defines the UTC time offset for the specified place and date in the ±HHmm format. | 0500 |
| A | Defines the section of the day in upper case letters. | AM or PM |
| a | Defines the section of the day in lower case letters. | am or pm |
Example This sample code shows both the standard and the localization formats for
dateTimeFormat.<!--left out for brevity→
<tr>
<td alignment="right">Order Date:</td>
<td>{{Declarations::order.orderDate; dateTimeFormat=DD.MM.YYYY}}</td>
</tr>
<tr>
<td alignment="right">Delivery Date:</td>
<td>{{Declarations::order.deliveryDate; dateTimeFormat=date}}</td>
</tr>Did this article solve your issue?
Let us know so we can improve!

