Duplicating dynamically added event on click


Hi ,

I have my situation where i want help to understand the problem
First let me explain my case. This could be a little long


These are the events registered in my database and showing on scheduler.

So what i need is… that if someone click any event it should gets duplicate with same date and time like in below screen shot.


which is working fine it is getting duplicated and saved into database as a new entry…
with these details in console.

Now my problem is with dynamically added new Event in scheduler with some button and using addEvent() method which has no database record entry.


Like in above screen shot there is my first event with text ( WORKING ) and other are also there with no text.

So when i click any of them they should also work. But they aren’t .

Instead of sending correct details it is getting random date and time automatically and in console what i noticed is that the SCHEDULER id is different in OnEventAdded function and while sending in request is different. . if you go little up and compare these console screen shot with first you will see the difference better.


in above first screen shot tells you my accurate data but in request this is going like empty… something is overriding it in this case where we are clicking dynamically created event after scheduler load.

How this is getting different i have no clue. can any one tell ?

This is how i’m duplicating the events:-

  scheduler.attachEvent("onClick", function(id, e)
var ev=scheduler.getEvent(id);
var newtemp={


return true;




It is difficult to guess what goes wrong. I tried to reproduce and event is created correctly, but I can’t check the request to the server.

Check if xml_date configuration corresponding to the date format that you sent to the server.

If you can share complete demo that I can run locally - it could help me to investigate the issue.


Hi Dear,

I’m uploading my problem project for you on below link

So first you will see this

In this i have made some events stored in database.
If we click any of them it will work. Like in below screen shot

Next You will find a button on top for getting dynamic events which will be created on scheduler without saving into database. In below screen shot you will find some new dynamic events.

Now Problems starts from here.
If you click any one of them. Like i am clicking the last one

You will see it is doubled with same ONCLICK text event. But actually what happened is that It has created a new slot if you will refresh the page like in below screen shot.

The above screen shot is after page refresh and you will find a newly created entry with that same text of dynamic event. I really don’t know how this is happening… This is going into the onclick method where i have set the text as ONCLICK like you’ve seen in first example…

So from now on without REFRESHING the page if i click any event no matter if it is saved in db or it is a dynamic… This problem will repeat.

You can also check the console logs I’ve set for you.

Also you can delete current view events from top button if you test it.

i hope you will have answer for me… Thanks in advance.



Hi I’m waiting for anyone’s reply.


Hi @Polina.
I want to know if you have checked this issue please.?