Weekdays #123

wants to merge 2 commits into


None yet

2 participants


Add option to enable only specified weekdays

I seem to have got a clean diff . . . but have managed to get the UA language change in here too and can't see how to remove it again :-(

GreyHead added some commits Aug 26, 2012
@GreyHead GreyHead Re-commit UA update b913c66
@GreyHead GreyHead Add option to enable only specified weekdays
Added a new option 'weekdays' that takes an optional array of day
numbers e.g. {0,3,4}. If the array is present then the available dates
are limited to the days in the array.

The option is applied in the isUnavailable() function when the calendar
is rendered.
@arian arian commented on the diff Apr 4, 2013
year, month, day, ms;
- if (!minDate && !maxDate && !availableDates) return false;
+ if ( typeof avaliableDates == 'undefined' ) {
+ availableDates = null;
+ }
+ if (!minDate && !maxDate && !availableDates && !weekdays) return false;
arian Apr 4, 2013 Owner

Why was this changed?

GreyHead Apr 5, 2013

If I recall correctly it was there to remove a warning about an undefined value. But it is not in my current version so is probably not needed. I re-started with a clean fork after getting into a mess with this version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment