0

Good Day Everybody,

I am developing a web application, using JSF and primefaces, in one of my views I have a primefaces element which is a Slide Menu with Menu Items like this.

<p:slideMenu style="width:140px">
<p:menuitem value="My products" url="products.xhtml"/>
<p:menuitem value="products" url="home.xhtml"/> 
<p:menuitem value="Delete Users" action="#{menuView.delete}"/>
<p:menuitem value="Sale" url="save.xhtml" />
<p:menuitem value="Log Out" action="#{login.logout()}"/>
 </p:slideMenu>

I have a derby DB with some users on it, I'm not trying to create Roles or something, I just would like to know if there's a way I can block/gray out the menu item "Delete Users" to the rest of users except the user admin in my db.

Thanks in Advance.

Kukeltje
  • 12,223
  • 4
  • 24
  • 47

0 Answers0