This content has been marked as final.
Show 2 replies
-
1. Re: a4j:commandButton oncomplete
liuliu Aug 1, 2008 6:22 AM (in response to tomsimmons)
use something like "if (data) showModel" in oncompete. -
2. Re: a4j:commandButton oncomplete
tomsimmons Aug 6, 2008 4:05 AM (in response to tomsimmons)"liuliu" wrote:
use something like "if (data) showModel" in oncompete.
Thank you, worked a treat.
For other folks reference:
I added a boolean in the backing bean (easier than mucking around with making the entire custom object JSON able), added the getter and setters for it in the backing bean.
In the JSP, added
data = "#{backingbean.boolean}"
to the a4j:commandButton attributes. Obviously needs to be your backing bean name and the accessor to your boolean. In the oncomplete modified it to
oncomplete = "if (data) javascript:Richfaces.showModalPanel(.....{....});"
Tom