« Return to Thread: Updates within Panels in datatable

Re: Updates within Panels in datatable

by salmas :: Rate this Message:

Reply (Restricted by the Administrator) | Reply to Author | View in Thread

Hi Igor:

I cannot use the AjaxSubmitButton because I need to change the button's model dynamically and this functionality is broken in Wicket 1.2 and I can’t use the 1.3 beta because my company doesn’t want to use beta software for a production release. I ended up using a regular Button and then updating the table using an AJAX Target in the buttons onSubmit method. Please do let me know if you have a better suggestion for what I can do here.
I tried
                ReuseIfModelsEqualStrategy strategy = new ReuseIfModelsEqualStrategy();
                table.setItemReuseStrategy(strategy);

but this did not help. Do I need to create a custom strategy? If so what should I do in it?

igor.vaynberg wrote:
On 7/31/07, salmas <ssaad@ecascabel.com> wrote:
>
> - Even though I do nothing in onSubmit (which I know does get called) the
> table is reloaded (button.getRequest() shows the request for the page to
> reload). I'd like to stop the auto redraw and do an AJAX update from
> within
> onSubmit instead, I am not sure how to stop the table reload when the
> button
> is clicked.


use ajax submit button

- from within onSubmit() in panel2 the textfield and the radio button in
> panel1 show their original values and not the values that I typed in prior
> to pressing the button. The widgets have PropertyModels. To load the
> panels
> I overrode public void populateItem(Item item, String componentId, IModel
> model) in the table columns and then added the panels where appropriate.
> What can I do to update the data in panel1 when the button in Panel2 is
> clicked?


see datatable.setitemreusestrategy(...)

-igor


--
> View this message in context:
> http://www.nabble.com/Updates-within-Panels-in-datatable-tf4196594.html#a11935400
> Sent from the Wicket - User (OLD) mailing list archive at Nabble.com.
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc.
> Still grepping through log files to find problems?  Stop.
> Now Search log events and configuration files using AJAX and a browser.
> Download your FREE copy of Splunk now >>  http://get.splunk.com/
> _______________________________________________
> IMPORTANT NOTICE:
>
> This mailing list is shutting down. Please subscribe to the Apache Wicket
> user list. Send a message to: "users-subscribe at wicket.apache.org" and
> follow the instructions.
> _______________________________________________
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
IMPORTANT NOTICE:

This mailing list is shutting down. Please subscribe to the Apache Wicket user list. Send a message to: "users-subscribe at wicket.apache.org" and follow the instructions.
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

 « Return to Thread: Updates within Panels in datatable