PDA

View Full Version : API documentation for RowEditor



sramanna
18 May 2009, 6:38 AM
Hello,

Where can I find the API documentation for the new RowEditor class in Ext 3.0.

Thank you

Animal
18 May 2009, 6:41 AM
It's example code, not a part of the product.

mitch_feaster
18 May 2009, 2:07 PM
Just example code, yet is it listed on the ExtJS blog as "another great new UI component allowing you to rapidly edit full rows in a grid"?

Could someone who knows how to use the RowEditor (which I must say is insanely awesome) at least post an example with some type of save function? I've looked through the source code and can't figure out how to bind a function to the clicking of the save button.

mitch_feaster
18 May 2009, 2:52 PM
I figured it out. For anyone having this same issue the key is to bind to events on your datastore. E.g.


SomeDataStore.on('update', yourSaveFunction)I still wouldn't mind seeing some documentation for this new component. Is the best thing to do just go off of Panel since that's what it inherits from?

sramanna
18 May 2009, 2:59 PM
Hi Mitch,
Thanks for your reply.

When you do this :
SomeDataStore.on('update', SaveFunction)

The saveFunction can be an ajax request to save the record in the server/database.
is that right ? This way, we can be saving the data remotely when we click the
roweditor save button. let me know if i understood it right.

mitch_feaster
18 May 2009, 3:52 PM
Exactly. check out addListener in the api doc for the useful parameters that will be sent to your "SaveFunction".

sramanna
18 May 2009, 3:58 PM
ok. Thank you.

If there is an error executing the "SaveFunction", (something caught in validation at the backend), Do you know how we can roll back the datastore (as the datastore would be updated locally already and we are calling saveFunction upon update).

Animal
18 May 2009, 11:19 PM
Just example code, yet is it listed on the ExtJS blog as "another great new UI component allowing you to rapidly edit full rows in a grid"?

Could someone who knows how to use the RowEditor (which I must say is insanely awesome) at least post an example with some type of save function? I've looked through the source code and can't figure out how to bind a function to the clicking of the save button.

There is a row-editor.html example page in examples/grid (at least in SVN there is, I don't know about the RC1 download), so Ext 3.0 will have what you want.

mjlecomte
19 May 2009, 3:44 AM
In svn, most of the "example classes / implementations", have been moved to an "ux" folder. "ux" meaning user extension, ie, not part of core library to be included with ext-all.

Several of the example classes do not have documentation so, at present, you'll need to review the source or infer through provided examples, etc.

ebinfo
5 Jul 2010, 6:17 AM
hi all.

i looked at the store.on('update', function()) thing and it is great if you want to save one field at a time, which in my opinion is defeating the purpose of a full row editor.

does anyone know how to make the edit happen only when the 'update' button is clicked and it will then send one call to edit all fields within the row?