This is a migrated thread and some comments may be shown as answers.

Delete Series with confirmation

2 Answers 8 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
ManniAT
Top achievements
Rank 2
ManniAT asked on 05 Aug 2014, 02:36 PM
Hi,

I'm handling series without exceptions.
So in other words - the user always edits the whole series (or a single appointment if no recurrence is defined).

I found a thread here how to suppress the "Series or single appointment" dialog on editing.
It suppresses the dialog - and shows the edit form for series - this is fine, but it also suppresses the delete confirmation.

I found out how to "filter between edit and delete" - but I have no idea how to go on.
What I want is a "normal" confirmation dialog "Do you want to delete the series"???

Here my code so far....
function RecurrenceActionDialogShowingHandler(sender, args) {
 
    if (args._recurrenceAction == 1) {
        args.set_cancel(true);
    }
    //Edit this instance only: 
    //args.set_editSeries(false); 
 
    //Edit the entire series: 
    args.set_editSeries(true);
}

It suppresses the selection for edit - but shows it for delete.

Manfred

2 Answers, 1 is accepted

Sort by
0
Accepted
Plamen
Telerik team
answered on 07 Aug 2014, 08:37 AM
Hello Manfred,

Here is the code that worked correctly at my side:
function recurrenceActionDialogShowingHandler(sender, args) {
               
               if (args._recurrenceAction == 1) {
                   args.set_cancel(true);
                   args.set_editSeries(true);
               }
               if (args._recurrenceAction == 2) {
                   args.set_cancel(true);
 
                   if (confirm("Do you want to delete the series?")) {
                       args.set_editSeries(true);
                   }
               }
           }

Hope this will help you solve the issue. 

Regards,
Plamen
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
ManniAT
Top achievements
Rank 2
answered on 07 Aug 2014, 11:18 AM
Hello Plamen,

works like a charm :)

Perfect support as always at telerik!

Thank you
Manfred
Tags
Scheduler
Asked by
ManniAT
Top achievements
Rank 2
Answers by
Plamen
Telerik team
ManniAT
Top achievements
Rank 2
Share this question
or