Problem in dataexporter header with facet

UI Components for JSF
Post Reply
jbbjunior
Posts: 12
Joined: 12 Apr 2013, 13:26
Location: Brasil
Contact:

08 Aug 2016, 21:09

I have problems in dataexporter PDF

when header facet use in component dataExporter in datatable

The header appears javax.faces.component.UIPanel instead of appearing "Severity"

This happens only when we have something more than the tag outputText inside facet header

You can fix this in the next version?

Code: Select all

<p:dataTable id="DataTableId" widgetVar="tableId" rowKey="#{alert.entity}" var="alert" filterMap="#{alertMBean.filterMap}"
	value="#{alertMBean.lazyModel}" paginator="true"	lazy="true"
	paginatorTemplate="{ExportersFile} {CurrentPageReport}  {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
	selectionMode="multiple" selection="#{alertMBean.selectedAlerts}"
	paginatorPosition="top" rowsPerPageTemplate="15,50,100,250,500"
	first="#{alertMBean.currentPage}"  
	rows="#{alertMBean.rows}">
	
	<f:facet name="{ExportersFile}">

		<h:commandLink styleClass="linkExportaGrid" title="#{res.button_export_PDF}">
				<img src="#{dashMBean.getCurrentContext()}/image/icone_PDF.png" width="24" />
				<p:dataExporter type="pdf" target="DataTableId" fileName="#{res.form_alerts}" pageOnly="true" />
		</h:commandLink>
	</f:facet>		

	<p:column>
		<f:facet name="header">
			<h:outputText value="Severity"/>
			<br />
			<p:commandButton id="showSeverityDlgBt" 
				 update=":severitySelectionForm" 
				 oncomplete="PF('severitySelectionDlg').show();" icon="ui-icon-search" />
					 
		</f:facet>
		<h:outputText value="#{alert.severityStr}" />
	</p:column>
</p:dataTable>
[/ Code]
--
João B. Branquinho Júnior
Server: JBOSS WildFly 9.0
JSF: Mojarra 2.2.1
PF version: PrimeFaces 8.0
Browser: 51.0.2704.106 m (64-bit)

ez2cwhy
Posts: 5
Joined: 24 Oct 2011, 12:56

24 Aug 2016, 03:32

I have encountered this same issue. I am attempting to use font awesome filter icon to show a column is filtered, but this causes issues when exporting, as the tag is picked up as the column header.
PrimeFaces 3.0.M3, Apache MyFaces 2.1.3, Tomcat 7, Windows XP, Eclipse Indigo

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 32 guests