My favorites | Sign in
Project Home Issues
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 28: Extend an event
1 person starred this issue and may be notified of changes. Back to list
Status:  Done
Owner:  ----
Closed:  Jun 2009


Sign in to add a comment
 
Reported by coryama...@gmail.com, Jun 2, 2009
Great calendar by the way :)

I was wondering if I could get just a little help on hacking fullcalendar
to be able to grab a handle on an event and drag to extend the event.  I
have added the handles (div at front and back of the element) and added the
draggable code, I'm just not sure how to best get the event associated with
the handle and alter the start time or end time.

Any help would be appreciated

cory a marsh at gmail dot com

thanks!
Jun 2, 2009
Project Member #1 adamrs...@gmail.com
not sure how you are inserting the handles, but i'd do something like this:

eventRender: function(event, element) {
   element.resizable({
      stop: function() {
          // calculate new start + end times, assign to...
          event.start = ...
          event.end = ...
          $('#yourcalendar').fullCalendar('updateEvent', event);
      }
   });
}
Jun 5, 2009
Project Member #2 adamrs...@gmail.com
post another comment if you are still having issues.
Status: Done
Jun 9, 2009
#3 coryama...@gmail.com
oh no.  I got it all working.  your post was helpful.  I ended up ended up replacing
the table with 3 divs, two handles and one content area.  I added new draggable
events to the handles that calculate deltas, and instead of adding the deltas to both
start and end, I just add them to start or end respectively.  It was pretty easy once
I got a little bit better understanding of jQuery and the calendar code.

Thanks again.  IF you like I can submit my changes?
Jun 15, 2009
Project Member #4 adamrs...@gmail.com
glad you got it to work. functionality like this will definitely be in a future
release. probably won't be in the next version though, I'm saving all my time to
implement a week-view, but after that, yes. I won't promise that i'll use your code
verbatim, but id be interested in looking at it if you want to post it on this thread.
Sign in to add a comment

Powered by Google Project Hosting