PDA

View Full Version : GXT 1.5.4 - Grid to Form Binding



marman
6 May 2009, 11:50 AM
Is it possible to use a FormBinding from a Grid and have it *only* update the grid when I click a button rather than update after I click off a field?

Webflash
8 May 2009, 8:33 AM
Is it possible to use a FormBinding from a Grid and have it *only* update the grid when I click a button rather than update after I click off a field?
No :-(
I need this functioonality to :-)

marman
8 May 2009, 8:37 AM
I worked around it....

basically, i do not bind the Store to the form. I call update or delete on the store object and then do a manual refresh of the GridView class. this seems to be working for me.

kaeptn
12 May 2009, 8:42 AM
Could you please post sample code? I have a similar problem and since I am rathe rnew I really would appreciate a heads up ...

TIA

marman
13 May 2009, 4:02 AM
Could you please post sample code? I have a similar problem and since I am rathe rnew I really would appreciate a heads up ...

TIA






grid.getStore().update( formPanel.getAccountVO() );
grid.getView().refresh( false );

Colin Alworth
13 May 2009, 7:52 AM
Not to ask you to write this for me ;), but what about the converse, updating the original model object when the grid changes?

Thanks for sharing!

kaeptn
14 May 2009, 1:06 AM
grid.getStore().update( formPanel.getAccountVO() );
grid.getView().refresh( false );



Cool ... thanks for that ... what does the getAccountVO method look like? And where do I find store.update() method in the documentation? How did you know it is there?

Thanks ... I'll try that way ...

EDIT
... forget that ... update() is not available to a store in ExtJS ... I overlooked that you are using GXT and now that I know these are different I have to search again foir my problem ;) ... thanks anyways ...
/EDIT