Source

habisoft / jrxml / FichaCadastro_pg2.jrxml

Full commit
<?xml version="1.0" encoding="UTF-8"  ?>
<!-- Created with iReport - A designer for JasperReports -->
<!DOCTYPE jasperReport PUBLIC "//JasperReports//DTD Report Design//EN" "http://jasperreports.sourceforge.net/dtds/jasperreport.dtd">
<jasperReport
		 name="FichaCadastro_pg2"
		 columnCount="1"
		 printOrder="Vertical"
		 orientation="Portrait"
		 pageWidth="595"
		 pageHeight="842"
		 columnWidth="535"
		 columnSpacing="0"
		 leftMargin="30"
		 rightMargin="30"
		 topMargin="20"
		 bottomMargin="20"
		 whenNoDataType="NoPages"
		 isTitleNewPage="false"
		 isSummaryNewPage="false">
	<property name="ireport.scriptlethandling" value="0" />
	<property name="ireport.encoding" value="UTF-8" />
	<import value="java.util.*" />
	<import value="net.sf.jasperreports.engine.*" />
	<import value="net.sf.jasperreports.engine.data.*" />

	<parameter name="SUBREPORT_DIR" isForPrompting="false" class="java.lang.String"/>
	<parameter name="LOGO" isForPrompting="false" class="java.awt.Image"/>
	<parameter name="DATA_HOJE" isForPrompting="false" class="java.util.Date">
		<defaultValueExpression ><![CDATA[new java.util.Date()]]></defaultValueExpression>
	</parameter>
	<parameter name="MEMBROS_DEFICIENTES" isForPrompting="false" class="java.lang.Object"/>
	<parameter name="TRATAMENTOS_MEMBROS" isForPrompting="false" class="java.lang.Object"/>

	<field name="nome" class="java.lang.String"/>
	<field name="laudoAssistente" class="java.lang.String"/>
	<field name="beneficioPretendido" class="java.lang.String"/>
	<field name="status.nome" class="java.lang.String"/>
	<field name="familia.informacoesDeSaude.informacoesAdicionais" class="java.lang.String"/>
	<field name="terreno" class="java.lang.Boolean"/>

		<background>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</background>
		<title>
			<band height="100"  isSplitAllowed="true" >
				<image  scaleImage="RetainShape" vAlign="Middle" hAlign="Center" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="141"
						height="99"
						key="image-1"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<graphicElement stretchType="NoStretch"/>
					<imageExpression class="java.awt.Image"><![CDATA[$P{LOGO}]]></imageExpression>
				</image>
				<staticText>
					<reportElement
						x="149"
						y="5"
						width="376"
						height="40"
						key="staticText-1"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" size="16" isBold="true"/>
					</textElement>
				<text><![CDATA[Prefeitura Municipal de Presidente Kennedy
Secretaria Municipal de Habitação]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="155"
						y="55"
						width="376"
						height="40"
						key="staticText-2"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<textElement textAlignment="Center">
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" size="16" isBold="true"/>
					</textElement>
				<text><![CDATA[Ficha de Cadastro]]></text>
				</staticText>
			</band>
		</title>
		<pageHeader>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</pageHeader>
		<columnHeader>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</columnHeader>
		<detail>
			<band height="600"  isSplitAllowed="true" >
				<staticText>
					<reportElement
						mode="Opaque"
						x="0"
						y="264"
						width="534"
						height="18"
						backcolor="#EEEEEE"
						key="staticText-3"/>
					<box leftPadding="1" rightPadding="1" topPadding="1" bottomPadding="1">					<pen lineWidth="0.0" lineColor="#000000"/>
					<topPen lineWidth="0.0" lineColor="#000000"/>
					<leftPen lineWidth="0.0" lineColor="#000000"/>
					<bottomPen lineWidth="0.0" lineColor="#000000"/>
					<rightPen lineWidth="0.0" lineColor="#000000"/>
</box>
					<textElement textAlignment="Center">
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Declaração do Requerente]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="0"
						y="285"
						width="534"
						height="15"
						key="staticText-4"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma"/>
					</textElement>
				<text><![CDATA[Declaro serem verdadeiras as informações acima expostas, estando ciente das penalidades.]]></text>
				</staticText>
				<line direction="TopDown">
					<reportElement
						x="110"
						y="330"
						width="317"
						height="0"
						key="line-1"/>
					<graphicElement stretchType="NoStretch"/>
				</line>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="332"
						width="533"
						height="14"
						key="textField-1"/>
					<box></box>
					<textElement textAlignment="Center">
						<font fontName="Tahoma"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{nome}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="-1"
						y="345"
						width="533"
						height="14"
						key="textField-2"/>
					<box></box>
					<textElement textAlignment="Center">
						<font fontName="Tahoma"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Presidente Kennedy, ES. " + new java.text.SimpleDateFormat("dd/MM/yyyy").format($P{DATA_HOJE})]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						mode="Opaque"
						x="0"
						y="366"
						width="534"
						height="18"
						backcolor="#EEEEEE"
						key="staticText-5"/>
					<box leftPadding="1" rightPadding="1" topPadding="1" bottomPadding="1">					<pen lineWidth="0.0" lineColor="#000000"/>
					<topPen lineWidth="0.0" lineColor="#000000"/>
					<leftPen lineWidth="0.0" lineColor="#000000"/>
					<bottomPen lineWidth="0.0" lineColor="#000000"/>
					<rightPen lineWidth="0.0" lineColor="#000000"/>
