features/calendar/assets/js/calendar.js
/**
 * Check if calendar event exists for morgue entry
 */
Check if calendar event exists for morgue entry
Check if calendar event exists for morgue entry
function checkEventExists() 
{
    gapi.client.load('calendar', 'v3', function() {
            var request = gapi.client.calendar.events.get({
                'calendarId': cal.id,
                'eventId': cal.eventId
            });
            request.execute(function(event) {
                if (event.hasOwnProperty('error')) {
                    cal.event = null;
                    showEventLink(false);
                    showCalendar(null);
                } else {
                    cal.event = event;
                    showEventLink(true);
                    showCalendar(event.start.dateTime);
                    showEvent();
                    showFacilitator();
                }
            });
    });
}
function checkEventExists ( ) { gapi . client . load ( 'calendar' , 'v3' , function ( ) { var request = gapi . client . calendar . events . get ( { 'calendarId' : cal . id , 'eventId' : cal . eventId } ) ; request . execute ( function ( event ) { if ( event . hasOwnProperty ( 'error' ) ) { cal . event = null ; showEventLink ( false ) ; showCalendar ( null ) ; } else { cal . event = event ; showEventLink ( true ) ; showCalendar ( event . start . dateTime ) ; showEvent ( ) ; showFacilitator ( ) ; } } ) ; } ) ; }
Check if calendar event exists for morgue entry
Check if calendar event exists for morgue entry