I would like to integrate a p:commandLink to execute an action in my bean.
It look currently like this
So for the following icon:
<i class="fa fa-dot-circle-o Fright" aria-hidden="true"></i> <br></br>
I need now a p:commandLink....
If i add here p:commandLink, than I got a second line with two different hovers elements and it´s now one anymore...
Here my current code:
Code: Select all
<p:commandLink id="notificationLink" global="false">
<i class="topbar-icon fa fa-fw fa-bell-o"></i>
<h:outputText id="notificationTopbar"
value="#{numberOfUnreadNotificationByEmployeeNotLazyController.numberOf}"
rendered="#{numberOfUnreadNotificationByEmployeeNotLazyController.numberOf != 0}"
styleClass="topbar-badge animated rubberBand" />
<h:outputText value="Benachrichtungen"
styleClass="topbar-item-name" />
</p:commandLink> <p:tooltip for="notificationLink" value="Benachrichtungen"
position="bottom" />
<ul class="animated">
<li role="menuitem"><a href="#" class="topbar-message"> <h:outputText
styleClass="shorten-long-text"
value="Keine Benachrichtungen vorhanden"
rendered="#{numberOfUnreadNotificationByEmployeeNotLazyController.numberOf == 0}" />
</a></li>
</ul>
<ul class="animated">
<p:repeat
value="#{notificationRequestLast10EntriesNotLazyController.notificationList}"
rendered="#{notificationRequestLast10EntriesNotLazyController.notificationList != null}"
var="notification">
<li role="menuitem" style="#{notification.readPortalNotification == false ? 'background-color: #dff0d8;' : 'background-color: #ffffff;'}"><a
href="#{generateTextNotLazyController.generateLink(notification)}">
<h:outputText escape="false"
value="#{generateTextNotLazyController.generateString(notification)}" />
<i class="fa fa-dot-circle-o Fright" aria-hidden="true"></i> <br></br>
<h:outputText id="notificationTime" style="margin-left: 29px;"
styleClass="Fs6" value="#{notification.createDate}">
<f:converter converterId="prettyTimeCustomConverter" />
</h:outputText> <p:tooltip for="notificationTime" position="bottom"
value="#{notification.createDate}" />
</a></li>
</p:repeat>
<h:panelGroup styleClass="TexAlCenter">
<p:commandLink >
<i class="fa fa-caret-square-o-right" aria-hidden="true" style="margin-left: 5px;"></i>
<h:outputText value="Alle Benachrichtungen anzeigen" />
</p:commandLink>
</h:panelGroup>
</ul></li>
2) I need also about the whole panel (like this):
a link. So this mean: as soon someone pressed on the whole panel, I would like to execute a function in my bean, which modify the notifcation and set to "read"....<li role="menuitem" style="#{notification.readPortalNotification == false ? 'background-color: #dff0d8;' : 'background-color: #ffffff;'}"><a
href="#{generateTextNotLazyController.generateLink(notification)}">
How can I do this?
Many thanks