Why don't you have your backingBean also have a handle to some kind of
Session based object that has the userRoles etc. Then when you call
backingBean.render() , render could then just check what it needs from
that bean?

On 9/9/05, Dave <[EMAIL PROTECTED]> wrote:
> Hello, 
> In a page, I need to render a UICompont based on user and his/her roles. 
> For example, 
>   <h:commandLink value="Edit" action="Edit" rendered="#{backingBean.render}"
> /> 
>   
> In the backingBean boolean render() method, user/roles can be obtained from
> request. But it needs to know the command id or name to figure out(based on
> authorization policy) if the user is allowed to perform the action. If not,
> the commandLink should not be rendered. 
>   
> The backing bean method is not allowed to pass parameters. It is not ideal
> for each command to have one backing bean method such as boolean
> renderEdit(). 
>   
> What is the way to accomplish this? Thanks for ideas!  Dave
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam? Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 


-- 
Rick

Reply via email to