在fullcalendar中禁用外部事件的突出显示 [英] Disable highlight of an external event in fullcalendar

查看:119
本文介绍了在fullcalendar中禁用外部事件的突出显示的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用fullcalendar jquery插件v2.6.1。实际上,我想在拖拽到日历时防止突出显示的外部事件选项。



是否有任何可能的方法来禁用 fc-突出显示来自事件或任何选项,以根据事件大小显示突出显示。我的意思是说我有一个开始和结束时间的外部事件,例如事件从10:00开始并在11:00结束,但是当我将该事件拖到日历中时, fc-突出显示总是涵盖了两个小时的时间段。



以下图片

事件2 中的灰色突出显示框仅可用为一个小时的插槽,但突出显示的背景涵盖了两个小时,我想禁用它或只是使它一个小时。请帮助。



提前致谢!

解决方案

您可以实现该解决方案通过在FullCalendar选项中添加 defaultTimedEventDuration:01:00:00 或在外部事件中添加 duration 这:

 < div class =external fc-eventduration =04:00> Event< / div> ; 


I am using the fullcalendar jquery plugin v2.6.1. Actually, I want to prevent the highlighted option of an external events while dragging to the calendar.

Is there any possible way to disable the fc-highlight from the event or any option to show the highlight on the basis of event size. I mean to say that I have an external event with start and end time e.g the event starts from 10:00 and ends at 11:00 but when I'm dragging that event to the calendar, the fc-highlight always covered the two hours slot.

Picture attached below

So in the picture, the grayish highlighted box in red stroke Event 2 which is only available for one hour slot but the highlighted background covers two hours which I want to disable it or just make it one hour. Please help.

Thanks in advance!

解决方案

You can achieve the solution by adding defaultTimedEventDuration: 01:00:00 in FullCalendar options or adding duration in an external events, something like this:

<div class="external fc-event" duration="04:00">Event</div>

这篇关于在fullcalendar中禁用外部事件的突出显示的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