save birth and death dates

also tidy up the code a chunk to remove duplication, handle edge cases
of removing dates requiring a null to be passed.
Rudimentary handling of errors.
reset edit field values when canceling edit

when the cancel button is pressed it should reset the values in the edit
fields to their original values which it does by looping through them
and pulling in the values from the view equivalents