javascript - How to extract event from one source only Fullcalendar -


i have build program employees of company declare days of work, vacation, days of illness etc.. idea use fullcalendar drag , drop function make nice. on month view, drag event "work" , put days worked, simple that.

what try do, extract event displayed put them in database, tried using :

$('#calendar').fullcalendar('clientevents'); 

but event googlecalendar used display public holidays in background event.

in other words, have 2 types of events, ones drag , drop, , ones put there googlecalendar on backgroundevents.

simply put, how can filter event extract ignore googlecalendar? put in array event calendar, don't want google.

if possible, i'd grateful hint on next step, putting events in data base.

what solution extract event added hand?

alright, got mate @ office. leaving answer here in case:

googlecalendars events , manually added events don't have same attributs, googlecalendars ones have 'source' , 'url' attribut others don't have.

what want event, loop through array , select thoses doesn't have source attribut. :

function send(){         var  cal_events = ''        data= $('#calendar').fullcalendar('clientevents');         (var key in data) {             var event = data[key];              if (typeof(event.source) == 'undefined'){                  //your stuff                     }                  });             }         }     } 

that way can act on events without 'source' attribut.

thanks anyway. robin


Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -