| | |
| | | * 产品检验单(纸质"××产品质量检验单"版式)Word 构建器 |
| | | * |
| | | * 版式:标题(公司 + 产品检验单)→ 表头信息 5 行 → 检验项目/检验结果 两列矩阵 → |
| | | * 判定结论/质检专用章(留空,打印后手填)→ 备注 → 检验/复核/批准签字行。 |
| | | * 判定结论(自动带出检验结果)/质检专用章(留空盖章)→ 备注 → 检验/复核/批准签字行。 |
| | | * 不含技术指标列;分组项不展示,录入项平铺;平行测量多值顿号合并。 |
| | | */ |
| | | public class MesQcProductReportWordBuilder { |
| | |
| | | writeTitle(doc, report); |
| | | writeHeaderTable(doc, report); |
| | | writeItemTable(doc, report); |
| | | writeConclusionTable(doc); |
| | | writeConclusionTable(doc, report); |
| | | writeRemarkTable(doc, report); |
| | | writeSignLine(doc); |
| | | doc.write(out); |
| | |
| | | .orElse(EMPTY); |
| | | } |
| | | |
| | | // ========== 判定结论 / 质检专用章(留空后填) ========== |
| | | // ========== 判定结论 / 质检专用章 ========== |
| | | |
| | | private static XWPFTable writeConclusionTable(XWPFDocument doc) { |
| | | /** 判定结论自动带出检验结果文案;质检专用章留空,打印后人工盖章 */ |
| | | private static XWPFTable writeConclusionTable(XWPFDocument doc, MesQcQcReportRespVO report) { |
| | | XWPFTable table = createTable(doc); |
| | | XWPFTableRow row = addRow(table, valueLeftSpan("判定结论:", 2), valueLeftSpan("质检专用章:", 2)); |
| | | // 预留手写/盖章高度 |
| | | String conclusion = notBlank(report.getCheckResultText()) ? report.getCheckResultText() : ""; |
| | | XWPFTableRow row = addRow(table, valueLeftSpan("判定结论:" + conclusion, 2), valueLeftSpan("质检专用章:", 2)); |
| | | // 预留盖章高度 |
| | | setRowHeight(row, 2550); |
| | | return table; |
| | | } |