677 add version number to xform and endpoint to replace a form

closes #677 and #542 
null should not allowed and this should default to 1, the the initial version. If possible we should also add a constraint that it must be unique relative to the id_string, e.g. if you have `(id_string: "blah", version: 1)` and `(id_string: "blah2", version: 1)` that's OK, but if I now try to add `(id_string: "blah", version: 1)` I get a uniqueness error.

But `(id_string: "blah", version: 2)` would be fine.