Hi,
If you have a WebmarkupContainer (or whatever grouping component) that holds all
components of your cart, you can put a public/protected method
updateCart(AjaxRequestTarget target)
on your base page. When you click on AjaxLink on child page, you can
call that method. Same applies for any other ajax callback method that gets
AjaxRequestTarget
(for example in AjaxButton, AjaxSelfUpdatingBehavior etc...)
for example:
onClick(final AjaxRequestTarget target){
// do your stuff in here
updateCart(target)
}
in your updateCart method you then do:
protected void updateCart(AjaxrequestTarget target){
target.addComponent(cart);
}
- Mikko
-----Original Message-----
From: HHB [mailto:[email protected]]
Sent: 14. joulukuuta 2008 11:10
To: [email protected]
Subject: How to update base page panel from child page?
Hey,
I use inheritance to do layout.
The base page containing main section that should contains child's markup,
and cart section.
Child pages are supposed to perform operations that will update the cart
section (lets say via Ajax).
My question is how to ask the cart section to updates its state (and redraw
it) from a child page?
I'm new to Wicket so forgive my questions :)
Thanks for your time.
--
View this message in context:
http://www.nabble.com/How-to-update-base-page-panel-from-child-page--tp20998486p20998486.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]