Update an event by dropping an external event

女生的网名这么多〃 提交于 2019-12-07 23:41:27

I found the solution by myself: eventRender is the right place for that!

  $('#calendar').fullCalendar({
    eventRender: function(evt, element) {
      element.droppable({
        accept: '.myevent',
        tolerance: 'pointer',
        activeClass: 'ui-state-hover',
        hoverClass: 'ui-state-active',
        drop: function(ev, ui) {
          alert('call dropped'); 
        }
      });
    },
    ....
    ....
  });

it is not necessary to modify fullcalendar.js

It may not be a direct answer to your question but you can consider it as an alternative option. I have used another jQuery based calendar plugin named Calendario and its pretty easy to add events in it.

Calendario

Github Repo

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!