@gct-paas/word 0.1.36 → 0.1.38
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/dist/base/select/src/basic-select.vue.d.ts +3 -0
- package/dist/core/command/commands/Backspace.d.ts +2 -0
- package/dist/core/data/DataManager.d.ts +19 -4
- package/dist/core/data/data-path-suffix.d.ts +7 -0
- package/dist/core/data/enricher-types.d.ts +6 -0
- package/dist/core/data/enrichers/build-field-enrichers.d.ts +6 -0
- package/dist/core/data/post-change-pipeline.d.ts +102 -0
- package/dist/core/layout/handlers/FieldHandler.d.ts +2 -0
- package/dist/core/layout/handlers/fields/index.d.ts +1 -0
- package/dist/core/layout/logic/LayoutBuilder.d.ts +4 -0
- package/dist/core/model/document/WrText.d.ts +4 -0
- package/dist/core/utils/expand.d.ts +10 -0
- package/dist/index.es.js +46240 -519
- package/dist/runtime/interface/render.d.ts +3 -0
- package/dist/sdk/doc-runtime/check-table/expand-runtime-json.d.ts +12 -0
- package/dist/sdk/doc-runtime/check-table/index.d.ts +4 -0
- package/dist/sdk/doc-runtime/check-table/map-check-table-item-infos.d.ts +14 -0
- package/dist/sdk/doc-runtime/check-table/resolve-check-table-item-infos.d.ts +5 -0
- package/dist/sdk/doc-runtime/check-table/types.d.ts +29 -0
- package/dist/sdk/doc-runtime/factories/document-initializer.d.ts +5 -0
- package/dist/sdk/doc-runtime/factories/useDocumentFactory.d.ts +2 -2
- package/dist/sdk/types/index.d.ts +2 -2
- package/dist/suites/edhr/check-table/check-table-dyn-value.d.ts +4 -0
- package/dist/suites/edhr/panel-schema/data-init/utils/sql.d.ts +2 -2
- package/dist/suites/edhr/paper-widget-manifest/basic/serialnumber-manifest.d.ts +1 -1
- package/dist/word.css +129 -109
- package/package.json +2 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { DocModeType } from '../../core';
|
|
1
2
|
import { DesignSuiteContext } from '../_register_/context/DesignSuiteContext';
|
|
2
3
|
import { FieldMeta } from '../../capabilities/model-field-runtime';
|
|
3
4
|
/**
|
|
@@ -26,6 +27,8 @@ export declare function getDefaultQueryIdsByFieldType(payload: {
|
|
|
26
27
|
export declare function loadDefaultValuesByFields(instances: any[], ctx: DesignSuiteContext, context: any, masterSlaveList: FieldMeta[]): Promise<Record<string, any>>;
|
|
27
28
|
/** 获取数据初始化数据 */
|
|
28
29
|
export declare const loadDataInitValues: (
|
|
30
|
+
/** 文档渲染模式 */
|
|
31
|
+
fillModeType: DocModeType,
|
|
29
32
|
/** 数据初始化配置 */
|
|
30
33
|
dataInitConfig: any,
|
|
31
34
|
/** 参数配置 */
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DocModel } from '../../../core/model';
|
|
2
|
+
import { CheckTableRegionRef, ExpandCheckTableRuntimeJsonOptions } from './types';
|
|
3
|
+
/** 扫描 runtimeJson 中所有检验表 region(用于对接「几条检验项」接口) */
|
|
4
|
+
export declare function listCheckTableRegionsInRuntimeJson(runtimeJson: unknown): CheckTableRegionRef[];
|
|
5
|
+
/**
|
|
6
|
+
* 按检验项条数扩运行态 runtimeJson
|
|
7
|
+
* - 只复制带 check-table subTable 的主体模板行;
|
|
8
|
+
* - 上下仅 subTableItem 的扩充行整体下移;
|
|
9
|
+
* - 拉长 itemRegion / 主体 region,并下移插入点以下的其它 region 行号。
|
|
10
|
+
*/
|
|
11
|
+
export declare function expandCheckTableRuntimeJson<T extends Record<string, unknown>>(runtimeJson: T, options: ExpandCheckTableRuntimeJsonOptions): T;
|
|
12
|
+
export declare function recalculateAllTablesInDocModel(docModel: DocModel): void;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { expandCheckTableRuntimeJson, listCheckTableRegionsInRuntimeJson, recalculateAllTablesInDocModel, } from './expand-runtime-json';
|
|
2
|
+
export { CHECK_TABLE_ROW_CONFIG_FIELDS, mergeCheckTableItemInfosIntoDefaults, readCheckTableRowConfigFromDefaults, resolveItemCountByRegionId, } from './map-check-table-item-infos';
|
|
3
|
+
export { resolveCheckTableItemInfos } from './resolve-check-table-item-infos';
|
|
4
|
+
export type { CheckTableItemInfosPayload, CheckTableRegionRef, ExpandCheckTableRuntimeJsonOptions, ResolveCheckTableItemInfosContext, } from './types';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CheckTableItemInfosPayload } from './types';
|
|
2
|
+
/** 从检验项详情推导每张检验表需要扩的主体行数 */
|
|
3
|
+
export declare function resolveItemCountByRegionId(runtimeJson: unknown, infos: CheckTableItemInfosPayload): Record<string, number>;
|
|
4
|
+
/**
|
|
5
|
+
* 将接口返回的检验项配置写入 defaults(展开为 $.f_jianyan1[0].type_ 等字段路径)。
|
|
6
|
+
* 仅 type_/show_type_/上下限等;不写入 rawData,避免覆盖 fetchRenderData 的业务数据。
|
|
7
|
+
*/
|
|
8
|
+
export declare function mergeCheckTableItemInfosIntoDefaults(defaultsMap: Record<string, unknown>, runtimeJson: unknown, infos: CheckTableItemInfosPayload, options?: {
|
|
9
|
+
layoutColumnCount?: number;
|
|
10
|
+
}): void;
|
|
11
|
+
/** 检验项行上参与动态组件的配置字段(defaults 按字段路径展开) */
|
|
12
|
+
export declare const CHECK_TABLE_ROW_CONFIG_FIELDS: readonly ["type_", "show_type_", "required_", "tip_text_", "options_", "pattern_", "max_int_", "min_int_", "min_decimal_", "max_decimal_", "validate_range_", "digits_", "regex_", "true_text_", "false_text_", "default_value_", "name_", "description_", "inspection_standard_", "__gw_y_uid"];
|
|
13
|
+
/** 从字段级 defaults 组装检验项行配置(供 readRowMeta) */
|
|
14
|
+
export declare function readCheckTableRowConfigFromDefaults(getDefault: (path: string) => unknown, rowMetaPath: string): Record<string, unknown>;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/** 运行态 JSON 中一张检验表区域的信息 */
|
|
2
|
+
export type CheckTableRegionRef = {
|
|
3
|
+
regionId: string;
|
|
4
|
+
valuePath: string;
|
|
5
|
+
/** 主体字段 key,如 f_jianyan1 */
|
|
6
|
+
subFieldKey: string;
|
|
7
|
+
/** 关联字段 key,如 f_jianyan2 */
|
|
8
|
+
linkFieldKey: string;
|
|
9
|
+
};
|
|
10
|
+
/** 接口返回的检验项列表 */
|
|
11
|
+
export type CheckTableItemInfosPayload = {
|
|
12
|
+
data: Record<string, unknown>[];
|
|
13
|
+
dict?: Record<string, unknown>;
|
|
14
|
+
};
|
|
15
|
+
export type ExpandCheckTableRuntimeJsonOptions = {
|
|
16
|
+
/**
|
|
17
|
+
* 检验项条数,key 为检验表 regionId。
|
|
18
|
+
* 条数 <= 1 时不扩行;已扩满时幂等跳过。
|
|
19
|
+
*/
|
|
20
|
+
itemCountByRegionId: Record<string, number>;
|
|
21
|
+
};
|
|
22
|
+
export type ResolveCheckTableItemInfosContext = {
|
|
23
|
+
instanceId: string;
|
|
24
|
+
runtimeJson: any;
|
|
25
|
+
mainModelKey: string;
|
|
26
|
+
materialNo?: string;
|
|
27
|
+
paramsConfig?: Record<string, unknown>;
|
|
28
|
+
requestInfo: Record<string, unknown>;
|
|
29
|
+
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Doc } from '../../../core';
|
|
2
2
|
import { DocInfo } from '../../types';
|
|
3
|
+
import { DocModel } from '../../../core/model';
|
|
3
4
|
import { IDocPayload, IDocProps, Execute } from './useDocumentFactory';
|
|
4
5
|
export interface InitializedDocument {
|
|
5
6
|
doc: Doc;
|
|
@@ -8,3 +9,7 @@ export interface InitializedDocument {
|
|
|
8
9
|
/** 从 Doc 实例提取响应式页面快照(与 layout 同步,供 docInfo ref 驱动 Vue) */
|
|
9
10
|
export declare function snapshotDocInfo(docInst?: Doc): DocInfo;
|
|
10
11
|
export declare function initializeDocumentEngine(props: IDocProps, payload: IDocPayload, result: Execute): Promise<InitializedDocument>;
|
|
12
|
+
/**
|
|
13
|
+
* 设计态导入 docx:替换模型并完成子模型 scope、设计默认值、交互与未保存基线等收尾。
|
|
14
|
+
*/
|
|
15
|
+
export declare function finalizeDesignModelImport(doc: Doc, docModel: DocModel): Promise<void>;
|
|
@@ -69,8 +69,8 @@ export interface DocumentFactory {
|
|
|
69
69
|
/** 手动触发文档重新加载(重新请求接口 + 重建引擎) */
|
|
70
70
|
reload(): void;
|
|
71
71
|
/**
|
|
72
|
-
*
|
|
73
|
-
*
|
|
72
|
+
* 重新请求实例/模板详情与填报数据,更新 dataManager,不重建引擎。
|
|
73
|
+
* 适用于保存后需要同步服务端最新实例状态与填报数据的场景。
|
|
74
74
|
*/
|
|
75
75
|
refreshData(): Promise<void>;
|
|
76
76
|
}
|
|
@@ -77,8 +77,8 @@ export interface DocControllerMethods extends DocOperations {
|
|
|
77
77
|
/** 手动触发文档重新加载 */
|
|
78
78
|
reload(): void;
|
|
79
79
|
/**
|
|
80
|
-
*
|
|
81
|
-
*
|
|
80
|
+
* 重新请求实例/模板详情与填报数据,更新 dataManager,不重建引擎。
|
|
81
|
+
* 适用于保存后需要同步服务端最新实例状态与填报数据的场景。
|
|
82
82
|
*/
|
|
83
83
|
refreshData(): Promise<void>;
|
|
84
84
|
/** 校验全量字段,返回错误映射;通过时返回 null */
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { HandlerContext } from '../../../core/layout/types';
|
|
2
|
+
export declare function isCheckTableCrossValueLayout(ctx: HandlerContext): boolean;
|
|
3
|
+
/** layout:克隆 wr 并写入动态 widgetMeta,valuePath 保持 value_ */
|
|
4
|
+
export declare function prepareDynLayoutWr(ctx: HandlerContext): HandlerContext;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { PaperWidgetManifest } from '../../../../capabilities/paper-widget-manifest';
|
|
2
|
-
export declare const manifest: PaperWidgetManifest
|
|
2
|
+
export declare const manifest: Omit<PaperWidgetManifest, 'renderers'>;
|