Docs
Guides & Reference
Ask or search…
K
Links

Calendar

(part of package 'Bootstrap Components') Extends designtime/SolutionModel: JSWebComponent Extends runtime: RuntimeWebComponent
Calendar is an input control component. It allows using a date-picker to choose Date values for a bound data-provider. The key difference compared to the Calendar-Inline component is that this Calendar component is an input field that the shows the date-picker in a popup only when clicked; whereas the Calendar-Inline shows the date-picker directly on the form.
This is a reference page; many components have detailed usage guides here.

Properties

calendarWeeks

Type: boolean Default Value: true

dataProviderID

Type: dataprovider

enabled

Type: enabled Default Value: true

format

Type: format

options

See https://getdatepicker.com/6/options/ what options you can set, some could be overridden by the locale again Type: json

pickerOnly

Whether to only allow date entry from the date picker or not (cannot type the date). Type: boolean Default Value: false

placeholderText

Type: tagstring

selectOnEnter

Whether to select the text when date field is focused. Type: boolean

styleClass

Set the styleclasses that should be applied at to this component Type: styleclass Default Value: "form-control"

tabSeq

Type: tabseq

theme

Type: string Default Value: "light"

toolTipText

Type: tagstring

visible

Whether the button is visible or not Type: visible

Events

onActionMethodID

Parameters:
event JSEvent

onDataChangeMethodID

Handle changed data, return false if the value should not be accepted.
JSEvent.data will contain extra information about dataproviderid, its scope and the scope id (record datasource or form/global variable scope)
Parameters:
Returns: boolean

onFocusGainedMethodID

Parameters:
event JSEvent

onFocusLostMethodID

Parameters:
event JSEvent

API

disableDates

Dates that should be disabled.
@param {Array<Date>} dateArray
@param {Boolean} [keepInvalid]
Parameters:
dateArray date[] keepInvalid boolean (optional)

disableDays

Days of the week that should be disabled. Values are 0 (Sunday) to 6 (Saturday).
@param {Array<Number>} dayArray
@param {Boolean} [keepInvalid]
Parameters:
dayArray int[] keepInvalid boolean (optional)

requestFocus

Set the focus to this calendar.
@example %%elementName%%.requestFocus();
@param mustExecuteOnFocusGainedMethod
(optional) if false will not execute the onFocusGained
method; the default value is true
Parameters:
mustExecuteOnFocusGainedMethod boolean (optional)

setMinMaxDate

Set the min date or max date that can be selected
@param {Date} minDate
@param {Date} maxDate
@param {Boolean} [keepInvalid]
Parameters:
minDate date maxDate date keepInvalid boolean (optional)