简体   繁体   English

如何在FullCalendar中仅显示发生事件的日子?

[英]How do I do to show only days with an event in FullCalendar?

I have a fullCalendar plugin connected to Google Calendar and it shows all days, including days that don't have an event. 我有一个与Google日历连接的fullCalendar插件,它会显示所有日子,包括没有活动的日子。 I need it to show just days with an event. 我需要它来显示事件的几天。 Is it possible? 可能吗?

I can't give a full answer since I am still chewing on this myself, but you might has well know what I've done. 由于我仍在自己身上作呕,因此我无法提供完整的答案,但是您可能很了解我所做的事情。 I work in a custom basic Day view called vertWeek, which looks like an agenda view. 我在一个名为vertWeek的自定义基本日视图中工作,它看起来像一个议程视图。 In dayRender, I have tried looping (.each) over fc-row and using freight trains of .has and .hasClass to try to hunt down those rows that have a td cell with .fc-container-event. 在dayRender中,我尝试在fc行上循环(.each),并使用.has和.hasClass的货运列车来尝试查找具有.fc-container-event的td单元格的行。 The existence of this should be enough but no matter what I try I can't isolate a specific day-row. 这样的存在应该足够了,但是无论我尝试什么,我都无法隔离特定的行。 All rows get a green border or in the negative they get a red border. 所有行都有一个绿色边框,或在负数处都有一个红色边框。

I know my each works coz if I use .html on the index each row prints out its index number neatly. 我知道如果我在索引上使用.html,那么每行都可以工作,因为整行打印出了它的索引号。 I don't have code handy, am away and tired, but go look for a post about squishing box calendar rows without events in them to get a gist of my efforts. 我没有方便的代码,出门在外又累又疲倦,但请去找一篇有关压缩框日历行的帖子,其中没有任何事件,以获取我的努力要旨。

Hope this helps. 希望这可以帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM