<?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="report02_purchasing_control_order"
		 columnCount="1"
		 printOrder="Vertical"
		 orientation="Landscape"
		 pageWidth="1190"
		 pageHeight="765"
		 columnWidth="1174"
		 columnSpacing="0"
		 leftMargin="8"
		 rightMargin="8"
		 topMargin="20"
		 bottomMargin="20"
		 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="date_from" isForPrompting="true" class="java.util.Date"/>
	<parameter name="date_end" isForPrompting="true" class="java.util.Date"/>
	<parameter name="supplier_code" isForPrompting="true" class="java.lang.String"/>
	<queryString><![CDATA[call sppureport02_purchasing_control_order($P{supplier_code},$P{date_from},$P{date_end})]]></queryString>

	<field name="ftcompany_name" class="java.lang.String"/>
	<field name="hdr_ftdocument_no_iso" class="java.lang.String"/>
	<field name="ftpo_no" class="java.lang.String"/>
	<field name="fdpo_date" class="java.sql.Date"/>
	<field name="ftsupplier_code" class="java.lang.String"/>
	<field name="ftsupplier_name" class="java.lang.String"/>
	<field name="ftitem_code" class="java.lang.String"/>
	<field name="ftitem_name" class="java.lang.String"/>
	<field name="fnqtypo" class="java.lang.Double"/>
	<field name="ftarrive_status" class="java.lang.String"/>
	<field name="ftstock_in_no" class="java.lang.String"/>
	<field name="fdstock_in_date" class="java.sql.Date"/>
	<field name="fdstock_in_datex" class="java.lang.String"/>
	<field name="fnqtyin" class="java.lang.Double"/>
	<field name="ftlpb" class="java.lang.String"/>
	<field name="ftmarking" class="java.lang.String"/>
	<field name="ftpayment_status" class="java.lang.String"/>
	<field name="fdpayment_date" class="java.sql.Timestamp"/>

	<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>

		<group  name="ftcompany_name" >
			<groupExpression><![CDATA[$F{ftcompany_name}]]></groupExpression>
			<groupHeader>
			<band height="0"  isSplitAllowed="true" >
			</band>
			</groupHeader>
			<groupFooter>
			<band height="46"  isSplitAllowed="true" >
				<crosstab >
					<reportElement
						x="3"
						y="2"
						width="1164"
						height="38"
						key="crosstab-1"/>
					<crosstabHeaderCell>						<cellContents mode="Transparent">
					<box>					<topPen lineWidth="1.0"/>
					<bottomPen lineWidth="1.0"/>
</box>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="100"
						height="25"
						key="textField-3"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["No. PO"]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="102"
						y="0"
						width="194"
						height="25"
						key="textField-3"/>
					<box></box>
					<textElement textAlignment="Left" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Nama Barang"]]></textFieldExpression>
				</textField>
						</cellContents>
					</crosstabHeaderCell>					<rowGroup name="ftpo_no" width="100" totalPosition="End">
						<bucket>
							<bucketExpression class="java.lang.String"><![CDATA[$F{ftpo_no}]]></bucketExpression>
						</bucket>
						<crosstabRowHeader>
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="true" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="100"
						height="23"
						key="textField"
						isPrintWhenDetailOverflows="true"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$V{ftpo_no}]]></textFieldExpression>
				</textField>
						</cellContents>
						</crosstabRowHeader>
						<crosstabTotalRowHeader>
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="100"
						height="30"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Total "]]></textFieldExpression>
				</textField>
						</cellContents>
						</crosstabTotalRowHeader>
					</rowGroup>
					<rowGroup name="ftitem_name" width="196">
						<bucket>
							<bucketExpression class="java.lang.String"><![CDATA[$F{ftitem_name}]]></bucketExpression>
						</bucket>
						<crosstabRowHeader>
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="192"
						height="23"
						key="textField"/>
					<box></box>
					<textElement verticalAlignment="Middle">
						<font/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$V{ftitem_name}]]></textFieldExpression>
				</textField>
						</cellContents>
						</crosstabRowHeader>
					</rowGroup>
					<columnGroup name="fdstock_in_datex" height="25" totalPosition="End" headerPosition="Center">
						<bucket>
							<bucketExpression class="java.lang.String"><![CDATA[$F{fdstock_in_datex}]]></bucketExpression>
						</bucket>
						<crosstabColumnHeader>
						<cellContents mode="Transparent">
					<box>					<topPen lineWidth="1.0"/>
					<bottomPen lineWidth="1.0"/>
</box>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="73"
						height="25"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$V{fdstock_in_datex}]]></textFieldExpression>
				</textField>
						</cellContents>
						</crosstabColumnHeader>
						<crosstabTotalColumnHeader>
						<cellContents mode="Transparent">
					<box>					<topPen lineWidth="1.0"/>
					<bottomPen lineWidth="1.0"/>
