Ver código fonte

update new report

master
CANCERYS\kw093 6 horas atrás
pai
commit
88ccf9c240
3 arquivos alterados com 811 adições e 0 exclusões
  1. +183
    -0
      src/main/java/com/ffii/fpsms/modules/report/service/ItemQcFailReportService.kt
  2. +67
    -0
      src/main/java/com/ffii/fpsms/modules/report/web/ItemQcFailReportController.kt
  3. +561
    -0
      src/main/resources/jasper/ItemQCReport.jrxml

+ 183
- 0
src/main/java/com/ffii/fpsms/modules/report/service/ItemQcFailReportService.kt Ver arquivo

@@ -0,0 +1,183 @@
package com.ffii.fpsms.modules.report.service

import com.ffii.core.support.JdbcDao
import org.springframework.stereotype.Service

@Service
open class ItemQcFailReportService(
private val jdbcDao: JdbcDao,
) {
fun searchItemQcFailReport(
stockCategory: String?, // items.type (可逗号分隔)
itemCode: String?, // items.code (可逗号分隔, LIKE)
lastInDateStart: String?, // stock_in_line.receiptDate >=
lastInDateEnd: String?, // stock_in_line.receiptDate <
): List<Map<String, Any>> {
val args = mutableMapOf<String, Any>()

val stockCategorySql = buildMultiValueExactClause(stockCategory, "it.type", "stockCategory", args)
val itemCodeSql = buildMultiValueLikeClause(itemCode, "it.code", "itemCode", args)

val lastInDateStartSql = if (!lastInDateStart.isNullOrBlank()) {
args["lastInDateStart"] = lastInDateStart
"AND sil.receiptDate >= :lastInDateStart"
} else ""

val lastInDateEndSql = if (!lastInDateEnd.isNullOrBlank()) {
args["lastInDateEnd"] = lastInDateEnd
"AND sil.receiptDate < :lastInDateEnd"
} else ""

val sql = """
SELECT
COALESCE(it.type, '') AS stockSubCategory,
COALESCE(it.code, '') AS itemNo,
COALESCE(CONCAT(
it.name,
CASE WHEN it.description IS NULL OR it.description = '' THEN '' ELSE CONCAT('\n', it.description) END
), '') AS itemName,
COALESCE(uc.udfudesc, uc.code, '') AS unitOfMeasure,
COALESCE(sil.lotNo, il.lotNo, '') AS lotNo,
COALESCE(DATE_FORMAT(COALESCE(sil.expiryDate, il.expiryDate), '%Y-%m-%d'), '') AS expiryDate,

/* 用 stock_in_line.jobOrderId 来判 IQC/EPQC */
CASE WHEN sil.jobOrderId IS NOT NULL THEN 'EPQC' ELSE 'IQC' END AS qcType,

/* QC Template Used:取 qc_category.code (例如 A1/B4/X1) */
COALESCE(
qc.name,
(SELECT name
FROM qc_category
WHERE isDefault = 1
AND deleted = 0
LIMIT 1),
qc.name,
''
) AS qcTemplate,

/* QC Criteria with Defect:优先用 qc_item_category.description,否则用 qc_item */
COALESCE(qic.description, qi.description, qi.name, '') AS qcDefectCriteria,

/* Lot Qty / Defect Qty:按 jrxml 字段类型输出 String */
TRIM(TRAILING '.' FROM TRIM(TRAILING '0' FROM FORMAT(COALESCE(sil.acceptedQty, 0), 2))) AS lotQty,
TRIM(TRAILING '.' FROM TRIM(TRAILING '0' FROM FORMAT(COALESCE(qr.failQty, 0), 2))) AS defectQty,

/* Ref Data (e.g temp):目前库表只有 qc_result.remarks,可先放这里 */
COALESCE(qr.remarks, '') AS refData,

/* Remarks:若你之后有独立字段再补 */
'' AS remark,

/* Order Ref No:IQC 用 purchase_order.code;EPQC 用 job_order.code */
CASE
WHEN sil.jobOrderId IS NOT NULL THEN COALESCE(jo.code, '')
ELSE COALESCE(po.code, '')
END AS orderRefNo

FROM qc_result qr
INNER JOIN stock_in_line sil
ON qr.stockInLineId = sil.id
AND sil.deleted = 0
INNER JOIN items it
ON qr.itemId = it.id
AND it.deleted = 0
LEFT JOIN item_uom iu
ON it.id = iu.itemId
AND iu.stockUnit = 1
AND iu.deleted = 0
LEFT JOIN uom_conversion uc
ON iu.uomId = uc.id
LEFT JOIN inventory_lot il
ON sil.inventoryLotId = il.id
AND il.deleted = 0
LEFT JOIN purchase_order po
ON sil.purchaseOrderId = po.id
AND po.deleted = 0
LEFT JOIN job_order jo
ON sil.jobOrderId = jo.id
AND jo.deleted = 0

LEFT JOIN items_qc_category_mapping iqcm
ON iqcm.itemId = it.id
AND iqcm.type = (CASE WHEN sil.jobOrderId IS NOT NULL THEN 'EPQC' ELSE 'IQC' END)
LEFT JOIN qc_category qc
ON qc.id = iqcm.qcCategoryId
AND qc.deleted = 0

LEFT JOIN qc_item qi
ON qi.id = qr.qcItemId
AND qi.deleted = 0
LEFT JOIN qc_item_category qic
ON qic.qcItemId = qi.id
AND qic.qcCategoryId = COALESCE(
iqcm.qcCategoryId,
(SELECT id
FROM qc_category
WHERE isDefault = 1
AND deleted = 0
LIMIT 1)
)

WHERE
qr.deleted = 0
AND qr.qcPassed = 0
$stockCategorySql
$itemCodeSql
$lastInDateStartSql
$lastInDateEndSql

ORDER BY
it.type,
it.code,
COALESCE(sil.lotNo, il.lotNo, ''),
CASE WHEN sil.jobOrderId IS NOT NULL THEN 'EPQC' ELSE 'IQC' END,
COALESCE(qic.`order`, 9999),
COALESCE(qi.code, '')
""".trimIndent()
val result = jdbcDao.queryForList(sql, args)
println("qcTemplate: ${result[0]["qcTemplate"]}")
println("qcDefectCriteria: ${result[0]["qcDefectCriteria"]}")
println("lotQty: ${result[0]["lotQty"]}")
println("defectQty: ${result[0]["defectQty"]}")
println("refData: ${result[0]["refData"]}")
println("remark: ${result[0]["remark"]}")
println("orderRefNo: ${result[0]["orderRefNo"]}")
return result
}

private fun buildMultiValueLikeClause(
paramValue: String?,
columnName: String,
paramPrefix: String,
args: MutableMap<String, Any>
): String {
if (paramValue.isNullOrBlank()) return ""
val values = paramValue.split(",").map { it.trim() }.filter { it.isNotBlank() }
if (values.isEmpty()) return ""

val conditions = values.mapIndexed { index, value ->
val paramName = "${paramPrefix}_$index"
args[paramName] = "%$value%"
"$columnName LIKE :$paramName"
}
return "AND (${conditions.joinToString(" OR ")})"
}

private fun buildMultiValueExactClause(
paramValue: String?,
columnName: String,
paramPrefix: String,
args: MutableMap<String, Any>
): String {
if (paramValue.isNullOrBlank()) return ""
val values = paramValue.split(",").map { it.trim() }.filter { it.isNotBlank() }
if (values.isEmpty()) return ""

val conditions = values.mapIndexed { index, value ->
val paramName = "${paramPrefix}_$index"
args[paramName] = value
"$columnName = :$paramName"
}
return "AND (${conditions.joinToString(" OR ")})"
}
}

