【发布时间】:2015-11-29 08:27:29
【问题描述】:
我将FullCalendar 用于医生/患者预约系统。我想使用 FullCalendar 在患者屏幕上显示医生的可用性。我正在使用dayRender 函数,但它是否向我显示了第二天的日期,特别是针对 EST 时区。谁能告诉我我在这里错过了什么?
dayRender: function (date, cell) {
var view = $('#calendar').fullCalendar('getView');
var strDay = moment(date._d).format('YYYY-MM-DD');
$.ajax({
url: '/client/profile/ajaxexpertappointentclientday',
data: 'strDate='+strDay ,
type: "POST",
async:false,
success: function(intFlag) {
var today = moment();
if(intFlag == 1 && strDay >= strTodaysDate && strDay < moment(today._d).add('days', 2).format('YYYY-MM-DD')) {
cell.css("background-color", "red");
} else {
cell.css("background-color", "#F0F0F0");
}
}
});
}
},
【问题讨论】:
-
您能否在您的问题中添加日历库的链接?其他人可以帮助您。
标签: javascript jquery timezone fullcalendar