Use type converted data when writing back to database.

This allows foreignKey types and other custom types to be converted into native values before writing them to the database.  There are likely other places something similar needs to be done and it will need to be validated against other connectors than the Mongo one.

See https://github.com/strongloop/loopback-datasource-juggler/issues/58