<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="inf_liquidacion_cesantia" language="groovy" pageWidth="860" pageHeight="612" orientation="Landscape" columnWidth="820" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
	<property name="ireport.zoom" value="1.996500000000001"/>
	<property name="ireport.x" value="275"/>
	<property name="ireport.y" value="0"/>
	<parameter name="whereFuncionarioNumDoc" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereFuncionarioTipoDoc" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="id_periodo_filtro" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="id_periodo" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="whereClasePlanta" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="comando" class="java.lang.String"/>
	<queryString>
		<![CDATA[select distinct
dep.coddepto || ' ' || mun.codmun_text as depmun,
dep.coddepto as coddep,
mun.codmun_text as codmun,
tab0.*,
tipdoc.descripcion,
tipdoc.abreviacion,
ter.primer_nombre || ' ' || ter.segundo_nombre as nombre,
ter.primer_apellido,
ter.segundo_apellido,
(select distinct periodo.periodo from no_liquida_v periodo where periodo.id_periodo = tab0.id_periodo) AS PERIODO,
(select distinct periodo.tipper from no_liquida_v periodo where periodo.id_periodo = tab0.id_periodo) AS TIPPER,
per.id_anhos || lpad(per.id_meses,2,'0') as periodo_mes,
nvl(dp.asignacion_basica,0) as asignacion_basica,
(case when tab0.fecha_termina is null then 1 else 0 end) as activo
from (select no_cesantia.*,NO_NOMBRAMIENTO_V.id_clase_planta
from no_cesantia
JOIN NO_NOMBRAMIENTO_V
on no_cesantia.id_tipo_doc = NO_NOMBRAMIENTO_V.id_tipo_doc
and no_cesantia.num_doc = NO_NOMBRAMIENTO_V.num_doc)tab0

join tipo_documento  tipdoc
on tipdoc.id_tipo_doc = tab0.id_tipo_doc

join no_datos_funcionario_v ter
on ter.id_tipo_doc = tab0.id_tipo_doc
and ter.num_doc = tab0.num_doc

join no_periodo per
on tab0.id_periodo = per.id_periodo

left join no_liquida_v liq
on liq.id_tipo_doc = tab0.id_tipo_doc
and liq.num_doc = tab0.num_doc
and liq.id_periodo = tab0.id_periodo

left join (
  SELECT
   aut.*,
   ROW_NUMBER() OVER (
    partition by aut.num_doc
    ORDER BY aut.actual desc
   ) AS rn
  from no_estado_func aut
  where aut.periodo = $P{id_periodo_filtro}
)estfun
on estfun.id_tipo_doc = tab0.id_tipo_doc
and estfun.num_doc = tab0.num_doc
and estfun.periodo = tab0.id_periodo
and estfun.rn = 1
/*
left join no_estado_func estfun
on estfun.id_tipo_doc = tab0.id_tipo_doc
and estfun.num_doc = tab0.num_doc
and estfun.periodo = tab0.id_periodo
--and estfun.actual = 1
*/

left join no_nombramiento nombra
on estfun.id_tipo_doc = nombra.id_tipo_doc
and estfun.num_doc = nombra.num_doc

left join no_dp_v dp
on estfun.id_dp = dp.id_dp

left join centro_operacion cenop
on estfun.id_cen_op = cenop.id_cen_op

left join departamento dep
on dep.id_depto = cenop.id_depto

left join municipios mun
on mun.codmun = cenop.codmun

where tab0.id_periodo = $P{id_periodo_filtro}
$P!{whereFuncionarioNumDoc} $P!{whereFuncionarioTipoDoc} $P!{whereClasePlanta}
and tab0.consolidado = 0
and ( estfun.actual = 1

    or (nombra.estado = 1 or
      ( nombra.estado = 0
        and nombra.fecha_retiro
      between to_date('01/'|| (select lpad(id_meses,2,'0') ||'/'||id_anhos from no_periodo where id_periodo = $P{id_periodo_filtro}) ,'dd/mm/yyyy')
      and trunc(last_day( TO_DATE('01/'|| (SELECT LPAD(ID_MESES,2,'0') ||'/'||ID_ANHOS FROM NO_PERIODO WHERE ID_PERIODO = $P{id_periodo}) ,'dd/mm/yyyy')  )+1)
      )
    )

)

order by
tab0.id_periodo,
tab0.id_tipo_doc,
tab0.num_doc]]>
	</queryString>
	<field name="DEPMUN" class="java.lang.String"/>
	<field name="CODDEP" class="java.lang.String"/>
	<field name="CODMUN" class="java.lang.String"/>
	<field name="ID_CESANTIA" class="java.math.BigDecimal"/>
	<field name="ID_PERIODO" class="java.math.BigDecimal"/>
	<field name="ID_TIPO_DOC" class="java.math.BigDecimal"/>
	<field name="NUM_DOC" class="java.lang.String"/>
	<field name="ID_CONCEP_NOMINA" class="java.math.BigDecimal"/>
	<field name="VALOR_LIQUIDADO" class="java.math.BigDecimal"/>
	<field name="NUM_DIAS" class="java.math.BigDecimal"/>
	<field name="FECHA_INGRESO" class="java.sql.Timestamp"/>
	<field name="FECHA_TERMINA" class="java.sql.Timestamp"/>
	<field name="VALOR_BASE" class="java.math.BigDecimal"/>
	<field name="VALOR_CONSOLIDADO" class="java.math.BigDecimal"/>
	<field name="VALOR_APLICADO" class="java.math.BigDecimal"/>
	<field name="VALOR_AJUSTE" class="java.math.BigDecimal"/>
	<field name="CONSOLIDADO" class="java.math.BigDecimal"/>
	<field name="ID_CLASE_PLANTA" class="java.math.BigDecimal"/>
	<field name="DESCRIPCION" class="java.lang.String"/>
	<field name="ABREVIACION" class="java.lang.String"/>
	<field name="NOMBRE" class="java.lang.String"/>
	<field name="PRIMER_APELLIDO" class="java.lang.String"/>
	<field name="SEGUNDO_APELLIDO" class="java.lang.String"/>
	<field name="PERIODO" class="java.lang.String"/>
	<field name="TIPPER" class="java.lang.String"/>
	<field name="PERIODO_MES" class="java.lang.String"/>
	<field name="ASIGNACION_BASICA" class="java.math.BigDecimal"/>
	<field name="ACTIVO" class="java.math.BigDecimal"/>
	<variable name="total_valor_liq" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR_LIQUIDADO}]]></variableExpression>
	</variable>
	<variable name="total_func" class="java.math.BigDecimal" calculation="Count">
		<variableExpression><![CDATA[$F{NUM_DOC}]]></variableExpression>
	</variable>
	<variable name="total_valor_ajuste" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR_AJUSTE}]]></variableExpression>
	</variable>
	<variable name="total_func_act" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO} == 1 ? 1 : 0 )]]></variableExpression>
	</variable>
	<variable name="total_func_ret" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO} != 1 ? 1 : 0 )]]></variableExpression>
	</variable>
	<variable name="total_valor_liq_act" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO}== 1 ? $F{VALOR_LIQUIDADO} : 0 )]]></variableExpression>
	</variable>
	<variable name="total_valor_ajuste_act" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO} == 1 ? $F{VALOR_AJUSTE} : 0 )]]></variableExpression>
	</variable>
	<variable name="total_valor_ajuste_ret" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO} != 1 ? $F{VALOR_AJUSTE} : 0 )]]></variableExpression>
	</variable>
	<variable name="total_valor_liq_ret" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO} != 1 ? $F{VALOR_LIQUIDADO} : 0 )]]></variableExpression>
	</variable>
	<variable name="total_base_liq" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR_BASE}]]></variableExpression>
	</variable>
	<variable name="total_base_liq_act" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO}== 1 ? $F{VALOR_BASE} : 0 )]]></variableExpression>
	</variable>
	<variable name="total_base_liq_ret" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[( $F{ACTIVO} != 1 ? $F{VALOR_BASE} : 0 )]]></variableExpression>
	</variable>
	<background>
		<band splitType="Stretch"/>
	</background>
	<title>
		<band height="60" splitType="Stretch">
			<staticText>
				<reportElement x="165" y="0" width="445" height="40"/>
				<textElement textAlignment="Center" verticalAlignment="Bottom" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<text><![CDATA[Sistema General de Nómina
Informe Liquidación de Cesantías]]></text>
			</staticText>
			<image>
				<reportElement x="0" y="10" width="140" height="40"/>
				<imageExpression class="java.lang.String"><![CDATA["repo:LogoEmpresa003.jpg"]]></imageExpression>
			</image>
			<staticText>
				<reportElement mode="Opaque" x="610" y="28" width="210" height="12" forecolor="#000000" backcolor="#FFFFFF"/>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Fecha de Impresión:]]></text>
			</staticText>
			<textField pattern="dd-MMM-yyyy   hh:mm aaa">
				<reportElement x="610" y="40" width="210" height="12"/>
				<box rightPadding="3"/>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="8"/>
				</textElement>
				<textFieldExpression class="java.util.Date"><![CDATA[new java.util.Date()]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="165" y="40" width="445" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{TIPPER}+" "+$F{PERIODO}]]></textFieldExpression>
			</textField>
		</band>
	</title>
	<pageHeader>
		<band height="20" splitType="Stretch"/>
	</pageHeader>
	<columnHeader>
		<band height="16" splitType="Stretch">
			<staticText>
				<reportElement mode="Opaque" x="0" y="0" width="60" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Documento]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="60" y="0" width="30" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[TD]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="90" y="0" width="75" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Primer Apellido]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="165" y="0" width="85" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Segundo Apellido]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="250" y="0" width="100" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Nombre]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="545" y="0" width="65" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Valor Aporte]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="715" y="0" width="55" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Retiro]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="660" y="0" width="55" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Ingreso]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="610" y="0" width="50" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Periodo]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="407" y="0" width="70" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Salario]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="350" y="0" width="57" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Dep Mun]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="770" y="0" width="50" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Vlr. Ajuste]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="477" y="0" width="68" height="16" forecolor="#000000" backcolor="#88C2F9"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Valor Base]]></text>
			</staticText>
		</band>
	</columnHeader>
	<detail>
		<band height="12" splitType="Stretch">
			<textField>
				<reportElement x="0" y="0" width="60" height="12"/>
				<box rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{NUM_DOC}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="60" y="0" width="30" height="12"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{ABREVIACION}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="90" y="0" width="75" height="12"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{PRIMER_APELLIDO}]]></textFieldExpression>
			</textField>
			<textField isBlankWhenNull="true">
				<reportElement x="165" y="0" width="85" height="12"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{SEGUNDO_APELLIDO}]]></textFieldExpression>
			</textField>
			<textField isBlankWhenNull="true">
				<reportElement x="250" y="0" width="100" height="12"/>
				<box leftPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{NOMBRE}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)">
				<reportElement x="545" y="0" width="65" height="12"/>
				<box rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOR_LIQUIDADO}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement x="610" y="0" width="50" height="12"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{PERIODO_MES}]]></textFieldExpression>
			</textField>
			<textField pattern="dd/MM/yyyy" isBlankWhenNull="true">
				<reportElement x="660" y="0" width="55" height="12"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.sql.Timestamp"><![CDATA[$F{FECHA_INGRESO}]]></textFieldExpression>
			</textField>
			<textField pattern="dd/MM/yyyy" isBlankWhenNull="true">
				<reportElement x="715" y="0" width="55" height="12"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.sql.Timestamp"><![CDATA[$F{FECHA_TERMINA}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)">
				<reportElement x="407" y="0" width="70" height="12"/>
				<box rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{ASIGNACION_BASICA}]]></textFieldExpression>
			</textField>
			<textField isBlankWhenNull="true">
				<reportElement x="350" y="0" width="57" height="12"/>
				<box>
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{DEPMUN}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00">
				<reportElement x="770" y="0" width="50" height="12"/>
				<box rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOR_AJUSTE}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)">
				<reportElement x="477" y="0" width="68" height="12"/>
				<box rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOR_BASE}]]></textFieldExpression>
			</textField>
		</band>
	</detail>
	<columnFooter>
		<band height="10" splitType="Stretch"/>
	</columnFooter>
	<pageFooter>
		<band height="24" splitType="Stretch">
			<textField>
				<reportElement mode="Opaque" x="299" y="12" width="89" height="12" forecolor="#575757" backcolor="#FFFFFF"/>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="6" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["Página "+$V{PAGE_NUMBER}+" de "]]></textFieldExpression>
			</textField>
			<textField evaluationTime="Report" pattern="" isBlankWhenNull="false">
				<reportElement mode="Opaque" x="389" y="12" width="60" height="12" forecolor="#575757" backcolor="#FFFFFF"/>
				<textElement verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="6" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="299" y="0" width="150" height="12" forecolor="#575757"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<text><![CDATA[Websafi - Nómina]]></text>
			</staticText>
		</band>
	</pageFooter>
	<summary>
		<band height="140" splitType="Stretch">
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="545" y="0" width="65" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_liq}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="610" y="0" width="160" height="12" backcolor="#BCBABA"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.0"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="8" isBold="true"/>
				</textElement>
				<text><![CDATA[]]></text>
			</staticText>
			<textField pattern="###0">
				<reportElement mode="Opaque" x="90" y="0" width="387" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="3" rightPadding="0">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_func}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="0" y="0" width="90" height="12" backcolor="#BCBABA"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.0"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="7" isBold="true"/>
				</textElement>
				<text><![CDATA[Total Funcionarios]]></text>
			</staticText>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="770" y="0" width="50" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_ajuste}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="545" y="36" width="65" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_liq_act}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="610" y="36" width="160" height="12" backcolor="#D2C8C8"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.0"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="8" isBold="true"/>
				</textElement>
				<text><![CDATA[]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="0" y="36" width="90" height="12" backcolor="#D2C8C8"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.0"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="7" isBold="true"/>
				</textElement>
				<text><![CDATA[Func. Activos]]></text>
			</staticText>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="770" y="36" width="50" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_ajuste_act}]]></textFieldExpression>
			</textField>
			<textField pattern="###0">
				<reportElement mode="Opaque" x="90" y="36" width="387" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="3" rightPadding="0">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_func_act}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="545" y="48" width="65" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_liq_ret}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="610" y="48" width="160" height="12" backcolor="#D2C8C8"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.0"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="8" isBold="true"/>
				</textElement>
				<text><![CDATA[]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="0" y="48" width="90" height="12" backcolor="#D2C8C8"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.0"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="7" isBold="true"/>
				</textElement>
				<text><![CDATA[Func. Retirados]]></text>
			</staticText>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="770" y="48" width="50" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_ajuste_ret}]]></textFieldExpression>
			</textField>
			<textField pattern="###0">
				<reportElement mode="Opaque" x="90" y="48" width="387" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="3" rightPadding="0">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_func_ret}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="545" y="60" width="275" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_valor_liq} + $V{total_valor_ajuste}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="0" y="60" width="545" height="12" backcolor="#D2C8C8"/>
				<box leftPadding="3">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.0"/>
				</box>
				<textElement verticalAlignment="Middle">
					<font size="7" isBold="true"/>
				</textElement>
				<text><![CDATA[Valor Neto]]></text>
			</staticText>
			<subreport>
				<reportElement stretchType="RelativeToBandHeight" x="0" y="95" width="350" height="45" isRemoveLineWhenBlank="true"/>
				<subreportParameter name="comando">
					<subreportParameterExpression><![CDATA[$P{comando}]]></subreportParameterExpression>
				</subreportParameter>
				<connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression>
				<subreportExpression class="java.lang.String"><![CDATA["repo:firma_simple_izq"]]></subreportExpression>
			</subreport>
			<subreport>
				<reportElement stretchType="RelativeToBandHeight" x="470" y="95" width="350" height="45" isRemoveLineWhenBlank="true"/>
				<subreportParameter name="comando">
					<subreportParameterExpression><![CDATA[$P{comando}]]></subreportParameterExpression>
				</subreportParameter>
				<connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression>
				<subreportExpression class="java.lang.String"><![CDATA["repo:firma_simple_der"]]></subreportExpression>
			</subreport>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="477" y="0" width="68" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_base_liq}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="477" y="36" width="68" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_base_liq_act}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;-#,##0.00">
				<reportElement mode="Opaque" x="477" y="48" width="68" height="12" forecolor="#000000" backcolor="#D2C8C8"/>
				<box leftPadding="0" rightPadding="2">
					<pen lineWidth="0.75"/>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{total_base_liq_ret}]]></textFieldExpression>
			</textField>
		</band>
	</summary>
	<noData>
		<band height="20">
			<staticText>
				<reportElement x="0" y="0" width="820" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font isBold="true"/>
				</textElement>
				<text><![CDATA[No hay objetos a mostrar.]]></text>
			</staticText>
		</band>
	</noData>
</jasperReport>
