PDA

View Full Version : About Ext.data.Store.getById



jianwen_yu
10 May 2007, 12:18 AM
How to use it?
wish an example about it!

jsakalos
10 May 2007, 2:02 AM
Watch the grid screencasts (videos) it is used there.

soad
10 May 2007, 2:13 AM
Here is how I use this method:



var rec = this.getDataSource().getById(this.id);
rec.beginEdit();
rec.set('currentPage', this.getCurrentPage());
rec.set('numPages', this.getNumPages());
rec.endEdit();
rec.commit();


As you see in the example, it retrieves a record by it's id and updates a couple of fields.

HTH

jianwen_yu
10 May 2007, 5:03 AM
Thanks for your help!