"markfoerstein" wrote : "toni" wrote : How can I render parts of the page depending on the user role with this kind of security setup? | | | | I would like to hide or show menu items depending on whether or not the user belongs to a certain rule. | | Same here toni ;-)
Easy: <h:commandButton value="Self Destruct" action="#{machine.selfDestruct}" rendered="#{s:hasPermission('machine','selfDestruct',machine)}"/> (Using 1.1.5, of course.) If you don't have instance-level security, the following simpler form will suffice: <h:commandButton value="Self Destruct" action="#{machine.selfDestruct}" rendered="#{s:hasPermission('machine','selfDestruct')}"/> And if all you have is role-based security, the following is even simpler: <h:commandButton value="Self Destruct" action="#{machine.selfDestruct}" rendered="#{s:hasRole('hero')}"/> View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4009171#4009171 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4009171 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user