feat(report): JOR(jatools)报表引擎重宿主 — platform-report 后端 + /api/report 端点

EIP3 真报表=jatools JOR 套打模板(非 amis 表格)。本批次把报表引擎重宿主进 EIP4
(复用客户已持有的预编译引擎 jar,非移植 900 源文件;非重建引擎)。Phase 1 后端完成+真验。

- platform-report 模块:18 个预编译 jar(jatools 引擎 + 改造版 BeanShell + itext/jxl/
  jsqlparser/jfreechart/barcode4j/zxing/…)经项目内 local-repo(install-libs.sh)正常依赖,
  打进 fat jar(BOOT-INF/lib 已确认,非 system scope)。
- ReportService:走 jatools.engine.ReportJob(查询参数 setParameter→declareExternalVariables
  →SQL ${PARAM});headless(java.awt.headless)。三格式 HTML/PDF/XLS。
- JatoolsConfig:把 EIP4 spring.datasource 注入引擎 System2.properties(无 CWD 文件依赖)+
  注册 CJK 字体供 PDF。
- ReportController:GET /api/report/render/{templateId}?format=html|pdf|xls&<查询参数>;
  按 templateId 从 view_template(type=200)的 <reportfile> CDATA 取 JOR 渲染;?tpl= dev 覆盖。
- SecurityConfig:X-Frame-Options DENY→SAMEORIGIN(报表查看器同源 iframe 内嵌;生产 nginx 单源)。

真验:全 reactor mvn clean install 绿(0 失败);8093 端点 GET /api/report/render/{id} 三格式
HTTP 200(HTML 48K/PDF 106K/XLS 21K);查询参数 PROJECTID 流进 SQL 48×;浏览器内 amis 菜单页
(查询表单+iframe 查看器)渲染出 JOR 套打报表(在建工程项目收付款信息表,公式列/分组小计/签字栏)。

边界:Phase 2 前端「报表页 body 换查看器」当前以单页 sys_page_schema 运行态改动演示(非本提交代码);
铺到全部 339 张 type=200 报表页 = Phase 3(转换器侧生成查看器 body)。数据保真须对完整客户库验证
(eip4dev 为部分 dev 库,部分报表源表缺)。design 见 docs/plans/2026-06-25-报表迁移-JOR引擎重宿主-design.md。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-25 17:56:50 +08:00
parent 2ff826505f
commit 702b5e9229
100 changed files with 1181 additions and 0 deletions

View File

@@ -0,0 +1,4 @@
#NOTE: This is a Maven Resolver internal implementation file, its format can be changed without prior notice.
#Thu Jun 25 17:03:52 CST 2026
itext-eip3.jar>=
itext-eip3.pom>=

View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>com.dsasp.thirdparty</groupId>
<artifactId>itext</artifactId>
<version>eip3</version>
<description>POM was created from install:install-file</description>
</project>

View File

@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<groupId>com.dsasp.thirdparty</groupId>
<artifactId>itext</artifactId>
<versioning>
<release>eip3</release>
<versions>
<version>eip3</version>
</versions>
<lastUpdated>20260625090352</lastUpdated>
</versioning>
</metadata>