View Full Version : [CLOSED] How I create a 'Add Item' gridPanel?

Feb 23, 2012, 1:55 PM

I wish create a gridPanel in 'add item' mode.
i.e, the last line in blank. When i click in columns of this last line, a new line is created bellow and the current line is editable.

The data should be stored in memory, or in local array, and update in the database only then OK button clicked.

There are any example for I follow?

thanks for any help!

Feb 23, 2012, 3:01 PM

Unfortunately, we have no such example.

I think it's possible and there should not be a big problem.

I would look into the Events API of the CellEditing plugin. You, probably, will need to use its BeforeEdit and Edit events.
http://docs.sencha.com/ext-js/4-0/#!/api/Ext.grid.plugin.CellEditing-event-beforeedit (http://docs.sencha.com/ext-js/4-0/#%21/api/Ext.grid.plugin.CellEditing-event-beforeedit)
http://docs.sencha.com/ext-js/4-0/#!/api/Ext.grid.plugin.CellEditing-event-edit (http://docs.sencha.com/ext-js/4-0/#%21/api/Ext.grid.plugin.CellEditing-event-edit)

Feb 23, 2012, 3:18 PM

I try follow this examples.

Thank you, Daniil!