</box>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="50"
						height="25"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Total"]]></textFieldExpression>
				</textField>
						</cellContents>
						</crosstabTotalColumnHeader>
					</columnGroup>

					<measure name="fnqtyin_Sum" class="java.lang.Double" calculation="Sum">
						<measureExpression><![CDATA[$F{fnqtyin}]]></measureExpression>
					</measure>
					<crosstabCell width="75" height="23">
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="false" pattern="#,##0" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="75"
						height="23"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$V{fnqtyin_Sum}]]></textFieldExpression>
				</textField>
						</cellContents>
					</crosstabCell>
					<crosstabCell width="50" height="23" columnTotalGroup="fdstock_in_datex">
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="false" pattern="#,##0" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="50"
						height="23"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$V{fnqtyin_Sum}]]></textFieldExpression>
				</textField>
						</cellContents>
					</crosstabCell>
					<crosstabCell width="75" height="30" rowTotalGroup="ftpo_no">
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="false" pattern="#,##0" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="75"
						height="30"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$V{fnqtyin_Sum}]]></textFieldExpression>
				</textField>
						</cellContents>
					</crosstabCell>
					<crosstabCell width="50" height="30" rowTotalGroup="ftpo_no" columnTotalGroup="fdstock_in_datex">
						<cellContents mode="Transparent">
					<box></box>
				<textField isStretchWithOverflow="false" pattern="#,##0" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="50"
						height="30"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Center" verticalAlignment="Middle">
						<font pdfFontName="Helvetica-Bold" isBold="true"/>
					</textElement>
				<textFieldExpression   class="java.lang.Double"><![CDATA[$V{fnqtyin_Sum}]]></textFieldExpression>
				</textField>
						</cellContents>
					</crosstabCell>
					<crosstabCell width="75" height="0" rowTotalGroup="ftitem_name">
						<cellContents mode="Transparent">
					<box></box>
						</cellContents>
					</crosstabCell>
					<crosstabCell width="50" height="0" rowTotalGroup="ftitem_name" columnTotalGroup="fdstock_in_datex">
						<cellContents mode="Transparent">
					<box></box>
						</cellContents>
					</crosstabCell>
					<whenNoDataCell>						<cellContents mode="Transparent">
					<box></box>
						</cellContents>
					</whenNoDataCell>					</crosstab>
			</band>
			</groupFooter>
		</group>
		<background>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</background>
		<title>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</title>
		<pageHeader>
			<band height="58"  isSplitAllowed="true" >
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="0"
						y="0"
						width="302"
						height="18"
						key="textField"/>
					<box></box>
					<textElement>
						<font fontName="Arial" size="12"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA[$F{ftcompany_name}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						x="200"
						y="18"
						width="347"
						height="18"
						key="staticText-1"/>
					<box></box>
					<textElement textAlignment="Center">
						<font fontName="Arial" pdfFontName="Helvetica-Bold" size="12" isBold="true"/>
					</textElement>
				<text><![CDATA[LAPORAN PURCHASING CONTROL ORDER ]]></text>
				</staticText>
				<staticText>
					<reportElement
						x="0"
						y="36"
						width="92"
						height="20"
						key="staticText-2"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" size="12"/>
					</textElement>
				<text><![CDATA[Periode transaksi :]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" pattern="dd-MMM-yyyy" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="98"
						y="36"
						width="92"
						height="18"
						key="textField-1"/>
					<box></box>
					<textElement>
						<font fontName="Arial" pdfFontName="Helvetica" size="12" isBold="false" isStrikeThrough="false" />
					</textElement>
				<textFieldExpression   class="java.util.Date"><![CDATA[$P{date_from}]]></textFieldExpression>
				</textField>
				<staticText>
					<reportElement
						x="190"
						y="36"
						width="25"
						height="17"
						key="staticText-3"/>
					<box></box>
					<textElement textAlignment="Center">
						<font fontName="Arial"/>
					</textElement>
				<text><![CDATA[s/d]]></text>
				</staticText>
				<textField isStretchWithOverflow="false" pattern="dd-MMM-yyyy" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="215"
						y="36"
						width="100"
						height="18"
						key="textField-2"/>
					<box></box>
					<textElement>
						<font fontName="Arial" size="12"/>
					</textElement>
				<textFieldExpression   class="java.util.Date"><![CDATA[$P{date_end}]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="568"
						y="-17"
						width="100"
						height="18"
						key="textField"/>
					<box></box>
					<textElement textAlignment="Right">
						<font fontName="Arial" size="12"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["Page " + $V{PAGE_NUMBER} + " of "]]></textFieldExpression>
				</textField>
				<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Report" hyperlinkType="None"  hyperlinkTarget="Self" >
					<reportElement
						x="668"
						y="-17"
						width="100"
						height="18"
						key="textField"/>
					<box></box>
					<textElement>
						<font fontName="Arial" size="12"/>
					</textElement>
				<textFieldExpression   class="java.lang.String"><![CDATA["" + $V{PAGE_NUMBER} + ""]]></textFieldExpression>
				</textField>
			</band>
		</pageHeader>
		<columnHeader>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</columnHeader>
		<detail>
			<band height="0"  isSplitAllowed="true" >
			</band>
		</detail>
		<columnFooter>
			<band height="1"  isSplitAllowed="true" >
			</band>
		</columnFooter>
		<pageFooter>
			<band height="1"  isSplitAllowed="true" >
			</band>
		</pageFooter>
		<summary>
			<band height="20"  isSplitAllowed="true" >
			</band>
		</summary>
</jasperReport>
