RealGrid2 API
Interface
BTDateCellEditor

BTDateCellEditor

Editor using BootStrap DatePicker

Signature:

export interface BTDateCellEditor extends TextCellEditor

Extends: TextCellEditor

Remarks

After bundling, you must apply the file as follows for it to work properly.

Inherits TextCellEditor.

[Superclass]

CellEditor - TextCellEditor

Example

//string type
column.editor = "btdate"
 
//object type
column.editor = { type: "btdate", maxLength: 6, textReadOnly: true }
<script type="text/javascript" src="/lib/bootstrap/bootstrap-datepicker.js"></script>
<script type="text/javascript" src="/lib/bootstrap/bootstrap-datepicker.ko.min.js"></script>
<link rel="stylesheet" type="text/css" href="/lib/css/bootstrap-datepicker.css">

Properties

PropertyTypeDescription
btOptionsanyOptions for BootStrap DatePicker
commitOnSelectbooleanWhether to commit when selected
dropDownPositionDropDownPositionLocation of calendar selection box
dropDownWhenClickbooleanWhether to expand the list when a cell is clicked
editFormatstring(ALPHA) Edit Format
maxDatestring | DateMaximum date that can be entered
minDatestring | DateMinimum date allowed for entry
textReadOnlybooleanWhether to prohibit input using the keyboard
type'btdate'Cell editor type: Bootstrap date editor
viewGridInsidebooleanWhether to include it inside the grid DOM

Properties Desc

btOptions

Options for BootStrap DatePicker

Type - any

Remarks:

Reference (opens in a new tab)


commitOnSelect

Whether to commit when selected

Type - boolean


dropDownPosition

Location of calendar selection box

Type - DropDownPosition


dropDownWhenClick

Whether to expand the list when a cell is clicked

Type - boolean


editFormat

Edit Format

Type - string


maxDate

Maximum date that can be entered

Type - string | Date

Remarks:

If a date later than maxDate is entered with the keyboard, it is changed to maxDate.


minDate

Minimum date allowed for entry

Type - string | Date

Remarks:

If a date earlier than minDate is entered with the keyboard, it is changed to minDate.


textReadOnly

Whether input using the keyboard is prohibited

Type - boolean


type

Cell editor type: Bootstrap date editor

Type - 'btdate'


viewGridInside

Whether to include it inside the grid DOM

Type - boolean