我刚刚在FullCalendar下创建了最基本的TimelineView:
<!DOCTYPE html>
<html lang='fr'>
<head>
<meta charset='utf-8' />
<link href='./fullcalendar/packages/core/main.css' rel='stylesheet' />
<link href='./fullcalendar/packages/timegrid/main.css' rel='stylesheet' />
<link href='./fullcalendar/packages-premium/timeline/main.css' rel='stylesheet' />
<link href="layout.css" rel="stylesheet" />
<script src='https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.9.0/moment.js'></script>
<script src='./fullcalendar/packages/core/main.js'></script>
<script src='./fullcalendar/packages/timegrid/main.js'></script>
<script src='./fullcalendar/packages/core/locales/fr.js'></script>
<script src='./fullcalendar/packages-premium/timeline/main.js'></script>
<script src='./fullcalendar/packages-premium/resource-common/main.js'></script>
<script src='./fullcalendar/packages-premium/resource-timegrid/main.js'></script>
<script src='./fullcalendar/packages-premium/resource-timeline/main.js'></script>
<script src="./jquery-3.4.1.min.js" type="text/javascript"></script>
</head>
<body>
<div id='calendar'></div>
</body>
</html>
<script>
var calendarEl = document.getElementById('calendar');
calendar = new FullCalendar.Calendar(calendarEl, {
schedulerLicenseKey:'',
plugins: ['resourceTimeline' ],
defaultView: 'resourceTimelineMonth'})
calendar.render();
</script>
如何删除/隐藏此列?
谢谢
您忘记了包含资源时间轴CSS文件。我无法使用标准Scheduler设置重现您的问题。演示:https://codepen.io/ADyson82/pen/WNQyrzN
但是如果您删除该文件,则您的问题开始出现。演示:https://codepen.io/ADyson82/pen/mdeKVLQ
我还可以看到上面显示的代码中缺少相关的CSS文件。对于您的情况,我希望您需要这样的链接:
<link href='./fullcalendar/packages-premium/resource-timeline/main.css' rel='stylesheet' />
[C0显示了每个插件正常工作所需的JS和CSS文件(如果有)。