Welcome Guest, Not a member yet? Register   Sign In
CI + FullCalendar
#1

[eluser]austintbiggs[/eluser]
I currently have a working implementation of FullCalendar, but the only missing elements are edit & delete functions straight from the calendar. From a form it's currently possible to edit and create events, but not directly from the calendar. At http://duckranger.com/2010/04/fullcalend...ng-events/ they have added these functions, but this is for CakePHP. So I guess what I'm asking is how would I translate this to CI?
#2

[eluser]yuvaraj[/eluser]
Hi,
This is my first post in this forum if you find any bugs please let me know so that i can take a look into it.
Use this code for edit functionality hope this might help u!
I haven't tried for add functionality i'll let u know after checking it. hope u r using arshaw fullcalendar plugin and this code is for arshaw full calendar plugin.
Code:
eventMouseover: function(event) {
                          
    var layer = '<div id="events-layer" class="fc-transparent">a><img src="images/edit.png" title="delete" width="14" id="editbut'+event.id+'" border="0" /></a></div>';
                                $(this).append(layer);
    $("#edbut"+event.id).hide();
    $("#edbut"+event.id).fadeIn(300);
    $("#edbut"+event.id).click(function() {
     var title = prompt('Current Event Title: ' + event.title + '\n\nNew        Event Title: ');
    
     if(title){
      $.post("urcontroller", {eventId: event.id, eventTitle: title});
do the rite thing in controller
      calendar.fullCalendar('refetchEvents');
     }
    });
                                
    
   },
  eventMouseout:function(){
                            $('#events-layer img').css('display','none');
                        }
use this style in fullcalendar.css
Code:
.fc-transparent,
.fc-agenda .fc-transparent .fc-event-time,
.fc-transparent a {        
padding-left: 1px;                                              
border-color: transparent;
background-color: transparent;
color: #fff;
}
sorry i cannot attach the image for edit,
kindly refer the below url and download the image.
url:http://www.iconfinder.com/icondetails/14042/10/edit_pen_pencil_write_icon
Regards,
Yuva




Theme © iAndrew 2016 - Forum software by © MyBB