<?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_gen_emb" language="groovy" pageWidth="1300" pageHeight="612" orientation="Landscape" columnWidth="1260" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
	<property name="ireport.zoom" value="1.6105100000000045"/>
	<property name="ireport.x" value="1044"/>
	<property name="ireport.y" value="0"/>
	<parameter name="whereMinero" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="whereEstado" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="whereConSaldo" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="id_meses" class="java.math.BigDecimal">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="id_anhos" class="java.math.BigDecimal">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="last_day" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="nom_periodo" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="whereClaDesPago" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="whereTipoBeneficiario" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="whereTerceroAcreedor" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<queryString>
		<![CDATA[select tab0.* from (

select

obldethist.num_pago,
obldethist.lote_pago,
obldethist.fecha_pago,

case when ( NVL(despago.valor , 0) - NVL(obldet.valor_girar ,0) ) = 0 then 0 else 1 end as con_saldo,
NVL(despago.valor,0) - NVL(obldet.valor_girar,0) as saldo,
nvl(obldet.valor_girar,0) as valor_aplicado,
despago.ID_DES_PAGO,
despago.id_cla_despago,
despago.id_mae_ter,
despago.fecha_proc,
despago.fecha_doc,
despago.tipo_doc,
despago.numero_doc,
despago.adjunto,
despago.valor,
despago.aplica_valor,
despago.aplica_porcentaje,
despago.estado,
despago.observaciones,
despago.id_mae_ter_acree,
despago.id_tipo_beneficiario,
despago.descripcion_cla,
despago.estado_cla,
despago.aplica_suspendido,
despago.id_des_nov,
despago.id_de_nov_1,
despago.VALOR_FINAL_1,
despago.tipo_doc_1,
despago.numero_doc_1,
despago.fecha_doc_1,
despago.fecha_proc_1,
despago.observaciones_1,
despago.num_doc,
despago.razon_soc,
despago.num_doc || ' - ' || despago.razon_soc as completo_tercero,
ter.num_doc as num_doc_acree,
case when ter.razon_soc is null then ter.pnombre||' '||ter.snombre||' '||ter.papellido||' '||ter.sapellido else ter.razon_soc end as razon_soc_acree,
ter.num_doc || ' - ' || (case when ter.razon_soc IS NULL then ter.pnombre||' '||ter.snombre||' '||ter.papellido||' '||ter.sapellido else ter.razon_soc end) as completo_acree,
tipben.descripcion as descripcion_tipben,
tipben.abreviatura

from re_des_pago_ultima_nov despago

left join (

  select

  NVL(sum(det.valor_girar),0) AS valor_girar,
  det.id_des_pago

  from re_obl_detalle det

  join re_obligacion obl
  on obl.id_distribucion = det.id_distribucion
  and obl.id_obligacion = det.id_obligacion

  where det.id_des_pago is not null
  and det.estado = 1
  and obl.estado = 1
  $P!{last_day}


  group by det.id_des_pago

)obldet

on despago.id_des_pago = obldet.id_des_pago

left join (

  select

  NVL(sum(det.valor_girar),0) AS valor_girar,
  det.id_des_pago,
  wm_concat(distinct pago.num_pago) as num_pago,
  wm_concat(distinct pago.lote_pago) as lote_pago,
  wm_concat(distinct to_char(pago.fecha_pago,'dd/mm/yyyy')) as fecha_pago

  from re_obl_detalle det

  join re_obligacion obl
  on obl.id_distribucion = det.id_distribucion
  and obl.id_obligacion = det.id_obligacion

  join re_pago_hist pago
  on pago.id_distribucion = det.id_distribucion
  and pago.id_obligacion = det.id_obligacion
  and pago.secuencia = det.secuencia

  where det.id_des_pago is not null
  and det.estado = 1
  and obl.estado = 1
  and pago.estado = 1
  --$P!{last_day}
  and det.fecha_aplica <= trunc(last_day(to_date('1/2015','mm/yyyy')))


  group by det.id_des_pago

)obldethist

on despago.id_des_pago = obldethist.id_des_pago

left join re_tipo_beneficiario tipben
on tipben.id_tipo_beneficiario = despago.id_tipo_beneficiario

left join interceros ter
on ter.id_mae_ter = despago.id_mae_ter_acree


)tab0

where
1 = 1
$P!{whereMinero}
$P!{whereClaDesPago}
$P!{whereEstado}
$P!{whereConSaldo}
$P!{whereTipoBeneficiario}
$P!{whereTerceroAcreedor}

order by tab0.num_doc, tab0.fecha_proc, tab0.id_des_pago]]>
	</queryString>
	<field name="NUM_PAGO" class="java.lang.String"/>
	<field name="LOTE_PAGO" class="java.lang.String"/>
	<field name="FECHA_PAGO" class="java.lang.String"/>
	<field name="CON_SALDO" class="java.math.BigDecimal"/>
	<field name="SALDO" class="java.math.BigDecimal"/>
	<field name="VALOR_APLICADO" class="java.math.BigDecimal"/>
	<field name="ID_DES_PAGO" class="java.math.BigDecimal"/>
	<field name="ID_CLA_DESPAGO" class="java.math.BigDecimal"/>
	<field name="ID_MAE_TER" class="java.math.BigDecimal"/>
	<field name="FECHA_PROC" class="java.sql.Timestamp"/>
	<field name="FECHA_DOC" class="java.sql.Timestamp"/>
	<field name="TIPO_DOC" class="java.math.BigDecimal"/>
	<field name="NUMERO_DOC" class="java.lang.String"/>
	<field name="ADJUNTO" class="java.lang.String"/>
	<field name="VALOR" class="java.math.BigDecimal"/>
	<field name="APLICA_VALOR" class="java.math.BigDecimal"/>
	<field name="APLICA_PORCENTAJE" class="java.math.BigDecimal"/>
	<field name="ESTADO" class="java.math.BigDecimal"/>
	<field name="OBSERVACIONES" class="java.lang.String"/>
	<field name="ID_MAE_TER_ACREE" class="java.math.BigDecimal"/>
	<field name="ID_TIPO_BENEFICIARIO" class="java.math.BigDecimal"/>
	<field name="DESCRIPCION_CLA" class="java.lang.String"/>
	<field name="ESTADO_CLA" class="java.math.BigDecimal"/>
	<field name="APLICA_SUSPENDIDO" class="java.math.BigDecimal"/>
	<field name="ID_DES_NOV" class="java.math.BigDecimal"/>
	<field name="ID_DE_NOV_1" class="java.math.BigDecimal"/>
	<field name="VALOR_FINAL_1" class="java.math.BigDecimal"/>
	<field name="TIPO_DOC_1" class="java.math.BigDecimal"/>
	<field name="NUMERO_DOC_1" class="java.lang.String"/>
	<field name="FECHA_DOC_1" class="java.sql.Timestamp"/>
	<field name="FECHA_PROC_1" class="java.sql.Timestamp"/>
	<field name="OBSERVACIONES_1" class="java.lang.String"/>
	<field name="NUM_DOC" class="java.lang.String"/>
	<field name="RAZON_SOC" class="java.lang.String"/>
	<field name="COMPLETO_TERCERO" class="java.lang.String"/>
	<field name="NUM_DOC_ACREE" class="java.lang.String"/>
	<field name="RAZON_SOC_ACREE" class="java.lang.String"/>
	<field name="COMPLETO_ACREE" class="java.lang.String"/>
	<field name="DESCRIPCION_TIPBEN" class="java.lang.String"/>
	<field name="ABREVIATURA" class="java.lang.String"/>
	<variable name="sum_valor_embargo" class="java.math.BigDecimal" resetType="Group" resetGroup="Tercero" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR}]]></variableExpression>
	</variable>
	<variable name="sum_valor_aplicado" class="java.math.BigDecimal" resetType="Group" resetGroup="Tercero" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR_APLICADO}]]></variableExpression>
	</variable>
	<variable name="sum_saldo" class="java.math.BigDecimal" resetType="Group" resetGroup="Tercero" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDO}]]></variableExpression>
	</variable>
	<variable name="total_valor_embargo" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR}]]></variableExpression>
	</variable>
	<variable name="total_valor_aplicado" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{VALOR_APLICADO}]]></variableExpression>
	</variable>
	<variable name="total_saldo" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDO}]]></variableExpression>
	</variable>
	<group name="Tercero">
		<groupExpression><![CDATA[$F{ID_MAE_TER}]]></groupExpression>
		<groupHeader>
			<band height="41">
				<staticText>
					<reportElement mode="Opaque" x="0" y="0" width="95" height="12" forecolor="#000000" backcolor="#88C2F9"/>
					<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 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[Beneficiario]]></text>
				</staticText>
				<textField>
					<reportElement x="95" y="0" width="657" 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{COMPLETO_TERCERO}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement mode="Opaque" x="0" y="17" width="40" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<box leftPadding="0">
						<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[Id Emb.]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="40" y="17" width="55" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Fecha]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="160" y="17" width="60" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Doumento]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="95" y="17" width="65" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Tipo Beneficiario]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="220" y="17" width="145" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Tercero Acreedor]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="365" y="17" width="127" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Observaciones]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="492" y="17" width="75" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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 Embargo]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="567" y="17" width="75" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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 Aplicado]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="642" y="17" width="70" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Saldo]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="712" y="17" width="40" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Estado]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="752" y="17" width="60" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Doumento Novedad]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="812" y="17" width="55" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Fecha]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="867" y="17" width="193" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Observaciones]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="1060" y="17" width="70" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[No. Pago]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="1130" y="17" width="75" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Lote Pago]]></text>
				</staticText>
				<staticText>
					<reportElement mode="Opaque" x="1205" y="17" width="55" height="24" forecolor="#000000" backcolor="#CBE3F9"/>
					<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 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[Fecha Pago]]></text>
				</staticText>
			</band>
		</groupHeader>
		<groupFooter>
			<band height="24">
				<textField>
					<reportElement mode="Opaque" x="0" y="0" width="492" height="12" forecolor="#000000" backcolor="#D2D0D0"/>
					<box leftPadding="2" 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.lang.String"><![CDATA["Total Beneficiario " + $F{COMPLETO_TERCERO}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement mode="Opaque" x="712" y="0" width="548" height="12" forecolor="#000000" backcolor="#D2D0D0"/>
					<box leftPadding="3">
						<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="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
					</textElement>
					<text><![CDATA[]]></text>
				</staticText>
				<textField pattern="#,##0.00;(#,##0.00)" isBlankWhenNull="false">
					<reportElement mode="Opaque" x="492" y="0" width="75" height="12" forecolor="#000000" backcolor="#D2D0D0"/>
					<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" rotation="None" markup="none">
						<font fontName="SansSerif" size="6" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
					</textElement>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{sum_valor_embargo}]]></textFieldExpression>
				</textField>
				<textField pattern="#,##0.00;(#,##0.00)" isBlankWhenNull="false">
					<reportElement mode="Opaque" x="567" y="0" width="75" height="12" forecolor="#000000" backcolor="#D2D0D0"/>
					<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" rotation="None" markup="none">
						<font fontName="SansSerif" size="6" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
					</textElement>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{sum_valor_aplicado}]]></textFieldExpression>
				</textField>
				<textField pattern="#,##0.00;(#,##0.00)" isBlankWhenNull="false">
					<reportElement mode="Opaque" x="642" y="0" width="70" height="12" forecolor="#000000" backcolor="#D2D0D0"/>
					<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" rotation="None" markup="none">
						<font fontName="SansSerif" size="6" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
					</textElement>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{sum_saldo}]]></textFieldExpression>
				</textField>
			</band>
		</groupFooter>
	</group>
	<background>
		<band splitType="Stretch"/>
	</background>
	<title>
		<band height="60" splitType="Stretch">
			<textField pattern="dd-MM-yyyy   hh:mm aaa">
				<reportElement mode="Opaque" x="642" y="40" width="110" height="12" forecolor="#000000" backcolor="#FFFFFF"/>
				<textElement textAlignment="Right" verticalAlignment="Middle" rotation="None" markup="none">
					<font fontName="SansSerif" size="8" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<textFieldExpression class="java.util.Date"><![CDATA[new java.util.Date()]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement x="160" y="0" width="482" height="40"/>
				<textElement textAlignment="Center" verticalAlignment="Bottom" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<text><![CDATA[Sistema de Distribución de Regalías
Informe General de Embargos]]></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="642" y="28" width="110" 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>
				<reportElement x="160" y="40" width="482" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["Corte a: " + $P{nom_periodo} + " de " + $P{id_anhos}]]></textFieldExpression>
			</textField>
		</band>
	</title>
	<pageHeader>
		<band height="20" splitType="Stretch"/>
	</pageHeader>
	<detail>
		<band height="10" splitType="Stretch">
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="0" y="0" width="40" height="10"/>
				<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">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{ID_DES_PAGO}]]></textFieldExpression>
			</textField>
			<textField pattern="dd/MM/yyyy">
				<reportElement stretchType="RelativeToTallestObject" x="40" y="0" width="55" height="10"/>
				<box leftPadding="0">
					<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.util.Date"><![CDATA[$F{FECHA_PROC}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="160" y="0" width="60" height="10"/>
				<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">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{NUM_DOC_ACREE}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="95" y="0" width="65" height="10"/>
				<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{ABREVIATURA}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="220" y="0" width="145" height="10"/>
				<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{RAZON_SOC_ACREE}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="365" y="0" width="127" height="10"/>
				<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{OBSERVACIONES}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)">
				<reportElement stretchType="RelativeToTallestObject" x="492" y="0" width="75" height="10"/>
				<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">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOR}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)">
				<reportElement stretchType="RelativeToTallestObject" x="567" y="0" width="75" height="10"/>
				<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">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{VALOR_APLICADO}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)">
				<reportElement stretchType="RelativeToTallestObject" x="642" y="0" width="70" height="10"/>
				<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">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{SALDO}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement stretchType="RelativeToTallestObject" x="712" y="0" width="40" height="10"/>
				<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 textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[($F{ESTADO}==0 ? "Suspendido" : "Activo" )]]></textFieldExpression>
			</textField>
			<textField isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="752" y="0" width="60" height="10"/>
				<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">
					<font size="6"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{NUMERO_DOC_1}]]></textFieldExpression>
			</textField>
			<textField pattern="dd/MM/yyyy" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="812" y="0" width="55" height="10"/>
				<box leftPadding="0">
					<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.util.Date"><![CDATA[$F{FECHA_DOC_1}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="867" y="0" width="193" height="10"/>
				<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{OBSERVACIONES_1}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="1205" y="0" width="55" height="10"/>
				<box leftPadding="0">
					<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{FECHA_PAGO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="1130" y="0" width="75" height="10"/>
				<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{LOTE_PAGO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="1060" y="0" width="70" height="10"/>
				<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{NUM_PAGO}]]></textFieldExpression>
			</textField>
		</band>
	</detail>
	<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 - Regalias]]></text>
			</staticText>
		</band>
	</pageFooter>
	<summary>
		<band height="25" splitType="Stretch">
			<staticText>
				<reportElement mode="Opaque" x="0" y="0" width="492" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="3">
					<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="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Totales]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="712" y="0" width="548" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="3">
					<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="8" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[]]></text>
			</staticText>
			<textField pattern="#,##0.00;(#,##0.00)" isBlankWhenNull="false">
				<reportElement mode="Opaque" x="492" y="0" width="75" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<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" 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_embargo}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)" isBlankWhenNull="false">
				<reportElement mode="Opaque" x="642" y="0" width="70" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<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" 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_saldo}]]></textFieldExpression>
			</textField>
			<textField pattern="#,##0.00;(#,##0.00)" isBlankWhenNull="false">
				<reportElement mode="Opaque" x="567" y="0" width="75" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<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" 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_aplicado}]]></textFieldExpression>
			</textField>
		</band>
	</summary>
	<noData>
		<band height="20">
			<staticText>
				<reportElement x="0" y="0" width="752" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font isBold="true"/>
				</textElement>
				<text><![CDATA[No hay objetos a mostrar.]]></text>
			</staticText>
		</band>
	</noData>
</jasperReport>
