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

	<parameter name="username" isForPrompting="true" class="java.lang.String"/>
	<parameter name="pgroup_code" isForPrompting="true" class="java.lang.String"/>
	<queryString><![CDATA[call sppureport21_fifo($P{pgroup_code})]]></queryString>

	<field name="ftcompany_name" class="java.lang.String"/>
	<field name="ftstock_group_code" class="java.lang.String"/>
	<field name="ftstock_group_name" class="java.lang.String"/>
	<field name="ftItem_Code" class="java.lang.String"/>
	<field name="ftItem_Name" class="java.lang.String"/>
	<field name="ftuom_code" class="java.lang.String"/>
	<field name="fnQty_Outstanding" class="java.lang.Double"/>
	<field name="fcNet_Price" class="java.lang.Double"/>
	<field name="fcamount" class="java.lang.Double"/>

	<variable name="urut" class="java.lang.Integer" resetType="Report" calculation="Count">
		<variableExpression><![CDATA[new java.lang.Integer(0) ]]></variableExpression>
		<initialValueExpression><![CDATA[new java.lang.Integer(1) ]]></initialValueExpression>
	</variable>
	<variable name="sub_total" class="java.lang.Double" resetType="Group" resetGroup="ftstock_group_name" calculation="Sum">
		<variableExpression><![CDATA[$F{fcamount}]]></variableExpression>
	</variable>
	<variable name="grand_total" class="java.lang.Double" resetType="Group" resetGroup="ftcompany_name" calculation="Sum">
		<variableExpression><![CDATA[$F{fcamount}]]></variableExpression>
	</variable>

		<group  name="ftcompany_name" >
			<groupExpression><![CDATA[$F{ftcompany_name}]]></groupExpression>
			<groupHeader>
			<band height="0"  isSplitAllowed="true" >
			</band>
			</groupHeader>
			<groupFooter>
			<band height="31"  isSplitAllowed="true" >
				<line direction="BottomUp">
					<reportElement
						x="696"
						y="3"
						width="418"
						height="1"
						key="line-4"/>
					<graphicElement stretchType="NoStretch"/>
				</line>
				<staticText>
					<reportElement
						x="759"
						y="9"
						width="202"
						height="17"
						key="staticText-53"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Grand Total :]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" pattern="#,##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="967"
						y="9"
						width="148"
						height="18"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Right">
						<font/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$V{grand_total}]]></textFieldExpression>
				</textField>
			</band>
			</groupFooter>
		</group>
		<group  name="ftstock_group_name" >
			<groupExpression><![CDATA[$F{ftstock_group_name}]]></groupExpression>
			<groupHeader>
			<band height="18"  isSplitAllowed="true" >
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="1"
						y="-1"
						width="558"
						height="18"
						key="textField"/>
					<box></box>
					<textElement>
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true" isUnderline="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{ftstock_group_name}]]></textFieldExpression>
				</textField>
			</band>
			</groupHeader>
			<groupFooter>
			<band height="27"  isSplitAllowed="true" >
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="511"
						y="7"
						width="456"
						height="19"
						key="textField-9"/>
					<box></box>
					<textElement textAlignment="Right" verticalAlignment="Middle">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Total "+$F{ftstock_group_name}+" :"]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" pattern="#,##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="967"
						y="8"
						width="151"
						height="18"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Right" verticalAlignment="Middle">
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$V{sub_total}]]></textFieldExpression>
				</textField>
				<line direction="BottomUp">
					<reportElement
						x="698"
						y="3"
						width="418"
						height="1"
						key="line-3"/>
					<graphicElement stretchType="NoStretch"/>
				</line>
			</band>
			</groupFooter>
		</group>
		<background>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</background>
		<title>
			<band height="2"  isSplitAllowed="true" >
			</band>
		</title>
		<pageHeader>
			<band height="70"  isSplitAllowed="true" >
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="1"
						y="0"
						width="598"
						height="13"
						key="textField"/>
					<box></box>
					<textElement>
						<font fontName="Arial" size="11"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{ftcompany_name}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						x="-5"
						y="17"
						width="963"
						height="16"
						key="staticText-29"/>
					<box></box>
					<textElement textAlignment="Center">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[LAPORAN PERSEDIAAN  (FIFO )]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Report" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="857"
						y="1"
						width="100"
						height="14"
						key="textField-1"/>
					<box></box>
					<textElement>
						<font fontName="Arial" size="11"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[" " + $V{PAGE_NUMBER} + ""]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="757"
						y="1"
						width="100"
						height="14"
						key="textField-2"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" size="11"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Page " + $V{PAGE_NUMBER} + " of "]]></textFieldExpression>
				</textField>
				<line direction="TopDown">
					<reportElement
						x="1"
						y="40"
						width="1125"
						height="0"
						key="line-1"/>
					<graphicElement stretchType="NoStretch"/>
				</line>
				<line direction="TopDown">
					<reportElement
						x="1"
						y="66"
						width="1125"
						height="0"
						key="line-2"/>
					<graphicElement stretchType="NoStretch"/>
				</line>
				<staticText>
					<reportElement
						x="8"
						y="45"
						width="43"
						height="18"
						key="staticText-44"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[No.]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="60"
						y="45"
						width="146"
						height="18"
						key="staticText-47"/>
					<box></box>
					<textElement>
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Kode Barang]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="221"
						y="45"
						width="406"
						height="18"
						key="staticText-48"/>
					<box></box>
					<textElement>
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Nama Barang]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="748"
						y="45"
						width="101"
						height="18"
						key="staticText-49"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Qty Sisa]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="1020"
						y="45"
						width="95"
						height="18"
						key="staticText-50"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Total]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="857"
						y="45"
						width="101"
						height="18"
						key="staticText-51"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Harga]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="666"
						y="45"
						width="73"
						height="18"
						key="staticText-52"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[Satuan]]></text>
				</staticText>
			</band>
		</pageHeader>
		<columnHeader>
			<band height="1"  isSplitAllowed="true" >
			</band>
		</columnHeader>
		<detail>
			<band height="16"  isSplitAllowed="true" >
				<textField isStretchWithOverflow="true" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="2"
						y="0"
						width="41"
						height="16"
						key="textField"
						stretchType="RelativeToBandHeight"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<textElement textAlignment="Right" verticalAlignment="Top">
						<font fontName="Arial" size="11"/>
					</textElement>
				<textFieldExpression   class="java.lang.Integer"><![CDATA[$V{urut}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="true" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="60"
						y="-1"
						width="128"
						height="16"
						key="textField-6"
						stretchType="RelativeToBandHeight"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<textElement>
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{ftItem_Code}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="true" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="221"
						y="0"
						width="406"
						height="16"
						key="textField-7"
						stretchType="RelativeToBandHeight"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<textElement>
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{ftItem_Name}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" pattern="#,##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="747"
						y="0"
						width="101"
						height="16"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$F{fnQty_Outstanding}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" pattern="#,##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="856"
						y="0"
						width="101"
						height="15"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$F{fcNet_Price}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" pattern="#,##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="967"
						y="0"
						width="151"
						height="16"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$F{fcamount}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="673"
						y="0"
						width="67"
						height="16"
						key="textField-8"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{ftuom_code}]]></textFieldExpression>
				</textField>
			</band>
		</detail>
		<columnFooter>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</columnFooter>
		<pageFooter>
			<band height="67"  isSplitAllowed="true" >
				<textField isStretchWithOverflow="false" pattern="EEE, d MMM yyyy HH:mm:ss" isBlankWhenNull="false" evaluationTime="Report" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="748"
						y="33"
						width="205"
						height="18"
						key="textField-4"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" pdfFontName="Helvetica-Oblique" size="12" isItalic="true"/>
					</textElement>
				<textFieldExpression   class="java.util.Date"><![CDATA[new java.util.Date()]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="645"
						y="33"
						width="100"
						height="18"
						key="textField-5"/>
					<box></box>
					<textElement>
						<font fontName="Arial" size="12"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$P{username}]]></textFieldExpression>
				</textField>
			</band>
		</pageFooter>
		<summary>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</summary>
</jasperReport>
