Sha256: c1de785288b4c9ba545ebff0e6baf4c7e4613bcd7799daccaed6a4295e614dfd

Contents?: true

Size: 1.85 KB

Versions: 46

Compression:

Stored size: 1.85 KB

Contents

## Functions

<div class="alert alert-info">
    <strong>Note</strong>
    All functions are accessed via the <code>data</code> attribute e.g. <code>$('#datetimepicker').datetimepicker(FUNCTION)</code>
</div>

### destroy

Destroys the widget and removes all attached event listeners

----------------------

### toggle

Shows or hides the widget

#### Emits

* `hide.datetimepicker` - if the widget is hidden after the toggle call

* `show.datetimepicker` - if the widget is show after the toggle call

* `change.datetimepicker` - if the widget is opened for the first time and the input element is empty and `options.useCurrent != false`

----------------------

### show

Shows the widget

#### Emits

* `show.datetimepicker` - if the widget was hidden before that call

* `change.datetimepicker` - if the widget is opened for the first time and the `useCurrent` is set to true or to a granularity value and the input element the component is attached to has an empty value

----------------------

### hide

Hides the widget

#### Emits

* `hide.datetimepicker` - if the widget was visible before that call

----------------------

### disable

Disables the input element, the component is attached to, by adding a `disabled="true"` attribute to it. If the widget was visible before that call it is hidden.

#### Emits

* `hide.datetimepicker` - if the widget was visible before that call

----------------------

### enable

Enables the input element, the component is attached to, by removing `disabled` attribute from it.

----------------------

### clear

Clears the date picker by setting the value to `null`

----------------------

### viewDate

#### viewDate

Returns a `moment` variable with the currently set `options.viewDate` option.

#### viewDate(viewDate)

Takes a `string, moment or Date` value.

This will change the `viewDate` without changing or setting the selected date.

Version data entries

46 entries across 46 versions & 2 rubygems

Version Path
card-mod-date-0.15.6 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.15.0 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.14.2 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.14.1 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.14.0 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.13.4 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.13.3 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.13.2 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.13.1 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.13.0 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.7 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.12.0 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.6 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.5 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.4 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.3 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.2 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.1 vendor/tempusdominus/src/docs/Functions.md
card-mod-date-0.11.0 vendor/tempusdominus/src/docs/Functions.md
card-1.100.0 mod/date/vendor/tempusdominus/src/docs/Functions.md