@ManagedBean(name = "notificationBean")
@RequestScoped
public class NotificationBean {
private Notification selected = new Notification();
private List<Notification> list = null;
private List<Notification> list2 = null;
public List<Notification> getList() {
if (this.list == null) {
ContextoBean contextoBean = ContextoUtil.getContextoBean();
NotificationRN notificationRN = new NotificationRN();
this.list = notificationRN.list(contextoBean.getLoggedUser());
}
return this.list;
}
public List<Notification> getList2() {
if (this.list2 == null) {
ContextoBean contextoBean = ContextoUtil.getContextoBean();
NotificationRN notificationRN = new NotificationRN();
this.list2 = notificationRN.list2(contextoBean.getLoggedUser().getIduser());
}
return this.list2;
}
<p:dataTable var="notification" value="#{notificationBean.list2}">
<c:facet name="header">Listing notification</c:facet>
<p:column>
<c:facet name="header">
<h:outputText value="Notification" />
</c:facet>
<h:outputText value="#{notification.codNotification}" />
</p:column>
</p:dataTable>
<p:dataTable id="dataTable" var="notification"
value="#{notificationBean.list}">
<c:facet name="header">Listing notification</c:facet>
<p:column>
<c:facet name="header">
<h:outputText value="Notification" />
</c:facet>
<h:outputText value="#{notification.codNotification}" />
</p:column>
SEVERE: Servlet.service() for servlet Faces Servlet threw exception javax.el.PropertyNotFoundException: /restrict/restrictednotifyfinish.xhtml @122,72 value="#{notificationBean.list2}": Property 'list2' not found on type hpdd.web.NotificationBean at com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:111)...Alguém sabe o porquê desse erro? Agradeço qualquer ajuda desde já. =)