EddyVerbruggen / Calendar-PhoneGap-Plugin

:date: Cordova plugin to Create, Change, Delete and Find Events in the native Calendar
773 stars 402 forks source link

Cordova-Calendar-plugin doesnt seem to work in iPhone #497

Open Junijoh opened 5 years ago

Junijoh commented 5 years ago

This is my function for creating an event in the calendar. After checking for deviceready state only, I'm calling the below function.It doesnt invoke success function. function create() { alert("creating event"); var title= "My Sample Appt"; var location = "Los Angeles"; var notes = "This is a sample note"; var startDate = new Date(2018,2,15,18,30,0,0,0); var endDate = new Date(2019,2,15,19,30,0,0,0); cal = window.plugins.calendar; cal.createEvent(title,location,notes,startDate,endDate, success, error);

}

function error (theerror) { alert("Error occurred - " + theerror); } function success(themessage) { alert("Success - " + themessage); }

jkenjar commented 5 years ago

@EddyVerbruggen Im also having issues with the ios plugin

hamrak commented 5 years ago

I have the same issue on iOS (plugin version is 5.1.4), error or success callbacks aren't called and there are no events in native calendar. Without any JS error. Android is fine.

PS: When I remove background threading it works. [self.commandDelegate runInBackground:^{ ... }];