@agile-team/mach-report 2.21.1 → 2.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -2
- package/dist/{ExcelBindingWizard-Bu0LUlzl.cjs → ExcelBindingWizard-CW79I6Gl.cjs} +1 -1
- package/dist/{ExcelBindingWizard-mnAO2qOX.js → ExcelBindingWizard-CZyppD7I.js} +3 -3
- package/dist/{ParamEditor-38ZfNrPU.cjs → ParamEditor-CiYCJI0b.cjs} +1 -1
- package/dist/{ParamEditor-C8l0EC8m.js → ParamEditor-DQit-Gdf.js} +2 -2
- package/dist/{ReportBatchPanel-CfUVhvkO.js → ReportBatchPanel-DKTpV7MU.js} +2 -2
- package/dist/{ReportBatchPanel-nCC06Nfp.cjs → ReportBatchPanel-Db6TAfG5.cjs} +1 -1
- package/dist/ReportLabelStudio-B0i9ohQj.cjs +1 -0
- package/dist/ReportLabelStudio-BYnRqmje.js +780 -0
- package/dist/{ReportParamPanel-peB-KEmm.js → ReportParamPanel-BHSKVL8k.js} +231 -224
- package/dist/ReportParamPanel-lngONOEz.cjs +1 -0
- package/dist/ReportPreview-BDgKssYR.js +5887 -0
- package/dist/ReportPreview-Dw-4icG6.cjs +6 -0
- package/dist/{ReportTemplateLibrary-B5t_EcIs.js → ReportTemplateLibrary-BZuKn0YK.js} +1 -1
- package/dist/{ReportTemplateLibrary-DVlsf72p.cjs → ReportTemplateLibrary-DEXH07ND.cjs} +1 -1
- package/dist/{RuleEditor-kT1JsZ9f.js → RuleEditor-CIQn547x.js} +3 -3
- package/dist/{RuleEditor-xFkCVlii.cjs → RuleEditor-zSUmPjKa.cjs} +1 -1
- package/dist/{TemplateOutlinePanel-CDI6mfWx.cjs → TemplateOutlinePanel-B5SfGYVN.cjs} +1 -1
- package/dist/{TemplateOutlinePanel-BesgGR1P.js → TemplateOutlinePanel-D0PgOSQE.js} +2 -2
- package/dist/{TemplateReusePanel-BNFU6V-W.js → TemplateReusePanel-BKlAEF8-.js} +2 -2
- package/dist/{TemplateReusePanel-BG9Or5-P.cjs → TemplateReusePanel-DAy_Hwqz.cjs} +1 -1
- package/dist/TemplateReviewPanel-CowmHaQQ.cjs +1 -0
- package/dist/{TemplateReviewPanel-CwvwyCSs.js → TemplateReviewPanel-div-EH_m.js} +2 -2
- package/dist/artifact-integrity.json +76 -76
- package/dist/{auto-Tq7ReIC1.cjs → auto-DcUHlKob.cjs} +1 -1
- package/dist/{auto-BkdGiNtr.js → auto-moShblh1.js} +4 -4
- package/dist/{designer-HQi-03R6.js → designer-B7jJeAeG.js} +1500 -1455
- package/dist/{designer-DU3yDWgs.cjs → designer-BWQVpJeN.cjs} +2 -2
- package/dist/designer.cjs +1 -1
- package/dist/designer.d.cts +149 -2
- package/dist/designer.d.ts +149 -2
- package/dist/designer.js +13 -12
- package/dist/{encoding-BSeUwrN7.js → encoding-DbnhbwI8.js} +2 -2
- package/dist/{encoding-B79hW4zq.cjs → encoding-ncQAvyOv.cjs} +1 -1
- package/dist/index.cjs +5 -5
- package/dist/index.d.cts +38 -0
- package/dist/index.d.ts +38 -0
- package/dist/index.js +299 -279
- package/dist/{json-snapshot-Kgn459Oj.js → json-snapshot-DvQbZlD7.js} +2 -2
- package/dist/{json-snapshot-I5VI84Vp.cjs → json-snapshot-nyV63AbB.cjs} +1 -1
- package/dist/{plugin-BaRUGORD.cjs → plugin-AcAQ2m9X.cjs} +1 -1
- package/dist/{plugin-D4kAxfLG.js → plugin-w5Nyt08U.js} +1 -1
- package/dist/{prefill-CJSazcVY.js → prefill-BXBxx5We.js} +1 -1
- package/dist/{prefill-Bpyn58AZ.cjs → prefill-DUvejVt1.cjs} +1 -1
- package/dist/prepared-YXy-fVLw.cjs +1 -0
- package/dist/{prepared-BwjwEzFz.js → prepared-rXCKqdHY.js} +35 -34
- package/dist/{protocol-C8VWF9An.cjs → protocol-C9ZaylID.cjs} +1 -1
- package/dist/{protocol-Bs9-ohHN.js → protocol-fjaeKkjf.js} +3 -3
- package/dist/{region-binding-workflow-JNowHd0A.cjs → region-binding-workflow-BiJQ7NU6.cjs} +1 -1
- package/dist/{region-binding-workflow-Cy4GIOUo.js → region-binding-workflow-aA8nxmkZ.js} +1 -1
- package/dist/report-encoding-worker.cjs +1 -1
- package/dist/report-encoding-worker.js +1 -1
- package/dist/{runtime-BDf5x1i1.js → runtime-BTtpjF3D.js} +4 -4
- package/dist/{runtime-DsJt1PIf.cjs → runtime-Dq0LUsyS.cjs} +1 -1
- package/dist/sbom.cdx.json +1 -1
- package/dist/server/node.d.cts +9 -0
- package/dist/server/node.d.ts +9 -0
- package/dist/server-node.cjs +5 -4
- package/dist/server-node.js +1838 -1760
- package/dist/server.cjs +1 -1
- package/dist/server.d.cts +81 -0
- package/dist/server.d.ts +81 -0
- package/dist/server.js +6 -6
- package/dist/style.css +1 -1
- package/dist/template-catalog-CLAM4w7H.cjs +1 -0
- package/dist/{template-catalog-DFwIS9aN.js → template-catalog-JSxSqk5y.js} +3 -3
- package/dist/template-fragments-Ca25Jt7e.cjs +1 -0
- package/dist/{template-fragments-Dng-AlHk.js → template-fragments-D2JFj7Du.js} +18 -18
- package/dist/{template-outline-DiADphlq.js → template-outline-CDWXptuj.js} +1 -1
- package/dist/template-outline-K4jGhATu.cjs +1 -0
- package/dist/template-registry-CWnuGqyP.cjs +1 -0
- package/dist/{template-registry-DhBqoD7W.js → template-registry-Do1Uav2Z.js} +333 -261
- package/dist/template-serialization-CU4n_Miu.js +307 -0
- package/dist/template-serialization-CgqBo6s-.cjs +1 -0
- package/dist/vue/async.d.cts +97 -2
- package/dist/vue/async.d.ts +97 -2
- package/dist/vue/index.d.cts +197 -4
- package/dist/vue/index.d.ts +197 -4
- package/dist/vue-async.cjs +1 -1
- package/dist/vue-async.js +3 -3
- package/dist/vue.cjs +1 -1
- package/dist/vue.js +75 -70
- package/dist/{workbook-session-NYv01LHe.cjs → workbook-session-BvEBRRMz.cjs} +1 -1
- package/dist/{workbook-session-oinxX3qo.js → workbook-session-f0wVlzst.js} +1 -1
- package/dist/workbook-sheets-CaPAulQ6.cjs +2 -0
- package/dist/workbook-sheets-D4M7XXBh.js +44 -0
- package/dist/worker.cjs +1 -1
- package/dist/worker.d.cts +9 -0
- package/dist/worker.d.ts +9 -0
- package/dist/worker.js +4 -4
- package/dist/xlsx.cjs +4 -4
- package/dist/xlsx.d.cts +39 -2
- package/dist/xlsx.d.ts +39 -2
- package/dist/xlsx.js +290 -270
- package/package.json +1 -1
- package/dist/ReportLabelStudio-CaEvYuSK.cjs +0 -1
- package/dist/ReportLabelStudio-DQPBmh4v.js +0 -765
- package/dist/ReportParamPanel-CVpK8mFc.cjs +0 -1
- package/dist/ReportPreview-BBJNlu2U.js +0 -5740
- package/dist/ReportPreview-nf4Dk1Jc.cjs +0 -6
- package/dist/TemplateReviewPanel-BmBrjt6P.cjs +0 -1
- package/dist/prepared-BiSz_9vN.cjs +0 -1
- package/dist/template-bindings-Cg5oBLFT.cjs +0 -1
- package/dist/template-bindings-TKnXM7ll.js +0 -62
- package/dist/template-catalog-D_2jdnkL.cjs +0 -1
- package/dist/template-fragments-DZVUBhuB.cjs +0 -1
- package/dist/template-outline-DWkzZXVC.cjs +0 -1
- package/dist/template-registry-DpLUSLwF.cjs +0 -1
- package/dist/template-serialization-Cc3h-miv.js +0 -247
- package/dist/template-serialization-D1R5oAqh.cjs +0 -1
package/dist/vue.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { createReportSource as v, ReportCellEditError as A } from "@agile-team/mach-report";
|
|
2
2
|
export * from "@agile-team/mach-report";
|
|
3
|
-
import { P as R, c as h } from "./ReportPreview-
|
|
4
|
-
import { R as Z, a as Q, _ as ee, b as re, d as te, e as ne, f as oe, g as se, h as ae, i as ie, j as ce, k as
|
|
5
|
-
import { M as
|
|
6
|
-
import { D as
|
|
3
|
+
import { P as R, c as h } from "./ReportPreview-BDgKssYR.js";
|
|
4
|
+
import { R as Z, a as Q, _ as ee, b as re, d as te, e as ne, f as oe, g as se, h as ae, i as ie, j as ce, k as ue, l as fe, m as le, n as de, o as ge, p as pe, q as Pe, r as me, s as Ee, t as Re, u as he, v as we, w as ye } from "./ReportPreview-BDgKssYR.js";
|
|
5
|
+
import { M as f } from "./ReportParamPanel-BHSKVL8k.js";
|
|
6
|
+
import { D as Te, a as ve, b as Ae, c as xe, d as Ce, P as _e, R as Ie, S as Me, e as Oe, f as De, n as ke, p as Fe, g as Le, r as be, h as Ue, i as qe, s as je, t as Ge, j as Ne, u as He } from "./ReportParamPanel-BHSKVL8k.js";
|
|
7
7
|
import { M as x } from "./injection-keys-e85udZCp.js";
|
|
8
|
-
import { a as
|
|
9
|
-
import { M as
|
|
8
|
+
import { a as ze, b as Ve, c as Ye } from "./injection-keys-e85udZCp.js";
|
|
9
|
+
import { M as $e, m as Xe } from "./plugin-w5Nyt08U.js";
|
|
10
10
|
import { shallowRef as C, computed as _, inject as I } from "vue";
|
|
11
|
-
import { x as
|
|
12
|
-
import { a as
|
|
11
|
+
import { x as M } from "./json-snapshot-DvQbZlD7.js";
|
|
12
|
+
import { a as O } from "./progress-Hc2vxoCs.js";
|
|
13
13
|
function V(r) {
|
|
14
14
|
const e = v(r), o = async (t) => {
|
|
15
15
|
if (t.reportIds.length === 0) throw new R("缺少报表 ID");
|
|
@@ -37,6 +37,9 @@ function Y() {
|
|
|
37
37
|
get loading() {
|
|
38
38
|
return e().loading;
|
|
39
39
|
},
|
|
40
|
+
get stale() {
|
|
41
|
+
return e().stale ?? !1;
|
|
42
|
+
},
|
|
40
43
|
get hasPlan() {
|
|
41
44
|
return e().hasPlan;
|
|
42
45
|
},
|
|
@@ -106,7 +109,7 @@ function Y() {
|
|
|
106
109
|
});
|
|
107
110
|
function t() {
|
|
108
111
|
if (!r.value)
|
|
109
|
-
throw new
|
|
112
|
+
throw new f("config", "报表预览尚未挂载,请在 ready 后调用控制器");
|
|
110
113
|
return r.value;
|
|
111
114
|
}
|
|
112
115
|
return {
|
|
@@ -148,9 +151,9 @@ function Y() {
|
|
|
148
151
|
await t().setParams(n, s);
|
|
149
152
|
},
|
|
150
153
|
async importExcel(n, s) {
|
|
151
|
-
const
|
|
152
|
-
if (!
|
|
153
|
-
return
|
|
154
|
+
const l = t();
|
|
155
|
+
if (!l.importExcel) throw new f("config", "旧自定义控制器未提供 Excel 导入");
|
|
156
|
+
return l.importExcel(n, s);
|
|
154
157
|
},
|
|
155
158
|
getPlan() {
|
|
156
159
|
return t().getPlan?.() ?? null;
|
|
@@ -176,14 +179,14 @@ function P(r) {
|
|
|
176
179
|
return !!r && typeof r == "object" && !Array.isArray(r);
|
|
177
180
|
}
|
|
178
181
|
function k(r) {
|
|
179
|
-
return Array.isArray(r) && r.every((e) => P(e) && typeof e.code == "string" && typeof e.message == "string" && ["info", "warning", "error"].includes(e.severity) && (e.path === void 0 || typeof e.path == "string") &&
|
|
182
|
+
return Array.isArray(r) && r.every((e) => P(e) && typeof e.code == "string" && typeof e.message == "string" && ["info", "warning", "error"].includes(e.severity) && (e.path === void 0 || typeof e.path == "string") && M(e));
|
|
180
183
|
}
|
|
181
184
|
function F(r, e) {
|
|
182
185
|
return Array.isArray(r) && r.every((o) => P(o) && Number.isSafeInteger(o.editIndex) && o.editIndex >= 0 && o.editIndex < e && typeof o.code == "string" && typeof o.message == "string");
|
|
183
186
|
}
|
|
184
187
|
function L(r, e) {
|
|
185
188
|
let o;
|
|
186
|
-
if (!P(r) || typeof r.revision != "string" || !r.revision.trim() ? o = "非空 revision(请先在适配器解包业务响应)" : r.sourceToken !== void 0 && typeof r.sourceToken != "string" ? o = "字符串 sourceToken" : r.diagnostics !== void 0 && !k(r.diagnostics) ? o = "结构化 diagnostics" : r.conflicts !== void 0 && !F(r.conflicts, e) && (o = "有效 editIndex/code/message conflicts"), o) throw new
|
|
189
|
+
if (!P(r) || typeof r.revision != "string" || !r.revision.trim() ? o = "非空 revision(请先在适配器解包业务响应)" : r.sourceToken !== void 0 && typeof r.sourceToken != "string" ? o = "字符串 sourceToken" : r.diagnostics !== void 0 && !k(r.diagnostics) ? o = "结构化 diagnostics" : r.conflicts !== void 0 && !F(r.conflicts, e) && (o = "有效 editIndex/code/message conflicts"), o) throw new f("edit", `ReportProvider.save 必须返回${o};服务器可能已提交,请重新查询确认后再编辑`);
|
|
187
190
|
}
|
|
188
191
|
function w(r) {
|
|
189
192
|
return typeof r == "function" ? r() : r;
|
|
@@ -199,17 +202,17 @@ function U(r) {
|
|
|
199
202
|
return r.requestId ?? globalThis.crypto?.randomUUID?.() ?? `mr-${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`;
|
|
200
203
|
}
|
|
201
204
|
function $(r, e) {
|
|
202
|
-
if (!r.save) throw new
|
|
205
|
+
if (!r.save) throw new f("config", "ReportProvider.save 未配置,无法启用业务保存");
|
|
203
206
|
let o = "", t, n, s = 0;
|
|
204
|
-
function
|
|
205
|
-
a.conflicts?.length || i !== o ||
|
|
207
|
+
function l(a, i, d) {
|
|
208
|
+
a.conflicts?.length || i !== o || d !== s || (t = a.revision, n = a.sourceToken);
|
|
206
209
|
}
|
|
207
210
|
async function m(a, i) {
|
|
208
211
|
if (i.signal.aborted) throw i.signal.reason ?? new DOMException("Aborted", "AbortError");
|
|
209
|
-
const
|
|
212
|
+
const d = w(e.reportId), E = { ...w(e.params ?? {}) }, g = JSON.stringify([d, E]), S = ++s;
|
|
210
213
|
if (g !== o && (o = g, t = void 0, n = void 0), e.requireSource !== !1 && a.edits.some((c) => !c.source)) throw new A("missing");
|
|
211
|
-
const
|
|
212
|
-
reportId:
|
|
214
|
+
const u = await r.save({
|
|
215
|
+
reportId: d,
|
|
213
216
|
params: E,
|
|
214
217
|
signal: i.signal,
|
|
215
218
|
requestId: a.requestId,
|
|
@@ -219,11 +222,11 @@ function $(r, e) {
|
|
|
219
222
|
sourceToken: y(e.sourceToken, a.edits, "sourceToken", n)
|
|
220
223
|
});
|
|
221
224
|
if (i.signal.aborted) throw i.signal.reason ?? new DOMException("Aborted", "AbortError");
|
|
222
|
-
L(
|
|
223
|
-
const p =
|
|
224
|
-
if (p?.length) throw new
|
|
225
|
-
const T =
|
|
226
|
-
return
|
|
225
|
+
L(u, a.edits.length), u.diagnostics?.forEach((c) => O(() => e.onDiagnostic?.(c)));
|
|
226
|
+
const p = u.diagnostics?.filter((c) => c.severity === "error");
|
|
227
|
+
if (p?.length) throw new f("edit", p.map((c) => c.message).join(";"), { diagnostics: p });
|
|
228
|
+
const T = u.conflicts?.map((c) => ({ source: a.edits[c.editIndex]?.source, address: a.edits[c.editIndex]?.address, message: c.message }));
|
|
229
|
+
return l(u, g, S), { revision: u.revision, sourceToken: u.sourceToken, conflicts: T };
|
|
227
230
|
}
|
|
228
231
|
return {
|
|
229
232
|
requireSource: e.requireSource ?? !0,
|
|
@@ -234,58 +237,60 @@ function $(r, e) {
|
|
|
234
237
|
};
|
|
235
238
|
}
|
|
236
239
|
export {
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
240
|
+
Te as DEFAULT_CALCULATION_MESSAGES,
|
|
241
|
+
ve as DEFAULT_DATA_REVIEW_MESSAGES,
|
|
242
|
+
Ae as DEFAULT_MESSAGES,
|
|
243
|
+
xe as DEFAULT_PRINT_MESSAGES,
|
|
244
|
+
Ce as DEFAULT_THEME,
|
|
245
|
+
ze as MACH_REPORT_CONFIG_KEY,
|
|
243
246
|
x as MACH_REPORT_CONTROLLER_KEY,
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
247
|
+
Ve as MACH_REPORT_FETCHER_KEY,
|
|
248
|
+
Ye as MACH_REPORT_PDF_EXPORTER_KEY,
|
|
249
|
+
f as MachReportError,
|
|
250
|
+
$e as MachReportPreview,
|
|
251
|
+
_e as PARAM_OPTIONS_MESSAGES,
|
|
249
252
|
R as PlanLoadError,
|
|
250
253
|
Z as REPORT_EXPORT_FORMATS,
|
|
251
254
|
Q as REPORT_PREVIEW_TOOLS,
|
|
252
255
|
ee as ReportDataComparisonPanel,
|
|
253
|
-
re as
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
ne as
|
|
257
|
-
oe as
|
|
258
|
-
se as
|
|
259
|
-
ae as
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
256
|
+
re as ReportExportMenu,
|
|
257
|
+
te as ReportPagination,
|
|
258
|
+
Ie as ReportParamPanel,
|
|
259
|
+
ne as ReportPrefillPanel,
|
|
260
|
+
oe as ReportPreview,
|
|
261
|
+
se as ReportPrintResourceError,
|
|
262
|
+
ae as ReportTaskStatus,
|
|
263
|
+
ie as ReportToolbar,
|
|
264
|
+
ce as ReportValidationPanel,
|
|
265
|
+
Me as SILENT_LOGGER,
|
|
266
|
+
ue as buildPrintDocument,
|
|
267
|
+
fe as buildWordHtml,
|
|
268
|
+
le as createDefaultPdfExporter,
|
|
269
|
+
de as createFetchRequest,
|
|
265
270
|
V as createLocalFetcher,
|
|
266
|
-
|
|
271
|
+
ge as createPrintCalibrationPlan,
|
|
267
272
|
$ as createProviderEditing,
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
273
|
+
pe as createReportStoragePreferences,
|
|
274
|
+
Oe as defineMachReportConfig,
|
|
275
|
+
De as defineMachReportPreset,
|
|
276
|
+
Pe as joinReportIds,
|
|
277
|
+
Xe as machReportPlugin,
|
|
278
|
+
me as normalizeReportIds,
|
|
279
|
+
ke as normalizeReportLoadError,
|
|
280
|
+
Ee as preparePrintResources,
|
|
281
|
+
Fe as printCalibration,
|
|
282
|
+
Re as printPlans,
|
|
283
|
+
Le as provideMachReportConfig,
|
|
284
|
+
be as resolveCalculationMessages,
|
|
285
|
+
Ue as resolveConfig,
|
|
286
|
+
qe as resolveDataReviewMessages,
|
|
287
|
+
je as snapshotPrintOptions,
|
|
288
|
+
Ge as themeToCssVars,
|
|
289
|
+
Ne as toErrorDetail,
|
|
285
290
|
Y as useMachReport,
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
291
|
+
He as useMachReportConfig,
|
|
292
|
+
he as usePageWindow,
|
|
293
|
+
we as usePrintExport,
|
|
289
294
|
K as useReportPreview,
|
|
290
|
-
|
|
295
|
+
ye as useZoom
|
|
291
296
|
};
|