We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Remove confirmation popup when dropping event

Thread ID:

Created:

Updated:

Platform:

Replies:

150516 Jan 9,2020 12:29 PM UTC Jan 14,2020 04:03 AM UTC Angular - EJ 2 5
loading
Tags: Schedule
Alexey Bogdanov
Asked On January 9, 2020 12:29 PM UTC

How can remove confirmation popup when dropping event. Event should just drop without any confirmation?
Thanks)

Vengatesh Maniraj [Syncfusion]
Replied On January 10, 2020 05:30 AM UTC

Hi Alexey, 

Greetings from Syncfusion Support. 

We can achieve this by using of addEvent method instead of using openEditor method in event drop events. We have prepared below sample based on the requirement.  


In the above sample, we have used addEvent in onTreeDragStop method like below, 

let eventData: { [key: string]: Object }  
                if (event.target.classList.contains('e-work-cells')) { 
                    let cellData: CellClickEventArgs = this.scheduleObj.getCellDetails(event.target); 
                    let resourceDetails: ResourceDetails = this.scheduleObj.getResourcesByIndex(cellData.groupIndex); 
                    eventData = { 
                        Id: filteredData[0].Id, 
                        Name: filteredData[0].Name, 
                        StartTime: cellData.startTime, 
                        EndTime: cellData.endTime, 
                        IsAllDay: cellData.isAllDay, 
                        Description: filteredData[0].Description, 
                        DepartmentID: resourceDetails.resourceData.GroupId, 
                        ConsultantID: resourceDetails.resourceData.Id 
                    }; 
                    
                } 
                // Handled the appointment drop for event target 
                let elem = closest(event.target, '.e-appointment'); 
                if(elem){ 
                      let appointment: { [key: string]: Object } =this.scheduleObj.getEventDetails(elem) as any; 
                        eventData = { 
                          Id: filteredData[0].Id, 
                        Name: filteredData[0].Name, 
                        StartTime: appointment.StartTime, 
                        EndTime: appointment.EndTime, 
                        IsAllDay: appointment.isAllDay, 
                        Description: filteredData[0].Description, 
                        DepartmentID: appointment.DepartmentID, 
                        ConsultantID: appointment.ConsultantID 
                    }; 
                } 
                this.scheduleObj.addEvent([eventData]);  

Kindly try the above sample and revert us for further assistance with this. 

Regards, 
Vengatesh 


Alexey Bogdanov
Replied On January 10, 2020 07:36 AM UTC

This sample working for waiting list, when we dragging appointment to schedule.
How can remove confirmation popup when removed event from schedule.

Actions:
- clicked by appointment on the schedule;
- clicked on delete icon (need remove appointment without modal popup) 

Attachment below.

Thanks)

Attachment: Actions_32dafdeb.zip

Vengatesh Maniraj [Syncfusion]
Replied On January 13, 2020 05:51 AM UTC

Hi Alexey, 

Thanks for the update. 

We have prepared the below sample based on the requirement. In this sample, we have used popupOpen event to prevent the DeleteAlert and delete the event without confirmation by making call of deleteEvent method. 

onPopupOpen(args: PopupOpenEventArgs) { 
    if (args.type === 'DeleteAlert') {      
      args.cancel = true; // prevent the alert window 
      this.scheduleObj.deleteEvent((args.data as any).Id); // delete the event 
    } 
  } 

Kindly try the above and let us know for further assistance. 

Regards, 
Vengatesh 


Alexey Bogdanov
Replied On January 13, 2020 07:28 AM UTC

Thanks.
It helped me)

Vengatesh Maniraj [Syncfusion]
Replied On January 14, 2020 04:03 AM UTC

Hi Alexey, 

You are most welcome. 

Regards, 
Vengatesh 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon