debugging of undo and redo

undo and redo should be working for add and edit.
still working on delete