I have a modaldialog where I do add,edit and delete operations. The problem I have are when I start editing and then before saving the work - I press the Cancel button. The database is not updated and that is good, but the DOM? is updated.
So my question are - how can I cancel the updating of the DOM?.
The datalist before I start
The modal/popup window before I start edit
I change the Name field
Then I press CANCEL button - and as you can see - the Name is changed
When I refresh the page - the changed value is back to original value.
My code look like this