I've been working on an app where community managers can input events using the prebuilt calendar module and adjust their times, these events will be added to our firestore database and displayed to other devices using our backend. However when changing the times of the events by dragging the event duration down or moving it to an entirely different time slot the fields of the calendar1.events change and lose the _id field which I need to reference in my looping query to update the documents in firebase. I've been trying to find a way to work around to this but since the calendar seems to lack a property holding a record of changes I'm not quite sure what to do.
The process I currently have is as follows:
User drags an event up or down the time axis to adjust event duration or moves the event entirely and they select yes on the dialog:
A JS query that loops through all objects in the calendar1.events array and passes data to another query that runs for each object
The result in firebase is that an object with a null _id property is created, and the targeted event's fields remain the same as they were: