stefangabos / Zebra_Datepicker

A super-lightweight, highly configurable, cross-browser date time picker jQuery plugin
https://stefangabos.github.io/Zebra_Datepicker/
Other
399 stars 183 forks source link

Cant set enabled hours #148

Closed supercain closed 5 years ago

supercain commented 5 years ago

Hi,

I want to configure the script to enable only a set of available hours like this:

enabled_hours: ['11', '12', '13', '14', '15', '16', '17', '18', '19']

but on the picker only 11 is shown and if I try to change it with the arrows then UNDEFINED appears. Enabled minutes wont work either

enabled_minutes: ['00'],

is this a bug or im doing something wrong?

Thank you.

stefangabos commented 5 years ago

I'll look into it this week. Thank you!

stefangabos commented 5 years ago

This is now fixed. It was because I expected those values to be given as integers

enabled_hours: [11, 12, 13, 14, 15, 16, 17, 18, 19]

instead of strings

enabled_hours: ['11', '12', '13', '14', '15', '16', '17', '18', '19']

Thank you for reporting and sorry it took so long to finally making time for this