</box>
					<textElement textAlignment="Center">
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Laudo da Assistente Social]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="390"
						width="533"
						height="160"
						key="textField-3"
						isRemoveLineWhenBlank="true"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{laudoAssistente}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						x="2"
						y="570"
						width="59"
						height="17"
						key="staticText-6"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<text><![CDATA[Pretensão:]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="280"
						y="570"
						width="51"
						height="17"
						key="staticText-7"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<text><![CDATA[Situação:]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="60"
						y="570"
						width="219"
						height="17"
						key="textField-4"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[($F{beneficioPretendido}.equalsIgnoreCase("casa popular") && $F{terreno}.booleanValue()) ? "Casa popular (tem terreno)" : (($F{beneficioPretendido}.equalsIgnoreCase("casa popular") && !$F{terreno}.booleanValue()) ? "Casa popular (não tem terreno)" : $F{beneficioPretendido})]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="332"
						y="570"
						width="162"
						height="17"
						key="textField-5"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{status.nome}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						x="0"
						y="170"
						width="534"
						height="17"
						key="staticText-8"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<text><![CDATA[Informações Adicionais:]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="187"
						width="534"
						height="78"
						key="textField-6"
						isRemoveLineWhenBlank="true"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<textElement>
						<font fontName="Tahoma"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{familia.informacoesDeSaude.informacoesAdicionais}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						mode="Opaque"
						x="0"
						y="10"
						width="534"
						height="18"
						backcolor="#EEEEEE"
						key="staticText-9"
						isPrintWhenDetailOverflows="true"/>
					<box leftPadding="1" rightPadding="1" topPadding="1" bottomPadding="1">					<pen lineWidth="0.0" lineColor="#000000"/>
					<topPen lineWidth="0.0" lineColor="#000000"/>
					<leftPen lineWidth="0.0" lineColor="#000000"/>
					<bottomPen lineWidth="0.0" lineColor="#000000"/>
					<rightPen lineWidth="0.0" lineColor="#000000"/>
</box>
					<textElement textAlignment="Center">
						<font fontName="Tahoma" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Saúde da Família]]></text>
				</staticText>
				<subreport  isUsingCache="true">
					<reportElement
						x="0"
						y="32"
						width="535"
						height="40"
						key="subreport-1"
						isRemoveLineWhenBlank="true"
						isPrintWhenDetailOverflows="true"/>
					<dataSourceExpression><![CDATA[$P{MEMBROS_DEFICIENTES}]]></dataSourceExpression>
					<subreportExpression  class="java.lang.String"><![CDATA[$P{SUBREPORT_DIR} + "FichaCadastro_subreport2.jasper"]]></subreportExpression>
				</subreport>
				<subreport  isUsingCache="true">
					<reportElement
						x="1"
						y="102"
						width="533"
						height="40"
						key="subreport-2"
						isRemoveLineWhenBlank="true"
						isPrintWhenDetailOverflows="true"/>
					<dataSourceExpression><![CDATA[$P{TRATAMENTOS_MEMBROS}]]></dataSourceExpression>
					<subreportExpression  class="java.lang.String"><![CDATA[$P{SUBREPORT_DIR} + "FichaCadastro_subreport3.jasper"]]></subreportExpression>
				</subreport>
			</band>
		</detail>
		<columnFooter>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</columnFooter>
		<pageFooter>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</pageFooter>
		<summary>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</summary>
</jasperReport>