I made a program that uses wpf(C#) as client side and wcf service server side.
For data exchange i use stes(self tracking entities).
In my database i have a table clients and a table presence. database model see below
<img src="https://dl.dropboxusercontent.com/u/18695256/DB.PNG" />
database model[
^]
In my wpf application i have a listbox with a list of clients and an update presence side
when a client is selected his personal info, his presence of today is shown.
<img src="https://dl.dropboxusercontent.com/u/18695256/MainWindow.PNG" />
window image[
^]
I know the image is in a different language but its just to show you how it looks like.
To show the clients info i just fetch the info from the server and use a viewmodel to show presence and client info. ( if the user does not have a presence yet i make a new one and ad the client info and clientid to the presence class.
I want to implement a cancel method.
I have found:
that you can do that by making a deep copy: with something like:
Clone by serialize and deserialize[
^]
or make the ste track all the original values and reroll when there is clicked on cancel.
Are there other options?
And what option do you find best?