DP 7.1.2695 DP Month
I'm running into trouble trying to delete events in a Month cal with recurrence support. How can I call a delete/remove function from JavaScript?
Calling Delete from a DP Menu item:
<DayPilot:MenuItem Text="Delete" Action="JavaScript" JavaScript="deletePrompt(e);" Command="open"> </DayPilot:MenuItem>
function deletePrompt(e) {
// alert("Delete Hit");
// Normal event
if (typeof e.recurrent === "undefined") { //e.recurrent doesn't appear to return valid recurrence info
dpm1.events.remove(e); // need valid Monthcal client method here
}
// Recurrent event
else {
var modal = new DayPilot.Modal();
modal.top = 150;
modal.width = 300;
modal.height = 150;
modal.opacity = .9;
modal.border = "10px solid #d0d0d0";
modal.showUrl("RecurrentDeleteModal.html");
// Also need valid delete method to call from within RecurrentDeleteModal.html
}
}
Am I going about this the correct way?
Thanks!