Add type conversion to editor

- In DocumentEditor can change the data type of a field
- Correctly resolve between double/int32/int64 (as mongo stores
everything as a double internally)