-
14 Nov 2012 6:27 AM #1
Grid with CellEditing inside FormPanel
Grid with CellEditing inside FormPanel
I'm having a problem with grids that are inside the form panel (Ext 4.1.2). The thing is that if I change the value in cell and while still editing go to somekind of form field, it doesn't show cell new value. Instead it shows the old. But when again starting to edit the cell, it shows the value I inserted (thus store is updated).
The problem is similar when you add Ext.form.Panel to code in here:
http://docs.sencha.com/ext-js/4-1/#!...in.CellEditing
When you now change names, it still shows Bart and Lisa, although it is changed to something else (you can see the real value when starting editing cell again).
The code I used:
Does anybody have a clue how to fix this?Code:Ext.create('Ext.data.Store', { storeId:'simpsonsStore', fields:['name', 'email', 'phone', 'number'], data:{'items':[ {"name":"Lisa", "email":"lisa@simpsons.com", "phone":"555-111-1224"}, {"name":"Bart", "email":"bart@simpsons.com", "phone":"555-222-1234"}, {"name":"Homer", "email":"home@simpsons.com", "phone":"555-222-1244"}, {"name":"Marge", "email":"marge@simpsons.com", "phone":"555-222-1254"} ]}, proxy: { type: 'memory', reader: { type: 'json', root: 'items' } } }); Ext.create('Ext.form.Panel', { items: [Ext.create('Ext.grid.Panel', { title: 'Simpsons', store: Ext.data.StoreManager.lookup('simpsonsStore'), columns: [ {header: 'Name', dataIndex: 'name', editor: 'textfield'}, {header: 'Email', dataIndex: 'email', flex:1, editor: { xtype: 'textfield', allowBlank: false } }, {header: 'Phone', dataIndex: 'phone'}, {header: 'iiiii', dataIndex: 'number', field: {xtype: 'numberfield'}} ], selType: 'cellmodel', plugins: [ Ext.create('Ext.grid.plugin.CellEditing', { clicksToEdit: 2 }) ], height: 200, width: 400, renderTo: Ext.getBody() })] });
Thanks for any help!
-
14 Nov 2012 6:41 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,656
- Vote Rating
- 436
So I change the value in a cell and it changes. Try to edit it again and everything is working. How do I reproduce?
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
14 Nov 2012 6:47 AM #3
-
14 Nov 2012 6:55 AM #4Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,656
- Vote Rating
- 436
Using 4.1.1, 4.1.2 and 4.1.3 with Chrome I cannot reproduce.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
18 Nov 2012 4:18 AM #5
I solved my problem. It appeared that the problem was between the chair and computer. The problem I had was not connected to the problem I reported in the Sencha Docs (although I can still create that problem when replacing the code in Sencha docs).
Cheers!
Looks like we can't reproduce the issue or there's a problem in the test case provided.


Reply With Quote