DateTimeField
A composite field that combines a DateField and a TimeField into a single input for selecting both date and time. The two sub-fields can be individually configured via dateField and timeField. The field's value is a Date object representing the combined selection. This field can be used as a cell editor in a Grid.
const dateTimeField = new DateTimeField({
label : 'Start',
value : new Date(2025, 0, 15, 9, 30),
appendTo : document.body
});
Useful configs and properties
| Config | Description |
|---|---|
| value | The combined date and time value |
| dateField | Configuration for the embedded DateField |
| timeField | Configuration for the embedded TimeField |
| weekStartDay | First day of the week (0=Sunday, 1=Monday, etc.) |
| label | Field label displayed beside the field |
See also
- DateField - Date-only input field
- TimeField - Time-only input field
- DateRangeField - Field for selecting a date range
No results
Configs
Configs are options you supply in a configuration object when creating an instance of this class-
The week start day in the picker, 0 meaning Sunday, 6 meaning Saturday. Uses a localized value by default.
Properties
Properties are getters/setters or publicly accessible variables on this class-
Identifies an object as an instance of DateTimeField class, or subclass thereof.
-
Returns the DateField instance
Has a corresponding dateField config.
-
Returns the TimeField instance
Has a corresponding timeField config.
-
Identifies an object as an instance of DateTimeField class, or subclass thereof.
Functions
Functions are methods available for calling on the classtype: datetimefield