<?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_kardex_ele_con_rango" language="groovy" pageWidth="1150" pageHeight="792" whenNoDataType="NoDataSection" columnWidth="1110" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
	<property name="ireport.zoom" value="1.366026910730144"/>
	<property name="ireport.x" value="15"/>
	<property name="ireport.y" value="0"/>
	<property name="ireport.jasperserver.reportUnit" value="/reports/inventario/inf_kardex_ele_con"/>
	<property name="ireport.jasperserver.url" value="http://192.168.2.43:8090/jasperserver/services/repository"/>
	<parameter name="fecha_ini" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="fecha_fin" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="id_cen_op" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="id_tipo_almacenamiento" class="java.lang.String">
		<defaultValueExpression><![CDATA[]]></defaultValueExpression>
	</parameter>
	<parameter name="whereLinea" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereClase" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereCatalogo" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereFecha" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereCenOp" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereTipoAlmacenamiento" class="java.lang.String">
		<defaultValueExpression><![CDATA[""]]></defaultValueExpression>
	</parameter>
	<parameter name="whereCodigoElementoMayor" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="whereCodigoElementoMenor" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="codigo_elemento_ini" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<parameter name="codigo_elemento_fin" class="java.lang.String">
		<defaultValueExpression><![CDATA[" "]]></defaultValueExpression>
	</parameter>
	<queryString>
		<![CDATA[select

(select max(desc_catalogo) from in_codigo_elemento_v where codigo_elemento='$P!{codigo_elemento_ini}') as desc_catalogo_ini,
(select max(desc_catalogo) from in_codigo_elemento_v where codigo_elemento='$P!{codigo_elemento_fin}') as desc_catalogo_fin,

tab0.*,
(select descripcion from in_tipo_almacenamiento where id_tipo_almacenamiento=$P{id_tipo_almacenamiento}) as desc_almac,
(select nom_cen_op from centro_operacion where id_cen_op=$P{id_cen_op}) as nom_cen_op,
(
    select
    max(mc.fecha_mov)
    from in_det_mov_con dm
    join in_movimientos_con mc on dm.id_movimientos_con=mc.id_movimientos_con and dm.id_vigencia=mc.id_vigencia
    and dm.id_tipo_movimiento=mc.id_tipo_movimiento and dm.id_cen_op=mc.id_cen_op
    join in_inventario_con ic on dm.id_inventario_con=ic.id_inventario_con
    where mc.estado=0 and mc.anulado=0 and mc.id_tipo_movimiento=1
    AND ic.id_cen_op = tab0.id_cen_op
    AND ic.id_tipo_almacenamiento = tab0.id_tipo_almacenamiento
    AND ic.id_linea = tab0.id_linea
    AND ic.id_clase = tab0.id_clase
    AND ic.id_catalogo = tab0.id_catalogo
)as fecha_last,
nvl(ta.saldo_anterior,0) as saldo_anterior,
nvl(tabsal.saldo_anterior,0) as saldoant

from(---- traer entradas
    select
    0 as tag_sal,
    cev.codigo_elemento, cev.id_linea, cev.id_clase, cev.id_catalogo,
    cev.desc_catalogo, mc.id_movimientos_con, ic.id_cen_op, ic.id_tipo_almacenamiento, mc.anulado, mc.estado,
    cp.descripcion as desc_concepto, mc.fecha_mov as fecha,
    case
    when mc.id_tipo_movimiento=1 then dm.cantidad
    else 0
    end as entradas,
    case
    when mc.id_tipo_movimiento=3 then dm.cantidad
    when mc.id_tipo_movimiento=2 then dm.cantidad
    else 0
    end as salidas,
    case
    when mc.id_tipo_movimiento=1 then dm.valor_unitario * dm.cantidad
    else 0
    end as valor_entradas,
    case
    when mc.id_tipo_movimiento=3 then dm.valor_promedio * dm.cantidad
    when mc.id_tipo_movimiento=2 then dm.valor_promedio * dm.cantidad
    else 0
    end as valor_salidas,

    dm.saldo,
    dm.saldo*dm.valor_promedio as costo_promedio,
    dm.valor_promedio,
    dm.valor_unitario
    from in_det_mov_con dm
    join in_movimientos_con mc on dm.id_movimientos_con=mc.id_movimientos_con and dm.id_vigencia=mc.id_vigencia and dm.id_tipo_movimiento=mc.id_tipo_movimiento and dm.id_cen_op=mc.id_cen_op
    join in_concepto_movimiento cp on mc.id_concepto_movimiento=cp.id_concepto_movimiento
    join in_inventario_con ic on dm.id_inventario_con=ic.id_inventario_con
    join in_codigo_elemento_v cev on ic.id_linea=cev.id_linea and ic.id_clase=cev.id_clase and ic.id_catalogo=cev.id_catalogo
    where
    mc.estado=0
    --and mc.anulado=0


    union

    ---- traer traslados
    select
    0 as tag_sal,
    cev.codigo_elemento, cev.id_linea, cev.id_clase, cev.id_catalogo,
    cev.desc_catalogo, mc.id_movimientos_con, ic.id_cen_op, ic.id_tipo_almacenamiento, mc.anulado, mc.estado,
    cp.descripcion as desc_concepto, mc.fecha_mov  as fecha,
    dm.cantidad as entradas,
    0 as salidas,
    dm.valor_unitario * dm.cantidad as valor_entradas,
    0 as valor_salidas,
    dm.saldo_fin,
    dm.saldo_fin*dm.valor_promedio as costo_promedio,
    dm.valor_promedio,
    dm.valor_unitario
    from in_det_mov_con dm
    join in_movimientos_con mc on dm.id_movimientos_con=mc.id_movimientos_con and dm.id_vigencia=mc.id_vigencia and dm.id_tipo_movimiento=mc.id_tipo_movimiento and dm.id_cen_op=mc.id_cen_op
    join in_concepto_movimiento cp on mc.id_concepto_movimiento=cp.id_concepto_movimiento
    join in_inventario_con ic on dm.id_inventario_con_fin=ic.id_inventario_con
    join in_codigo_elemento_v cev on ic.id_linea=cev.id_linea and ic.id_clase=cev.id_clase and ic.id_catalogo=cev.id_catalogo
    where
    mc.estado=0
    --and mc.anulado=0
    and mc.id_tipo_movimiento=2

    union

    /* Saldo anterior, para mostar total y cabecera - 20170925*/
    select tab13.* from(

        select
        1 as tag_sal,
        cev.codigo_elemento, tab0.id_linea, tab0.id_clase, tab0.id_catalogo,
        cev.desc_catalogo, null as id_movimientos_con, tab0.id_cen_op, tab0.id_tipo_almacenamiento, 1 as anulado, 1 as estado,
        null as desc_concepto,
        to_date($P{fecha_ini}, 'dd/mm/yyyy') as fecha,
        0 as entradas,
        0 as salidas,
        0 as valor_entradas,
        0 as valor_salidas,
        0 as saldo_fin,
        0 as costo_promedio,
        0 as valor_promedio,
        0 as valor_unitario
        --sum(sal.saldo_anterior) as  saldo_anterior
        from in_saldo_inventario_con sal
        join in_inventario_con tab0 on sal.id_inventario_con = tab0.id_inventario_con
        join in_codigo_elemento_v cev on tab0.id_linea=cev.id_linea and tab0.id_clase=cev.id_clase and tab0.id_catalogo=cev.id_catalogo
        where
        sal.id_vigencia = to_char( to_date($P{fecha_ini}, 'dd/mm/yyyy'), 'yyyy' )
        and sal.id_meses = to_char( to_date($P{fecha_ini}, 'dd/mm/yyyy') ,'mm' )
        $P!{whereCenOp}
        $P!{whereTipoAlmacenamiento}
    )tab13
    where rownum=1
)tab0

left join(
    select * from(
        select
        cev.codigo_elemento,
        dm.saldo as saldo_anterior,
         ROW_NUMBER() OVER (
          partition by cev.codigo_elemento
          ORDER BY cev.codigo_elemento, mc.fecha_mov desc
         ) AS rn
        from in_det_mov_con dm
        join in_movimientos_con mc on dm.id_movimientos_con=mc.id_movimientos_con and dm.id_vigencia=mc.id_vigencia and dm.id_tipo_movimiento=mc.id_tipo_movimiento and dm.id_cen_op=mc.id_cen_op
        join in_inventario_con tab0 on dm.id_inventario_con=tab0.id_inventario_con
        join in_codigo_elemento_v cev on tab0.id_linea=cev.id_linea
        and tab0.id_clase=cev.id_clase and tab0.id_catalogo=cev.id_catalogo
        where mc.estado=0 and mc.anulado=0 and mc.fecha_mov < to_date($P{fecha_ini}, 'dd/mm/yyyy')
        $P!{whereCenOp}
        $P!{whereTipoAlmacenamiento}
        order by mc.fecha_mov desc
    )
    where
    rn = 1
)ta on 1=1
and ta.codigo_elemento = tab0.codigo_elemento

left join
(
    select codigo_elemento, saldo_anterior from(

        select
        cev.codigo_elemento,
        sum(sal.saldo_anterior) as  saldo_anterior
        from in_saldo_inventario_con sal
        join in_inventario_con tab0 on sal.id_inventario_con = tab0.id_inventario_con
        join in_codigo_elemento_v cev on tab0.id_linea=cev.id_linea
        and tab0.id_clase=cev.id_clase and tab0.id_catalogo=cev.id_catalogo
        where
        sal.id_vigencia = to_char( to_date($P{fecha_ini}, 'dd/mm/yyyy'), 'yyyy' )
        and sal.id_meses = to_char( to_date($P{fecha_ini}, 'dd/mm/yyyy') ,'mm' )
        $P!{whereCenOp}
        $P!{whereTipoAlmacenamiento}
        group by
        cev.codigo_elemento
    )
)tabsal
on 1=1
and tabsal.codigo_elemento = tab0.codigo_elemento

where
1=1
and tab0.anulado = 0
$P!{whereFecha}
$P!{whereCenOp}
$P!{whereTipoAlmacenamiento}
$P!{whereCodigoElementoMayor}
$P!{whereCodigoElementoMenor}

order by
tab0.codigo_elemento,
tab0.fecha,
tab0.id_movimientos_con]]>
	</queryString>
	<field name="DESC_CATALOGO_INI" class="java.lang.String"/>
	<field name="DESC_CATALOGO_FIN" class="java.lang.String"/>
	<field name="TAG_SAL" class="java.math.BigDecimal"/>
	<field name="CODIGO_ELEMENTO" class="java.lang.String"/>
	<field name="ID_LINEA" class="java.math.BigDecimal"/>
	<field name="ID_CLASE" class="java.math.BigDecimal"/>
	<field name="ID_CATALOGO" class="java.math.BigDecimal"/>
	<field name="DESC_CATALOGO" class="java.lang.String"/>
	<field name="ID_MOVIMIENTOS_CON" class="java.math.BigDecimal"/>
	<field name="ID_CEN_OP" class="java.math.BigDecimal"/>
	<field name="ID_TIPO_ALMACENAMIENTO" class="java.math.BigDecimal"/>
	<field name="ANULADO" class="java.math.BigDecimal"/>
	<field name="ESTADO" class="java.math.BigDecimal"/>
	<field name="DESC_CONCEPTO" class="java.lang.String"/>
	<field name="FECHA" class="java.sql.Timestamp"/>
	<field name="ENTRADAS" class="java.math.BigDecimal"/>
	<field name="SALIDAS" class="java.math.BigDecimal"/>
	<field name="VALOR_ENTRADAS" class="java.math.BigDecimal"/>
	<field name="VALOR_SALIDAS" class="java.math.BigDecimal"/>
	<field name="SALDO" class="java.math.BigDecimal"/>
	<field name="COSTO_PROMEDIO" class="java.math.BigDecimal"/>
	<field name="VALOR_PROMEDIO" class="java.math.BigDecimal"/>
	<field name="VALOR_UNITARIO" class="java.math.BigDecimal"/>
	<field name="DESC_ALMAC" class="java.lang.String"/>
	<field name="NOM_CEN_OP" class="java.lang.String"/>
	<field name="FECHA_LAST" class="java.sql.Timestamp"/>
	<field name="SALDO_ANTERIOR" class="java.math.BigDecimal"/>
	<field name="SALDOANT" class="java.math.BigDecimal"/>
	<variable name="sum_entradas" class="java.math.BigDecimal" resetType="Group" resetGroup="CODIGO" calculation="Sum">
		<variableExpression><![CDATA[$F{ANULADO}.intValue() == 0
? $F{ENTRADAS}
: 0]]></variableExpression>
	</variable>
	<variable name="sum_salidas" class="java.math.BigDecimal" resetType="Group" resetGroup="CODIGO" calculation="Sum">
		<variableExpression><![CDATA[$F{ANULADO}.intValue() == 0
? $F{SALIDAS}
: 0]]></variableExpression>
	</variable>
	<variable name="sum_saldo" class="java.math.BigDecimal" resetType="Group" resetGroup="CODIGO" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDO}]]></variableExpression>
	</variable>
	<variable name="sum_sal" class="java.math.BigDecimal" resetType="Group" resetGroup="CODIGO" calculation="Sum">
		<variableExpression><![CDATA[($F{ANULADO}.intValue() == 0
    ? $F{ENTRADAS} - $F{SALIDAS}
    :  0
)]]></variableExpression>
		<initialValueExpression><![CDATA[]]></initialValueExpression>
	</variable>
	<variable name="sum_entradas_tot" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{ANULADO}.intValue() == 0
