在完整日历中,当设置参数时
分钟时间
和
最大时间
Now()指示符没有正确定位。
我有一个JSFiddle来展示这个问题。在这个Fiddle中,我希望指标在当前日期和时间,但它位于“昨天”栏的顶部。
下面是小提琴中使用的代码
<div id="calendar"></div>Javascript
$('#calendar').fullCalendar({
defaultView: 'agendaWeek',
height: 600,
nowIndicator: 'true',
minTime: "20:00:00", // this makes the calendar start at 8PM
maxTime: "44:00:00", // this makes the calender end 24 hours later at 8PM ( (8PM => 20) + 24 = 44)
schedulerLicenseKey: 'CC-Attribution-NonCommercial-NoDerivatives'
})移除
minTime
和
maxTime
参数,使当前指示符位置正确,如下面所示:https://jsfiddle.net/8jndrp7m/2/
在使用minTime和maxTime时,如何正确定位Now指示器?还是这是个窃听器?
发布于 2019-03-13 12:43:45
问题就像您为第二天设置了maxTime,这是为什么它不能工作的原因。
如果您喜欢指定日期以设置最大值,请使用validRange设置min & max日期
$('#calendar').fullCalendar({
defaultView: 'agendaWeek', //agendaWeek
validRange: {
start: '2017-05-01',
end: '2017-06-01'
},
locale: 'nl',
timezone: 'local',
themeSystem: 'bootstrap3',
height: 600,
slotDuration: '00:10:00',
nowIndicator: 'true',
minTime: "17:00:00", // this makes the calendar start at 8PM
maxTime: "20:00:00", // this makes the calender end 24 hours later at 8PM ( (8PM => 20) + 24 = 44)
schedulerLicenseKey: 'CC-Attribution-NonCommercial-NoDerivatives',
editable: true, // enable draggable events
droppable: true, // this allows things to be dropped onto the calendar
})发布于 2019-03-13 12:33:50
我看到了许多问题:
'true'改为true,1.放在时间的前面,来设置第二天早上下一个day.So 8的时间是maxTime: '1.08:00:00'。https://stackoverflow.com/questions/55141826
复制相似问题