-
21 Jan 2013 12:22 AM #1Sencha - Community Support Team
- Join Date
- Nov 2007
- Location
- Helsingborg, Sweden
- Posts
- 2,460
- Vote Rating
- 56
[4.2.0.265] TreeStore CRUD broken
[4.2.0.265] TreeStore CRUD broken
This was broken back in 4.0.x, new regression in 4.2.0. 'internalId' is not set on a newly created Record. This breaks nodeHash when removing a record later.
Server responds:Code:Ext.onReady(function() { Ext.define('Task', { extend: 'Ext.data.Model', idProperty : 'Id', fields: [ {name: 'Id' }, {name: 'task', type: 'string'}, {name: 'user', type: 'string'}, {name: 'duration', type: 'string'}, {name: 'done', type: 'boolean'} ] }); var store = Ext.create('Ext.data.TreeStore', { model: 'Task', proxy: { type: 'ajax', //the store will get the content from the .json file api: { create : 'treecreate.json' } }, root : {}, listeners : { write : function() { console.log(this.getRootNode().firstChild.internalId) // SHOULD BE 111 } } }); store.getRootNode().appendChild(new Task({})); store.sync(); });
Code:[{ task:'Project: Shopping', Id : 111, user:'Tommy Maintz', iconCls:'task-folder' }]
-
22 Jan 2013 12:37 PM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,714
- Vote Rating
- 438
Thanks for the report! I have opened a bug in our bug tracker.
Success! Looks like we've fixed this one. According to our records the fix was applied for
EXTJSIV-8281
in
4.2.0 Sprint 3.


Reply With Quote