generalized date change function

The ledgerDateChange function is slightly modified and name changed to
ledgerPrimaryFieldChange. This will allow other fields, such as the amount
field, to use this same function for editing.
amount edit uses newly modified function

amount edits should create a new entry if it is a first edit. This
preserves the origional downloaded entry for comparing to prevent
duplicates in future downloads. Subsequent edits of the amount (and date)
fields simply update the value of the new entry.
escape strings added to record adding and editing
all field editing works perfectly ^_^
handles printing apostorphies in the querried comments

fails sometimes, like on FRY's, though I catch open, closed, and normal
apostrophies. The data is in the DB, it's just not printing.