从primefaces dataTable创建复合组件时出现以下错误.我究竟做错了什么 !?
Exception
javax.faces.view.facelets.TagException: /view/restrito/basico/municipio.xhtml @77,165 <p:ajax> Composite component does not support event rowSelect
Run Code Online (Sandbox Code Playgroud)
tabela-padrao.xhtml
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:cc="http://xmlns.jcp.org/jsf/composite"
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:p="http://primefaces.org/ui"
xmlns:f="http://xmlns.jcp.org/jsf/core"
xmlns:h="http://xmlns.jcp.org/jsf/html">
<!-- INTERFACE -->
<cc:interface>
<cc:attribute name="uniqueId" required="true" />
<cc:attribute name="value" required="true" />
<cc:attribute name="var" required="true" />
<cc:attribute name="selection" required="true" />
<cc:attribute name="exportedFileName" required="true" />
<cc:attribute name="renderedTable" default="true"/>
<cc:attribute name="primaryKey" required="true"/>
</cc:interface>
<!-- IMPLEMENTATION -->
<cc:implementation>
<p:dataTable value="#{cc.attrs.value}"
id="#{cc.attrs.uniqueId}"
scrollable="true"
scrollWidth="100%"
var="#{cc.attrs.var}"
rendered="#{cc.attrs.renderedTable}"
selection="#{cc.attrs.selection}"
rowKey="#{cc.attrs.primaryKey}"
selectionMode="single"
paginator="true"
rowsPerPageTemplate="15,30,45"
paginatorTemplate="{CurrentPageReport} {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown} {Exporters}"
emptyMessage="#{bundle.tabela_nenhum_registro_encontrado}">
<cc:insertChildren/> …Run Code Online (Sandbox Code Playgroud)