extjs4.2 - EXTJS 4.2.0.663 : Buffered store with editor grid -
buffered store editor grid.
we have been using version 4.1.1 , migrating 4.2.0.663. have editor grids buffered stores contain large volume of data. editor grids similar row-editing example(except uses buffered store). add functionality grid has stopped after migration , raises error
ext.error: insert operation not supported buffered store.
var rowediting = ext.create('ext.grid.plugin.rowediting', { clickstomoveeditor: 1, autocancel: false }); // create grid , specify field want // use editor @ each column. var grid = ext.create('ext.grid.panel', { store: store, columns: [{ header: 'name', dataindex: 'name', flex: 1, editor: { // defaults textfield if no xtype supplied allowblank: false } }, { header: 'email', dataindex: 'email', width: 160, editor: { allowblank: false, vtype: 'email' } }, { xtype: 'datecolumn', header: 'start date', dataindex: 'start', width: 90, editor: { xtype: 'datefield', allowblank: false, format: 'm/d/y', minvalue: '01/01/2006', mintext: 'cannot have start date before company existed!', maxvalue: ext.date.format(new date(), 'm/d/y') } }, { xtype: 'numbercolumn', header: 'salary', dataindex: 'salary', format: '$0,0', width: 90, editor: { xtype: 'numberfield', allowblank: false, minvalue: 1, maxvalue: 150000 } }, { xtype: 'checkcolumn', header: 'active?', dataindex: 'active', width: 60, editor: { xtype: 'checkbox', cls: 'x-grid-checkheader-editor' } }], renderto: 'editor-grid', width: 600, height: 400, title: 'employee salaries', frame: true, tbar: [{ text: 'add employee', iconcls: 'employee-add', handler : function() { rowediting.canceledit(); // create model instance var r = ext.create('employee', { name: 'new guy', email: 'new@sencha-test.com', start: ext.date.cleartime(new date()), salary: 50000, active: true }); store.insert(0, r); rowediting.startedit(0, 0); } }], plugins: [rowediting], });
please advise on approach followed.
have similar problem row editing plugin. looks problem related buffered store internals changed. solve issue can:
- extend row editing plugin , change way insert data. after inserting reload current page of data or so...
- switch using buffered store using bufferedrenderer plugin grid. quick overview of plugin can find here: bufferedrenderer
- do deeper research, there solution without eliminating buffered stores.
i case i'm going choose second way unless clarify changes in buffered stores in extjs 4.2...
update: appears buffered stores have limited functionalty in 4.2. , still buggy. have problem now: commit bug
Comments
Post a Comment