+ 67
- 0
src/main/java/com/ffii/fpsms/modules/report/web/ItemQcFailReportController.kt Ver arquivo

@@ -0,0 +1,67 @@
package com.ffii.fpsms.modules.report.web

import net.sf.jasperreports.engine.*
import org.springframework.http.*
import org.springframework.web.bind.annotation.*
import java.time.LocalDate
import java.time.LocalTime
import java.time.format.DateTimeFormatter
import com.ffii.fpsms.modules.report.service.ItemQcFailReportService
import com.ffii.fpsms.modules.report.service.ReportService

@RestController
@RequestMapping("/report")
class ItemQcFailReportController(

private val reportService: ReportService,
private val itemQcFailReportService: ItemQcFailReportService,
) {

@GetMapping("/print-item-qc-fail")
fun generateItemQcFailReport(
@RequestParam(required = false) stockCategory: String?,
@RequestParam(required = false) itemCode: String?,
@RequestParam(required = false) lastInDateStart: String?,
@RequestParam(required = false) lastInDateEnd: String?,
): ResponseEntity<ByteArray> {
val parameters = mutableMapOf<String, Any>()

parameters["stockCategory"] = stockCategory ?: "All"
parameters["stockSubCategory"] = stockCategory ?: "All" // 你定义 stock sub category = items.type
parameters["itemNo"] = itemCode ?: "All"
parameters["year"] = java.time.LocalDate.now().year.toString()
parameters["reportDate"] = java.time.LocalDate.now().format(java.time.format.DateTimeFormatter.ofPattern("yyyy-MM-dd"))
parameters["reportTime"] = java.time.LocalTime.now().format(java.time.format.DateTimeFormatter.ofPattern("HH:mm:ss"))

// jrxml 里有这些参数,先给空
parameters["storeLocation"] = ""
parameters["balanceFilterStart"] = ""
parameters["balanceFilterEnd"] = ""
parameters["lastInDateStart"] = lastInDateStart ?: ""
parameters["lastInDateEnd"] = lastInDateEnd ?: ""
parameters["lastOutDateStart"] = ""
parameters["lastOutDateEnd"] = ""

val dbData = itemQcFailReportService.searchItemQcFailReport(
stockCategory = stockCategory,
itemCode = itemCode,
lastInDateStart = lastInDateStart,
lastInDateEnd = lastInDateEnd,
)

val pdfBytes = reportService.createPdfResponse(
"/jasper/ItemQCReport.jrxml",
parameters,
dbData
)

val headers = org.springframework.http.HttpHeaders().apply {
contentType = org.springframework.http.MediaType.APPLICATION_PDF
setContentDispositionFormData("attachment", "ItemQCFailReport.pdf")
set("filename", "ItemQCFailReport.pdf")
}
return org.springframework.http.ResponseEntity(pdfBytes, headers, org.springframework.http.HttpStatus.OK)
}
}



