options.js
//Create a list of weekday numbers that is much easier to parse at runtime
Create a list of weekday numbers that is much easier to parse at runtime
Create a list of weekday numbers that is much easier to parse at runtime
function createDisabledWeekdays(mon,tue,wed,thu,fri) {
disabledDays = "0,6";
if (mon == true) {
disabledDays = disabledDays.concat(",1");
}
if (tue == true) {
  disabledDays = disabledDays.concat(",2");
}
if (wed == true) {
  disabledDays = disabledDays.concat(",3");
}
if (thu == true) {
  disabledDays = disabledDays.concat(",4");
}
if (fri == true) {
  disabledDays = disabledDays.concat(",5");
}
return disabledDays;
}
function createDisabledWeekdays ( mon , tue , wed , thu , fri ) { disabledDays = "0,6" ; if ( mon == true ) { disabledDays = disabledDays . concat ( ",1" ) ; } if ( tue == true ) { disabledDays = disabledDays . concat ( ",2" ) ; } if ( wed == true ) { disabledDays = disabledDays . concat ( ",3" ) ; } if ( thu == true ) { disabledDays = disabledDays . concat ( ",4" ) ; } if ( fri == true ) { disabledDays = disabledDays . concat ( ",5" ) ; } return disabledDays ; }
Create a list of weekday numbers that is much easier to parse at runtime
Create a list of weekday numbers that is much easier to parse at runtime