[ALOY-486] sql adapter does not update ID in client-side model when using AUTOINCREMENT
|Affected Version/s||Alloy 1.0.0|
|Fix Version/s||Alloy 1.0.0, 2013 Sprint 02|
DescriptionIf a new model is being created that relies on an AUTOINCREMENT id, it is not updated in the client-side model when the INSERT happens. The id doesn't update until the next collection.fetch(), and model.fetch() doesn't work because there's no id to match up to on the client-side. To resolve this issue we should grab the last inserted id after a new model is created and assign it to the model's model.id field, if the idAttribute is not the Alloy default "alloy_id". If it's "alloy_id", then just assign a GUID.
- Federico Casali 2013-02-20 Alloy: 1.0.1 master TiSDK: 3.1.0.v20130219190219 CLI: 3.0.24 Verified as fixed. Using the 'models/sql_no_migration', added Log info (http://pastie.org/6262111 ) Closing.