-
4 May 2012 2:21 PM #1
ST 2.0.1 - Store.load() does not update nested (hasMany) relationship
ST 2.0.1 - Store.load() does not update nested (hasMany) relationship
When using myStore.load() i do not get an updated nested store. This seems to be a bug as I can't find a way to do this otherwise/manually.
Config of the model :
Code:config: { idProperty: '_id', fields: [ {name: "_id", type: "string"}, {name: "email", type: "string"}, {name: "firstName", type: "string"}, {name: "lastName", type: "string"}, //{name: "cards", inner: true}, ], hasMany: [{ model: app.ns + '.model.Card', name: 'cards', primaryKey: '_id', foreignKey: 'user_id' }], proxy: { type: 'rest', url : app.ep + '/users', enablePagingParams: false, reader: { type: 'json', rootProperty: 'data' } } },
-
4 May 2012 2:53 PM #2
This seems to fill my needs, but not sure there is no side effects.
Code:{name: "cards", inner: true, convert: function(v, record) { record.cards().removeAll(); record.cards().setData(v); return v; }},
Thank you for reporting this bug. We will make it our priority to review this report.


Reply With Quote