+ 561
- 0
src/main/resources/jasper/ItemQCReport.jrxml Ver arquivo

@@ -0,0 +1,561 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Created with Jaspersoft Studio version 6.17.0.final using JasperReports Library version 6.17.0-6d93193241dd8cc42629e188b94f9e0bc5722efd -->
<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="ItemQCReport" pageWidth="842" pageHeight="595" orientation="Landscape" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="6a86bad3-14fb-475b-b1eb-824e47f43432">
<subDataset name="Empty Dataset1" uuid="b8103bc4-ba4d-4924-9104-c2a6b6737612"/>
<parameter name="stockSubCategory" class="java.lang.String">
<defaultValueExpression><![CDATA["stockSubCategory"]]></defaultValueExpression>
</parameter>
<parameter name="stockCategory" class="java.lang.String">
<defaultValueExpression><![CDATA["stockCategory"]]></defaultValueExpression>
</parameter>
<parameter name="itemNo" class="java.lang.String">
<defaultValueExpression><![CDATA["itemCode"]]></defaultValueExpression>
</parameter>
<parameter name="year" class="java.lang.String"/>
<parameter name="reportDate" class="java.lang.String"/>
<parameter name="reportTime" class="java.lang.String"/>
<parameter name="storeLocation" class="java.lang.String">
<parameterDescription><![CDATA["storeLocation"]]></parameterDescription>
</parameter>
<parameter name="balanceFilterStart" class="java.lang.String">
<parameterDescription><![CDATA["balanceFilterStart"]]></parameterDescription>
</parameter>
<parameter name="balanceFilterEnd" class="java.lang.String">
<parameterDescription><![CDATA["balanceFilterEnd"]]></parameterDescription>
</parameter>
<parameter name="lastInDateStart" class="java.lang.String">
<parameterDescription><![CDATA["lastInDateStart"]]></parameterDescription>
</parameter>
<parameter name="lastOutDateStart" class="java.lang.String">
<parameterDescription><![CDATA["lastOutDateStart"]]></parameterDescription>
</parameter>
<parameter name="lastInDateEnd" class="java.lang.String">
<parameterDescription><![CDATA["lastInDateStart"]]></parameterDescription>
</parameter>
<parameter name="lastOutDateEnd" class="java.lang.String">
<parameterDescription><![CDATA["lastOutDateStart"]]></parameterDescription>
</parameter>
<queryString>
<![CDATA[]]>
</queryString>
<field name="itemNo" class="java.lang.String"/>
<field name="itemName" class="java.lang.String"/>
<field name="unitOfMeasure" class="java.lang.String"/>
<field name="lotNo" class="java.lang.String"/>
<field name="expiryDate" class="java.lang.String"/>
<field name="qcType" class="java.lang.String"/>
<field name="qcTemplate" class="java.lang.String"/>
<field name="qcDefectCriteria" class="java.lang.String"/>
<field name="lotQty" class="java.lang.String"/>
<field name="defectQty" class="java.lang.String"/>
<field name="refData" class="java.lang.String"/>
<field name="remark" class="java.lang.String"/>
<field name="orderRefNo" class="java.lang.String"/>
<field name="stockSubCategory" class="java.lang.String"/>
<group name="Group1">
<groupExpression><![CDATA[$F{itemNo}]]></groupExpression>
<groupHeader>
<band height="70">
<property name="com.jaspersoft.studio.layout" value="com.jaspersoft.studio.editor.layout.FreeLayout"/>
<staticText>
<reportElement x="220" y="2" width="100" height="20" uuid="cef3d30b-3a1a-473b-8c64-7b5853249a2d">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[貨品名稱]]></text>
</staticText>
<staticText>
<reportElement x="140" y="2" width="80" height="20" uuid="5f174805-6b43-41ee-8ce2-31d24637691b">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[貨品編號]]></text>
</staticText>
<textField>
<reportElement x="0" y="22" width="140" height="20" uuid="c0b124cd-bcb0-4160-920d-9af8999d8193"/>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$F{stockSubCategory}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="0" y="2" width="140" height="20" uuid="ebf23e1d-a6c6-4837-b745-4806da3b941d">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[貨物子分類]]></text>
</staticText>
<textField>
<reportElement x="140" y="22" width="80" height="20" uuid="b5f95bb0-7462-4997-bc8e-e8da4e5e1b9b"/>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$F{itemNo}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="220" y="22" width="100" height="20" uuid="5d1ed7c1-ae6d-4cac-8b9c-3108899c2360">
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$F{itemName}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="320" y="22" width="61" height="20" uuid="61320e5d-0621-47f0-889b-b3c5e40447c0">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Top">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<textFieldExpression><![CDATA[$F{unitOfMeasure}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="320" y="2" width="61" height="20" uuid="cbcb5f4c-23a5-4273-910d-c596bcb3c7f0">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[單位]]></text>
</staticText>
<staticText>
<reportElement x="0" y="52" width="70" height="18" uuid="a5f5f7b8-580b-4f1f-971d-b2a9619d570a">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[批號]]></text>
</staticText>
<staticText>
<reportElement x="70" y="52" width="90" height="18" uuid="67fc8d08-74ed-4e63-af62-4bf566c2bea4">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[到期日]]></text>
</staticText>
<staticText>
<reportElement x="160" y="52" width="90" height="18" uuid="7db4a800-8573-408c-baad-f4f4885625c9">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[品質檢查類型]]></text>
</staticText>
<staticText>
<reportElement x="250" y="52" width="90" height="18" uuid="f6036ff2-a00e-4809-bcb2-f4e86fb1ccf7">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[品質檢查樣板]]></text>
</staticText>
<staticText>
<reportElement x="340" y="52" width="130" height="18" uuid="26c0ec07-f36c-4f9a-8b9c-5e485bdd501e">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[品質問題點]]></text>
</staticText>
<staticText>
<reportElement x="470" y="52" width="50" height="18" uuid="808b9adc-e79f-469b-89f8-a4d8035d0b02">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[批量]]></text>
</staticText>
<staticText>
<reportElement x="520" y="52" width="50" height="18" uuid="7d8c7616-20d1-4081-853b-34bf90711d8f">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[瑕疵品數量]]></text>
</staticText>
<staticText>
<reportElement x="570" y="52" width="60" height="18" uuid="e36d0d94-9345-46d2-8fa5-604676255cba">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[參考數據]]></text>
</staticText>
<staticText>
<reportElement x="630" y="52" width="90" height="18" uuid="0405bb1d-d677-436c-85bd-57345f1bb6bc">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[備注]]></text>
</staticText>
<staticText>
<reportElement x="720" y="52" width="80" height="18" uuid="8b11690e-d04c-4402-9436-dba241594b9a">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="10"/>
</textElement>
<text><![CDATA[Order Ref No.]]></text>
</staticText>
<line>
<reportElement x="0" y="68" width="800" height="1" uuid="b9fe93ec-e2d2-4f9a-8339-f61b3c9ef3ab">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
</band>
</groupHeader>
<groupFooter>
<band height="5">
<line>
<reportElement x="0" y="0" width="799" height="1" uuid="babfccb0-edd7-419b-92df-848cf3da5c45">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
<line>
<reportElement x="0" y="4" width="799" height="1" uuid="18a2cefa-4d37-479e-9e90-f690a5cd24b5">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
</band>
</groupFooter>
</group>
<background>
<band splitType="Stretch"/>
</background>
<pageHeader>
<band height="180" splitType="Stretch">
<textField>
<reportElement x="90" y="58" width="390" height="23" uuid="4c8a499b-bbdb-4ebd-82be-42470f9614db">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{stockCategory}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="0" y="58" width="90" height="23" uuid="27f73af0-5568-440b-8330-cb8b80e3ac52">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<text><![CDATA[貨物分類:]]></text>
</staticText>
<textField evaluationTime="Report">
<reportElement x="780" y="12" width="20" height="18" uuid="54f6d70c-9c04-4980-9151-f748ccd4a5d4">
<property name="com.jaspersoft.studio.unit.width" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="700" y="12" width="40" height="18" uuid="9fea4333-624c-4163-a2d1-c88b92815d46">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[頁數]]></text>
</staticText>
<textField>
<reportElement x="740" y="12" width="20" height="18" uuid="9a639fc7-4866-4b46-9ff2-e9f9dffb37e4">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="760" y="12" width="20" height="18" uuid="6685b6ed-fe0d-4669-8e3a-61cb60a141f0">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[/]]></text>
</staticText>
<line>
<reportElement x="0" y="90" width="800" height="1" uuid="07a0e89a-653f-4d81-bc4d-8d2b0d07131c">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
<line>
<reportElement x="0" y="179" width="799" height="1" uuid="ac02dc33-cb8d-4e70-8bcc-42285159d0bc">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
<line>
<reportElement x="0" y="175" width="799" height="1" uuid="b4baa70b-6211-49e6-95f4-218c624647e0">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
<staticText>
<reportElement x="0" y="35" width="90" height="23" uuid="89236d28-ff56-412a-9152-62bff0f29c11">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<text><![CDATA[報告日期:]]></text>
</staticText>
<textField>
<reportElement x="90" y="35" width="390" height="23" uuid="6b152aab-d180-47cc-892a-1038ac7a3650"/>
<textElement verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{reportDate}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="570" y="35" width="228" height="23" uuid="fa8aead3-618b-45fa-b535-46246fa0f415"/>
<textElement verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{reportTime}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="480" y="35" width="90" height="23" uuid="0b9c0ce6-b5a0-4c12-985a-e14eb7a59467">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<text><![CDATA[報告時間:]]></text>
</staticText>
<staticText>
<reportElement x="336" y="0" width="130" height="23" uuid="0102d5e8-f072-4701-abff-8f62a4dc8463">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Middle">
<font fontName="微軟正黑體" size="16" isBold="true"/>
</textElement>
<text><![CDATA[Item QC Report]]></text>
</staticText>
<textField>
<reportElement x="82" y="136" width="724" height="18" uuid="66d47923-ff26-4dab-8260-da717aeb8109">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$P{storeLocation}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="0" y="136" width="82" height="18" uuid="80b48eee-5ff0-4513-a867-87b5e8479c45">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[店鋪位置:]]></text>
</staticText>
<textField>
<reportElement x="82" y="100" width="724" height="18" uuid="a4e55fc5-bc8d-43a3-919d-8d83ac4790dc">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$P{stockSubCategory}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="0" y="100" width="82" height="18" uuid="6817c9dd-71ce-44b4-a06c-556c27b1ffbb">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[貨物子分類:]]></text>
</staticText>
<textField>
<reportElement x="82" y="118" width="724" height="18" uuid="4d757786-b0a4-4609-9e23-ff9717e3902c">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$P{balanceFilterStart}+"件"+ " ~ " + $P{balanceFilterEnd}+"件"]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="0" y="118" width="82" height="18" uuid="d35a0798-c969-4743-8bac-3155ee34c4e2">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[存量:]]></text>
</staticText>
<textField>
<reportElement x="462" y="154" width="336" height="18" uuid="8b71649c-52ab-40e6-bcd6-a46201d3906d">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$P{lastOutDateStart} + " 到 " + $P{lastOutDateEnd}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="380" y="154" width="82" height="18" uuid="f6ed3fa1-a0bc-4d79-b63b-2cfd7ec1790d">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[最後出倉日期:]]></text>
</staticText>
<staticText>
<reportElement x="0" y="154" width="82" height="18" uuid="b26146a6-0083-4e43-8466-e6e32e3e0120">
<property name="com.jaspersoft.studio.unit.y" value="px"/>
<property name="com.jaspersoft.studio.unit.height" value="px"/>
<property name="com.jaspersoft.studio.unit.width" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<text><![CDATA[最後入倉日期:]]></text>
</staticText>
<textField>
<reportElement x="82" y="154" width="298" height="18" uuid="9fa63848-5dd3-400f-ad19-0671365361c5">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體" size="12"/>
</textElement>
<textFieldExpression><![CDATA[$P{lastInDateStart} + " 到 " + $P{lastInDateEnd}]]></textFieldExpression>
</textField>
</band>
</pageHeader>
<detail>
<band height="17" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="70" height="17" uuid="20ded9b2-c04b-42d6-bc94-c95ce864ed65"/>
<textElement verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{lotNo}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="70" y="0" width="90" height="17" uuid="2f60426c-0d94-483f-8851-2b9d73b438e3"/>
<textElement textAlignment="Right" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{expiryDate}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="160" y="0" width="90" height="17" uuid="c738c90c-e341-420f-ac76-4ee2660b038f"/>
<textElement textAlignment="Center" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{qcType}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="250" y="0" width="90" height="17" uuid="6e149a04-1b03-4ac6-8c54-c15ae889365d"/>
<textElement textAlignment="Center" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{qcTemplate}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="340" y="0" width="130" height="17" uuid="e079b438-f9e4-443d-a3f3-c0805292292c"/>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{qcDefectCriteria}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="470" y="0" width="50" height="17" uuid="4abfba85-9590-4121-aeb3-724182614bea"/>
<textElement textAlignment="Right" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{lotQty}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="520" y="0" width="50" height="17" uuid="ffa7b57b-4036-40b7-a6b0-d5e217afbb3b"/>
<textElement textAlignment="Right" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{defectQty}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="570" y="0" width="60" height="17" uuid="9fb029a9-a16e-48d3-870e-d63af808faab"/>
<textElement textAlignment="Center" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{refData}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="630" y="0" width="90" height="17" uuid="af608ffa-d266-4855-a1e0-b7435621cb27"/>
<textElement textAlignment="Left" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{remark}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="720" y="0" width="80" height="17" uuid="a5e52468-0ed0-4dfb-a305-2873273101c0"/>
<textElement textAlignment="Right" verticalAlignment="Top">
<font fontName="微軟正黑體"/>
</textElement>
<textFieldExpression><![CDATA[$F{orderRefNo}]]></textFieldExpression>
</textField>
</band>
</detail>
</jasperReport>

Carregando…
Cancelar
Salvar