menu.xhtml
1.39 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<rich:toolBar
xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:s="http://jboss.com/products/seam/taglib"
xmlns:rich="http://richfaces.org/rich">
<rich:toolBarGroup>
<h:outputText value="#{projectName}:"/>
<s:link
id="menuHomeId"
view="/home.xhtml"
value="Home"
propagation="none"/>
</rich:toolBarGroup>
<!-- @newMenuItem@ -->
<s:link view="/view/example/MovieList.xhtml"
value="Movie List"
includePageParams="false"
propagation="none"/>
<rich:toolBarGroup location="right">
<ui:remove>
<!-- temporarily disabled for all -->
<s:link
id="identityManagement"
view="/useradmin"
value="Identity Management"
propagation="none"
rendered="#{identity.hasRole('admin')}"/>
</ui:remove>
<h:outputText
id="menuWelcomeId"
value="signed in as: #{credentials.username}"
rendered="#{identity.loggedIn}"/>
<s:link
id="menuLoginId"
view="/login.xhtml"
value="Login"
rendered="#{not identity.loggedIn}"
propagation="none"/>
<s:link
id="menuLogoutId"
view="/home.xhtml"
action="#{identity.logout}"
value="Logout"
rendered="#{identity.loggedIn}"
propagation="none"/>
</rich:toolBarGroup>
</rich:toolBar>