This content has been marked as final.
Show 1 reply
-
1. Re: Binding action method to programically created component doesn't work
piotr.sobczyk Feb 13, 2010 1:13 PM (in response to piotr.sobczyk)Allright, I solved it!
My custom component was lacking overriden decode method that generates event. I make my component extending UIComand (and in that way getting access to protected queueEvent method) and added such code:
@Override public void decode(FacesContext ctx){ ExternalContext external = ctx.getExternalContext(); Map requestParams = external.getRequestParameterMap(); String clientId = link.getClientId(ctx); if(requestParams.containsKey(clientId)){ queueEvent(new ActionEvent(link)); } }
Maybe it will help someone with similar problem.