does not refresh at fullcalendar after refresh

0

Good morning, I need some help. I have a fullcalendar that when I make a change it does not give the refresh on the screen. Can anyone help?

* follow part of the code: *

// Quando der duplo clique vai abrir o modal de alteração (update_cal.php)
    eventRender: function (event, element) {
        element.bind('dblclick', function () {
        $('#ModalEdit #event_id').val(event.id);
        $('#ModalEdit #id').val(event.id);
        $('#ModalEdit #title').val(event.title);
        $('#ModalEdit #start').val(moment(event.start).format('DD/MM/YYYY 
        HH:mm:ss'));
        $('#ModalEdit #end').val(moment(event.end).format('DD/MM/YYYY 
        HH:mm:ss'));
        $('#ModalEdit #color').val(event.color);
        $('#ModalEdit #obs').val(event.obs);
        $('#ModalEdit').modal('show');
    });
},

here is the part of ajax.

$.ajax({
    url: this.action,
    type: this.method,
    data: array + '&SendPostForm=',
    dataType: 'json',
    success: function (response) {
        if (response.status === 'OK') { 
            $('#ModalEdit').modal('hide');
            $('#calendar').fullCalendar('removeEvents', function (event) {
               return event.id === $("#editEvent #event_id").val();
            });
    $("#calendar").fullCalendar('addEventSource', response.data);
    $("#editEvent").trigger("reset");
        alert(response.text + ' ===> ' + '&SendPostForm=');
    } else if (response.status === 'Error') {
        alert(response.text + ' ==> ' + '&SendPostForm=');
    } else {
          alert('Ocorreu um erro, tente novamente.' + ' => ' + '&SendPostForm=');
    }
}

});

    
asked by anonymous 09.03.2018 / 15:08

0 answers