21,887
社区成员
发帖
与我相关
我的任务
分享
jQuery(function(){
// Datepicker
jQuery('#datepicker').datepicker({
inline: true,
changeMonth: true,
changeYear: true,
beforeShowDay: function(date){
var weeks = date.getDay();
var texts = "";
if (weeks == 0)
texts = "休日";
/* 休日のチェック */
if(date.isJpHoliday()) {
texts = date.jp_hol_name;
// description = d.jp_hol_desc;
weeks = 0;
}
if (weeks == 0)
return [true, 'days_red', texts];
else if (weeks == 6)
return [true, 'days_blue', texts];
return [true, 'days_black'];
}
});
jQuery('#datepicker').datepicker('option', {dateFormat: 'yy年m月d日'});
jQuery('#datepicker').datepicker('option', 'dayNamesMin', ['日', '月', '火', '水', '木', '金', '土']);
jQuery('#datepicker').datepicker('option', 'monthNamesShort', ['1月', '2月', '3月', '4月', '5月', '6月', '7月', '8月', '9月', '10月', '11月', '12月']);
});