? $F{ENTRADAS}
: 0]]></variableExpression>
	</variable>
	<variable name="sum_salidas_tot" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{ANULADO}.intValue() == 0
? $F{SALIDAS}
: 0]]></variableExpression>
	</variable>
	<variable name="sum_saldo_tot" class="java.math.BigDecimal" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDO}]]></variableExpression>
	</variable>
	<variable name="sum_sal_tot" class="java.math.BigDecimal" incrementType="Group" incrementGroup="CODIGO" calculation="Sum">
		<variableExpression><![CDATA[$F{SALDOANT}]]></variableExpression>
		<initialValueExpression><![CDATA[]]></initialValueExpression>
	</variable>
	<group name="CODIGO">
		<groupExpression><![CDATA[$F{CODIGO_ELEMENTO}]]></groupExpression>
		<groupHeader>
			<band height="10">
				<textField isStretchWithOverflow="true">
					<reportElement stretchType="RelativeToTallestObject" x="0" y="0" width="100" height="10" isRemoveLineWhenBlank="true">
						<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
					</reportElement>
					<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{CODIGO_ELEMENTO}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="true">
					<reportElement stretchType="RelativeToTallestObject" x="100" y="0" width="176" height="10" isRemoveLineWhenBlank="true">
						<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
					</reportElement>
					<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{DESC_CATALOGO}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="true">
					<reportElement stretchType="RelativeToTallestObject" x="820" y="0" width="55" height="10" isRemoveLineWhenBlank="true">
						<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
					</reportElement>
					<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" isBold="true"/>
					</textElement>
					<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{SALDOANT}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="true" isBlankWhenNull="true">
					<reportElement stretchType="RelativeToTallestObject" x="276" y="0" width="544" height="10" isRemoveLineWhenBlank="true">
						<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
					</reportElement>
					<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" isBold="true"/>
					</textElement>
					<textFieldExpression class="java.lang.String"><![CDATA["Saldo Inicial"]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="true" isBlankWhenNull="true">
					<reportElement stretchType="RelativeToTallestObject" x="875" y="0" width="235" height="10" isRemoveLineWhenBlank="true">
						<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
					</reportElement>
					<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>
				</textField>
			</band>
		</groupHeader>
		<groupFooter>
			<band height="12">
				<textField>
					<reportElement mode="Opaque" x="0" y="0" width="550" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box leftPadding="2">
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Left" 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 " + $F{CODIGO_ELEMENTO}]]></textFieldExpression>
				</textField>
				<textField>
					<reportElement mode="Opaque" x="605" y="0" width="80" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Left" 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[" "]]></textFieldExpression>
				</textField>
				<textField>
					<reportElement mode="Opaque" x="740" y="0" width="80" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Left" 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[" "]]></textFieldExpression>
				</textField>
				<textField pattern="###0;(-###0)">
					<reportElement mode="Opaque" x="685" y="0" width="55" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box leftPadding="0" rightPadding="3">
						<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{sum_salidas}]]></textFieldExpression>
				</textField>
				<textField pattern="###0;(-###0)">
					<reportElement mode="Opaque" x="820" y="0" width="55" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box leftPadding="0" rightPadding="3">
						<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[$F{SALDOANT} + $V{sum_entradas} - $V{sum_salidas}]]></textFieldExpression>
				</textField>
				<textField>
					<reportElement mode="Opaque" x="875" y="0" width="235" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box>
						<topPen lineWidth="0.75"/>
						<leftPen lineWidth="0.75"/>
						<bottomPen lineWidth="0.75"/>
						<rightPen lineWidth="0.75"/>
					</box>
					<textElement textAlignment="Left" 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[" "]]></textFieldExpression>
				</textField>
				<textField pattern="###0;(-###0)">
					<reportElement mode="Opaque" x="550" y="0" width="55" height="12" forecolor="#000000" backcolor="#CDCDCD"/>
					<box leftPadding="0" rightPadding="3">
						<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{sum_entradas}]]></textFieldExpression>
				</textField>
			</band>
		</groupFooter>
	</group>
	<background>
		<band splitType="Stretch"/>
	</background>
	<title>
		<band height="108" splitType="Stretch">
			<textField pattern="dd-MMM-yyyy   hh:mm aaa">
				<reportElement mode="Opaque" x="955" y="40" width="155" 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="230" y="0" width="725" height="40"/>
				<textElement textAlignment="Center" verticalAlignment="Bottom" markup="none">
					<font fontName="SansSerif" size="12" isBold="true"/>
				</textElement>
				<text><![CDATA[Sistema General de Inventarios
Informe de Kardex Elementos de Consumo por Rango de Códigos]]></text>
			</staticText>
			<image>
				<reportElement x="0" y="0" width="130" height="60"/>
				<imageExpression class="java.lang.String"><![CDATA["repo:LogoEmpresa003.jpg"]]></imageExpression>
			</image>
			<staticText>
				<reportElement mode="Opaque" x="955" y="28" width="155" 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="230" y="40" width="725" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle" markup="none">
					<font fontName="SansSerif" size="10" isBold="true"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA["Periodo de "+$P{fecha_ini}+" hasta "+$P{fecha_fin}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="0" y="80" width="230" height="14" forecolor="#000000" backcolor="#64B0F7"/>
				<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" rotation="None" markup="none">
					<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Código Elemento Desde:]]></text>
			</staticText>
			<textField>
				<reportElement x="230" y="80" width="320" height="14"/>
				<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="8"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$P{codigo_elemento_ini}+" - "+$F{DESC_CATALOGO_INI}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="550" y="94" width="190" height="14" forecolor="#000000" backcolor="#64B0F7"/>
				<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" rotation="None" markup="none">
					<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Centro Operación:]]></text>
			</staticText>
			<textField>
				<reportElement x="740" y="94" width="370" height="14"/>
				<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="8"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{NOM_CEN_OP}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="0" y="94" width="230" height="14" forecolor="#000000" backcolor="#64B0F7"/>
				<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" rotation="None" markup="none">
					<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Tipo Almacenamiento:]]></text>
			</staticText>
			<textField>
				<reportElement x="230" y="94" width="320" height="14"/>
				<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="8"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$F{DESC_ALMAC}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement mode="Opaque" x="550" y="80" width="190" height="14" forecolor="#000000" backcolor="#64B0F7"/>
				<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" rotation="None" markup="none">
					<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Código Elemento Hasta:]]></text>
			</staticText>
			<textField>
				<reportElement x="740" y="80" width="370" height="14"/>
				<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="8"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[$P{codigo_elemento_fin}+" - "+$F{DESC_CATALOGO_FIN}]]></textFieldExpression>
			</textField>
			<staticText>
				<reportElement x="0" y="60" width="1110" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font isBold="true"/>
				</textElement>
				<text><![CDATA[]]></text>
			</staticText>
		</band>
	</title>
	<pageHeader>
		<band height="12" splitType="Stretch"/>
	</pageHeader>
	<columnHeader>
		<band height="39" splitType="Stretch">
			<staticText>
				<reportElement mode="Opaque" x="230" y="25" width="46" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[N° Mov]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="276" y="25" width="134" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Concepto Mov]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="410" y="25" width="70" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Fecha Mov]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="550" y="25" width="55" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Cantidad]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="605" y="25" width="80" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Valor]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="550" y="11" width="135" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Entradas]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="740" y="25" width="80" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Valor]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="685" y="25" width="55" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Cantidad]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="685" y="11" width="135" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Salidas]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="820" y="25" width="55" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Cantidad]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="875" y="25" width="80" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Costo Prom.]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="820" y="11" width="135" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Saldo]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="955" y="25" width="78" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Valor Ud.]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="1033" y="25" width="77" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Valor Prom.]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="100" y="25" width="130" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Elemento]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="480" y="25" width="70" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Estado Mov]]></text>
			</staticText>
			<staticText>
				<reportElement mode="Opaque" x="0" y="25" width="100" height="14" forecolor="#000000" backcolor="#91C9FC"/>
				<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="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
				</textElement>
				<text><![CDATA[Código Elemento]]></text>
			</staticText>
			<staticText>
				<reportElement x="0" y="0" width="1110" height="11"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font isBold="true"/>
				</textElement>
				<text><![CDATA[]]></text>
			</staticText>
		</band>
	</columnHeader>
	<detail>
		<band height="10" splitType="Prevent">
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="230" y="0" width="46" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{ID_MOVIMIENTOS_CON}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="276" y="0" width="134" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{DESC_CONCEPTO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="dd/MM/yyyy">
				<reportElement stretchType="RelativeToTallestObject" x="410" y="0" width="70" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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.util.Date"><![CDATA[$F{FECHA}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="550" y="0" width="55" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{ENTRADAS}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="$ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="605" y="0" width="80" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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_ENTRADAS}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="685" y="0" width="55" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{SALIDAS}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="$ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="740" y="0" width="80" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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_SALIDAS}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="820" y="0" width="55" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{SALDOANT} + $V{sum_sal}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="$ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="875" y="0" width="80" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{COSTO_PROMEDIO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="$ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="955" y="0" width="78" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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_UNITARIO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" pattern="$ #,##0.00">
				<reportElement stretchType="RelativeToTallestObject" x="1033" y="0" width="77" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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_PROMEDIO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true" isBlankWhenNull="true">
				<reportElement stretchType="RelativeToTallestObject" x="480" y="0" width="70" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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="7"/>
				</textElement>
				<textFieldExpression class="java.lang.String"><![CDATA[($F{ANULADO}.intValue() == 1
    ? "Anulado"
    :  "Cerrado"
)]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="0" y="0" width="100" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{CODIGO_ELEMENTO}]]></textFieldExpression>
			</textField>
			<textField isStretchWithOverflow="true">
				<reportElement stretchType="RelativeToTallestObject" x="100" y="0" width="130" height="10" isRemoveLineWhenBlank="true">
					<printWhenExpression><![CDATA[$F{TAG_SAL} != 1]]></printWhenExpression>
				</reportElement>
				<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{DESC_CATALOGO}]]></textFieldExpression>
			</textField>
		</band>
	</detail>
	<columnFooter>
		<band height="17" splitType="Stretch"/>
	</columnFooter>
	<pageFooter>
		<band height="24" splitType="Stretch">
			<textField>
				<reportElement mode="Opaque" x="447" y="12" width="141" 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="589" y="12" width="73" 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="447" y="0" width="215" height="12" forecolor="#575757"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font size="6"/>
				</textElement>
				<text><![CDATA[Websafi - Inventarios]]></text>
			</staticText>
		</band>
	</pageFooter>
	<summary>
		<band height="25" splitType="Stretch">
			<textField>
				<reportElement mode="Opaque" x="0" y="0" width="550" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="2">
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Left" 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 General:"]]></textFieldExpression>
			</textField>
			<textField pattern="###0;(-###0)">
				<reportElement mode="Opaque" x="550" y="0" width="55" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="0" rightPadding="3">
					<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{sum_entradas_tot}]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement mode="Opaque" x="605" y="0" width="80" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Left" 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[" "]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement mode="Opaque" x="740" y="0" width="80" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Left" 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[" "]]></textFieldExpression>
			</textField>
			<textField>
				<reportElement mode="Opaque" x="875" y="0" width="235" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box>
					<topPen lineWidth="0.75"/>
					<leftPen lineWidth="0.75"/>
					<bottomPen lineWidth="0.75"/>
					<rightPen lineWidth="0.75"/>
				</box>
				<textElement textAlignment="Left" 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[" "]]></textFieldExpression>
			</textField>
			<textField pattern="###0;(-###0)">
				<reportElement mode="Opaque" x="685" y="0" width="55" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="0" rightPadding="3">
					<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{sum_salidas_tot}]]></textFieldExpression>
			</textField>
			<textField pattern="###0;(-###0)">
				<reportElement mode="Opaque" x="820" y="0" width="55" height="12" forecolor="#000000" backcolor="#BCBABA"/>
				<box leftPadding="0" rightPadding="3">
					<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{sum_sal_tot} + $V{sum_entradas_tot} - $V{sum_salidas_tot}]]></textFieldExpression>
			</textField>
		</band>
	</summary>
	<noData>
		<band height="20">
			<staticText>
				<reportElement x="0" y="0" width="1110" height="20"/>
				<textElement textAlignment="Center" verticalAlignment="Middle">
					<font isBold="true"/>
				</textElement>
				<text><![CDATA[No hay objetos a mostrar.]]></text>
			</staticText>
		</band>
	</noData>
</jasperReport>
