@gct-paas/word 0.2.43 → 0.2.44-beta.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 +25 -1
- package/dist/assets/svgs/table/index.d.ts +1 -0
- package/dist/base/input/src/input-number.vue.d.ts +1 -0
- package/dist/base/message/src/Message.vue.d.ts +2 -0
- package/dist/base/message/src/message.d.ts +2 -0
- package/dist/base/modal/src/ModalRoot.vue.d.ts +1 -1
- package/dist/base/modal/src/index.d.ts +2 -1
- package/dist/base/modal/src/modal.type.d.ts +3 -1
- package/dist/base/select/src/basic-select.vue.d.ts +16 -4
- package/dist/base/utils/image-size-util.d.ts +12 -6
- package/dist/capabilities/model-field-runtime/types/field.d.ts +4 -0
- package/dist/core/command/base/FloatingFieldCommand.d.ts +9 -0
- package/dist/core/command/commands/DeleteCol.d.ts +1 -1
- package/dist/core/command/commands/DeleteRow.d.ts +1 -1
- package/dist/core/command/commands/InsertFloatingField.d.ts +9 -0
- package/dist/core/command/commands/InsertTable.d.ts +0 -1
- package/dist/core/command/commands/MoveFloatingField.d.ts +10 -0
- package/dist/core/command/commands/RemoveFloatingField.d.ts +12 -0
- package/dist/core/command/types.d.ts +16 -0
- package/dist/core/data/DataManager.d.ts +6 -1
- package/dist/core/data/enrichers/inspection-module-qty-enricher.d.ts +19 -0
- package/dist/core/data/enrichers/udi-enricher.d.ts +23 -0
- package/dist/core/data/formula/business-functions.d.ts +10 -0
- package/dist/core/data/formula/formula-params-cache.d.ts +15 -0
- package/dist/core/data/types/runtime-config.d.ts +13 -0
- package/dist/core/event/handlers/IMEHandler.d.ts +1 -0
- package/dist/core/index.d.ts +2 -0
- package/dist/core/model/document/wtcRegionRef.d.ts +1 -1
- package/dist/core/model/logic/subtable/repeating/RepeatingRegion.d.ts +4 -1
- package/dist/core/model/logic/subtable/shared/dataGroupSlotCount.d.ts +37 -1
- package/dist/core/model/overlays/Wlayout.d.ts +4 -0
- package/dist/core/runtime/DocumentRuntimeManager.d.ts +38 -0
- package/dist/core/view/Doc.d.ts +5 -0
- package/dist/core/widget/types.d.ts +2 -2
- package/dist/domain/active/active-types.d.ts +3 -1
- package/dist/domain/document-business/business/product-release/profile.d.ts +2 -0
- package/dist/domain/document-business/business/product-release/service.d.ts +2 -0
- package/dist/domain/document-business/index.d.ts +2 -0
- package/dist/domain/document-business/registry.d.ts +2 -0
- package/dist/domain/document-business/runtime/field-query-runtime.d.ts +4 -0
- package/dist/domain/document-business/types.d.ts +24 -0
- package/dist/domain/document-rule/index.d.ts +3 -0
- package/dist/domain/document-rule/runtime/decision-rule-evaluator.d.ts +13 -0
- package/dist/domain/document-rule/runtime/document-rule-runtime.d.ts +19 -0
- package/dist/domain/document-rule/types.d.ts +50 -0
- package/dist/domain/field/field-props-schema-type.d.ts +1 -1
- package/dist/domain/field/field-type.d.ts +64 -0
- package/dist/domain/field/form-value.d.ts +6 -0
- package/dist/domain/field/query-filter.d.ts +15 -0
- package/dist/domain/field/seal/seal-binding.d.ts +19 -0
- package/dist/domain/field/seal/seal-display.d.ts +34 -0
- package/dist/domain/field/seal/seal-value.d.ts +39 -0
- package/dist/domain/table/business/device/maintenance/index.d.ts +1 -0
- package/dist/domain/table/business/device/maintenance/profile/field-keys.d.ts +9 -0
- package/dist/domain/table/business/device/maintenance/profile/fields.d.ts +2 -0
- package/dist/domain/table/business/device/maintenance/profile/index.d.ts +3 -0
- package/dist/domain/table/business/device/point-inspection/index.d.ts +1 -0
- package/dist/domain/table/business/device/point-inspection/profile/field-keys.d.ts +9 -0
- package/dist/domain/table/business/device/point-inspection/profile/fields.d.ts +2 -0
- package/dist/domain/table/business/device/point-inspection/profile/index.d.ts +3 -0
- package/dist/domain/table/business/device/runtime/device-signature-lock-engine.d.ts +13 -0
- package/dist/domain/table/business/device/signature-lock.d.ts +26 -0
- package/dist/domain/table/business/material/material-requisition/profile/field-keys.d.ts +1 -1
- package/dist/domain/table/business/material/material-substitution/actions/scan.d.ts +3 -0
- package/dist/domain/table/business/material/material-substitution/index.d.ts +3 -0
- package/dist/domain/table/business/material/material-substitution/profile/field-keys.d.ts +41 -0
- package/dist/domain/table/business/material/material-substitution/profile/fields.d.ts +2 -0
- package/dist/domain/table/business/material/material-substitution/profile/index.d.ts +4 -0
- package/dist/domain/table/business/material/material-substitution/runtime/register-handlers.d.ts +1 -0
- package/dist/domain/table/business/material/material-substitution/runtime/row-change-handlers.d.ts +6 -0
- package/dist/domain/table/business/material/material-substitution/runtime/scan-fill.d.ts +4 -0
- package/dist/domain/table/business/warehouse/warehouse-allocate/profile/field-keys.d.ts +1 -1
- package/dist/domain/table/business/warehouse/warehouse-inventory/profile/field-keys.d.ts +3 -1
- package/dist/domain/table/business/warehouse/warehouse-out/profile/field-keys.d.ts +1 -1
- package/dist/domain/table/design/hooks/on-bounded-default-props.d.ts +3 -0
- package/dist/domain/table/design/sub-model-matcher.d.ts +2 -0
- package/dist/domain/table/design/validate-nested-table-insert.d.ts +3 -0
- package/dist/domain/table/index.d.ts +3 -0
- package/dist/domain/table/registry.d.ts +1 -1
- package/dist/domain/table/runtime/option-fill-updates.d.ts +6 -0
- package/dist/domain/table/runtime/table-runtime.d.ts +3 -0
- package/dist/domain/table/types.d.ts +11 -4
- package/dist/index.es.js +41701 -6258
- package/dist/runtime/canvas/__common__/context-menu/resolve-table-context.d.ts +10 -0
- package/dist/runtime/canvas/node/seal-overlay.vue.d.ts +6 -0
- package/dist/runtime/canvas/table/render/material-consume/bom-validator.d.ts +3 -3
- package/dist/runtime/canvas/table/render/material-consume/material-consume-table-controller.d.ts +2 -2
- package/dist/runtime/canvas/table/render/material-consume/service.d.ts +5 -2
- package/dist/runtime/canvas/table/render/material-consume/uom-convert-runtime.d.ts +4 -2
- package/dist/runtime/interface/render.d.ts +2 -1
- package/dist/runtime/interface/sterilization-date.d.ts +9 -0
- package/dist/runtime/interface/validate-designer-default.d.ts +5 -0
- package/dist/runtime/renderer/dialogs/document-rule-prompt/document-rule-prompt.vue.d.ts +5 -0
- package/dist/runtime/renderer/dialogs/document-rule-prompt/open-document-rule-prompt.d.ts +2 -0
- package/dist/runtime/renderer/dialogs/seal/open-seal-flow.d.ts +3 -0
- package/dist/runtime/renderer/dialogs/seal/seal-api.d.ts +17 -0
- package/dist/runtime/renderer/dialogs/seal/seal-confirm-dialog.vue.d.ts +7 -0
- package/dist/runtime/renderer/dialogs/seal/seal-runtime.d.ts +30 -0
- package/dist/runtime/renderer/dialogs/seal/types.d.ts +17 -0
- package/dist/runtime/renderer/dialogs/seal/use-seal-confirm.d.ts +27 -0
- package/dist/runtime/renderer/dialogs/signature/authentication/signature-authentication.vue.d.ts +27 -0
- package/dist/runtime/renderer/dialogs/signature/authentication/types.d.ts +30 -0
- package/dist/runtime/renderer/dialogs/signature/authentication/useSignatureAuthentication.d.ts +29 -0
- package/dist/runtime/renderer/dialogs/signature/signature-dialog.vue.d.ts +54 -1
- package/dist/runtime/renderer/dialogs/upload-image/base-upload-image.vue.d.ts +1 -0
- package/dist/runtime/renderer/dialogs/upload-image/upload-image-dialog.vue.d.ts +1 -0
- package/dist/runtime/renderer/dropdowns/components/tables/columns/business/material-consume-history.d.ts +17 -0
- package/dist/runtime/renderer/dropdowns/components/tables/composables/useMaterialSubstitutionSource.d.ts +7 -0
- package/dist/runtime/validation/layout.d.ts +20 -0
- package/dist/runtime/validation/state.d.ts +7 -3
- package/dist/runtime/validation/useFormValidator.d.ts +4 -0
- package/dist/sdk/doc-runtime/composables/useDocumentRulePrompt.d.ts +3 -0
- package/dist/sdk/doc-runtime/factories/document-initializer.d.ts +1 -1
- package/dist/sdk/doc-runtime/factories/runtime-data-sources.d.ts +39 -0
- package/dist/sdk/doc-runtime/factories/useDocumentFactory.d.ts +5 -0
- package/dist/sdk/doc-runtime/factories/value-change-data-sources.d.ts +7 -0
- package/dist/sdk/doc-runtime/queries/template-placed-fields.d.ts +7 -0
- package/dist/sdk/engine/index.d.ts +3 -1
- package/dist/sdk/setup.d.ts +10 -2
- package/dist/sdk/types/index.d.ts +8 -0
- package/dist/sdk/types/placed-form-field.d.ts +6 -0
- package/dist/sdk/vue/index.d.ts +6 -0
- package/dist/suites/edhr/component/gct-seal-render.vue.d.ts +7 -0
- package/dist/suites/edhr/manifest/field/_common_/basic.d.ts +3 -3
- package/dist/suites/edhr/manifest/field/business/product-release-qty-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/business/udi-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/logic/seal-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/object-type/device-parameter-object-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/object-type/inspection-parameter-object-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/object-type/process-parameter-object-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/trace/inspection-container-manifest.d.ts +2 -0
- package/dist/suites/edhr/manifest/field/trace/sterilization-date-manifest.d.ts +2 -0
- package/dist/suites/edhr/panel-schema/data-init/material-consume-object/bom-validator.d.ts +6 -5
- package/dist/suites/edhr/panel-schema/index.d.ts +1 -0
- package/dist/suites/edhr/panel-schema/material-substitution-table/material-substitution-table.basic.d.ts +1 -0
- package/dist/suites/edhr/panel-schema/rule/components/add-rule-button.vue.d.ts +10 -3
- package/dist/suites/edhr/panel-schema/rule/components/decision-rule-condition.vue.d.ts +19 -0
- package/dist/suites/edhr/panel-schema/rule/components/decision-rule-group.vue.d.ts +16 -0
- package/dist/suites/edhr/panel-schema/rule/message-config/message-rule-modal.vue.d.ts +12 -0
- package/dist/suites/edhr/panel-schema/rule/message-config/message-rule.d.ts +22 -0
- package/dist/suites/edhr/panel-schema/rule/message-config/message-time-picker.vue.d.ts +18 -0
- package/dist/suites/edhr/panel-schema/rule/message-config/with-word-message-rule-fields.d.ts +5 -0
- package/dist/suites/edhr/panel-schema/rule/modals/inspection-decision-modal.vue.d.ts +11 -0
- package/dist/suites/edhr/panel-schema/rule/modals/open-inspection-decision-modal.d.ts +8 -0
- package/dist/suites/edhr/panel-schema/rule/types.d.ts +5 -0
- package/dist/suites/edhr/panel-schema/rule/use-rules-config.d.ts +22 -0
- package/dist/suites/edhr/panel-schema/rule/utils/decision-rule.d.ts +34 -0
- package/dist/suites/shared/panel/modules/field-formula-module/field-formula-module.vue.d.ts +1 -0
- package/dist/suites/shared/panel/utils/default-value-visibility.d.ts +3 -0
- package/dist/utils/adapters/ServiceUtil.d.ts +9 -0
- package/dist/utils/pdf/collect-seal-draw-ops.d.ts +4 -0
- package/dist/word.css +1497 -592
- package/package.json +4 -4
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
type TablePathNode = {
|
|
2
|
+
component?: string;
|
|
3
|
+
};
|
|
4
|
+
/** 布局路径按外到内排列,右键操作应定位命中位置所属的最内层表格。 */
|
|
5
|
+
export declare function resolveInnermostTableContext<T extends TablePathNode>(nodes: readonly (T | undefined)[]): {
|
|
6
|
+
table?: T;
|
|
7
|
+
tableRow?: T;
|
|
8
|
+
tableCell?: T;
|
|
9
|
+
};
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { OverlayLayout } from '../../../core';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
widget: OverlayLayout;
|
|
4
|
+
};
|
|
5
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
6
|
+
export default _default;
|
|
@@ -41,6 +41,7 @@ export declare class BomEntryValidator {
|
|
|
41
41
|
/** 历史数据中已经消耗的 */
|
|
42
42
|
private readonly historyQty;
|
|
43
43
|
get hasConsumed(): number;
|
|
44
|
+
private get historyQtyForValidation();
|
|
44
45
|
private get remainingQty();
|
|
45
46
|
/** 剩于可消耗数量 */
|
|
46
47
|
get remainingNum(): number;
|
|
@@ -114,9 +115,8 @@ export declare class BomEntryValidator {
|
|
|
114
115
|
* @return {*}
|
|
115
116
|
*/
|
|
116
117
|
calcQtyConsumed(arr: IMaterialConsumeData[], source?: ConsumeDataSource): BigNumber;
|
|
117
|
-
/**
|
|
118
|
-
|
|
119
|
-
private calcTotalForBounds;
|
|
118
|
+
/** 当前及历史数据按行取转换后数量,未转换的行使用上料数量。 */
|
|
119
|
+
private calcQtyForValidation;
|
|
120
120
|
calcRunningQtyConsumed(arr: IMaterialConsumeData[]): number;
|
|
121
121
|
/**
|
|
122
122
|
* 计算自定义的数量校验的最大值和最小值
|
package/dist/runtime/canvas/table/render/material-consume/material-consume-table-controller.d.ts
CHANGED
|
@@ -262,7 +262,7 @@ export declare class MaterialConsumeTableController {
|
|
|
262
262
|
/** 校验有效期 */
|
|
263
263
|
validateExpiration(row: IMaterialConsumeData): void;
|
|
264
264
|
/**
|
|
265
|
-
*
|
|
265
|
+
* 物料+批次查复检日期、有效期;缺任一参数不查;无日期放过;小于当天则 throw
|
|
266
266
|
*/
|
|
267
267
|
private validateReinspectionDate;
|
|
268
268
|
/**
|
|
@@ -277,7 +277,7 @@ export declare class MaterialConsumeTableController {
|
|
|
277
277
|
private applyUnitConversionForRows;
|
|
278
278
|
/**
|
|
279
279
|
* 提交前对所有有效行应用单位转换规则(兜底:Record 模式 / 非顺序投料无组切换)。
|
|
280
|
-
*
|
|
280
|
+
* 同时修正旧表单已保存的转换单位。
|
|
281
281
|
*/
|
|
282
282
|
private applyUnitConversionForAllRows;
|
|
283
283
|
/** 行级错误映射到 Word 的字段路径,供校验连线定位。 */
|
|
@@ -71,8 +71,11 @@ export declare function getReinspectionDate(params: {
|
|
|
71
71
|
product_id_: string;
|
|
72
72
|
material_no_?: string;
|
|
73
73
|
material_no_id_?: string;
|
|
74
|
-
}): Promise<
|
|
75
|
-
|
|
74
|
+
}): Promise<{
|
|
75
|
+
reInspectionDate?: string;
|
|
76
|
+
validateDate?: string;
|
|
77
|
+
}>;
|
|
78
|
+
/** 物料+批次查复检日期、有效期;缺任一参数不查;无日期放过;小于当天则 throw */
|
|
76
79
|
export declare function assertReinspectionDate(opts: {
|
|
77
80
|
product_id_?: string;
|
|
78
81
|
material_no_?: string;
|
|
@@ -23,9 +23,11 @@ interface ApplyUnitConversionOptions {
|
|
|
23
23
|
/** 当前物料消耗子表字段 key */
|
|
24
24
|
subFieldKey: string;
|
|
25
25
|
}
|
|
26
|
+
/** 兼容已保存的数字字符串,空值和无效结果交给上料数量兜底。 */
|
|
27
|
+
export declare function parseConvertedQty(value: unknown): number | undefined;
|
|
26
28
|
/**
|
|
27
|
-
*
|
|
28
|
-
* @returns
|
|
29
|
+
* 应用第一条匹配的规则,或修正已保存的转换单位。
|
|
30
|
+
* @returns 是否写回了转换结果字段
|
|
29
31
|
*/
|
|
30
32
|
export declare function applyUnitConversionRules(options: ApplyUnitConversionOptions): Promise<boolean>;
|
|
31
33
|
/** 从文档 config 读取单位转换规则列表 */
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { DocModeType } from '../../core';
|
|
2
2
|
import { DesignSuiteContext } from '../_register_/context/DesignSuiteContext';
|
|
3
3
|
import { FieldMeta } from '../../capabilities/model-field-runtime';
|
|
4
|
+
import { shouldInitializeDocumentData } from '../../core/data/initialization';
|
|
4
5
|
/** 获取默认值集合 */
|
|
5
|
-
export declare function loadDefaultValuesByFields(instances: any[], ctx: DesignSuiteContext, context: any, masterSlaveList: FieldMeta[]): Promise<Record<string, any>>;
|
|
6
|
+
export declare function loadDefaultValuesByFields(instances: any[], ctx: DesignSuiteContext, context: any, masterSlaveList: FieldMeta[], initialization?: Parameters<typeof shouldInitializeDocumentData>[0]): Promise<Record<string, any>>;
|
|
6
7
|
/** 获取数据初始化数据 */
|
|
7
8
|
export declare const loadDataInitValues: (
|
|
8
9
|
/** 文档渲染模式 */
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { FieldDataBindingMeta } from '../../core/widget';
|
|
2
|
+
type FieldInstance = {
|
|
3
|
+
widgetMeta?: {
|
|
4
|
+
field?: FieldDataBindingMeta;
|
|
5
|
+
};
|
|
6
|
+
};
|
|
7
|
+
/** 用 detail 返回的交易实例查询灭菌日期,首次加载时仅补齐主、子表字段的空值。 */
|
|
8
|
+
export declare function fillSterilizationDate(txnInstId: string | undefined, instances: FieldInstance[], rawData: Record<string, unknown>): Promise<void>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { FieldDataBindingMeta } from '../../core/widget';
|
|
2
|
+
import { FieldMeta } from '../../capabilities/model-field-runtime';
|
|
3
|
+
import { ApiRule } from '../../domain/field/field-props-schema-type';
|
|
4
|
+
/** 每次文档初始化独立去重;只检查设计默认值,不写 rawData 或模板配置。 */
|
|
5
|
+
export declare function createDesignerDefaultValidator(loadFieldByKey: (modelKey: string, key: string) => Promise<FieldMeta | undefined>): (field: FieldDataBindingMeta, rule: ApiRule, value: string) => Promise<boolean>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
message: string;
|
|
3
|
+
};
|
|
4
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
5
|
+
export default _default;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { api } from '../../../../utils/adapters/api';
|
|
2
|
+
export interface SealDetail {
|
|
3
|
+
id?: string;
|
|
4
|
+
name?: string;
|
|
5
|
+
code?: string;
|
|
6
|
+
sealImage?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const sealRequestConfig: NonNullable<Parameters<typeof api.platform.sealManagement.getInfo>[1]> & {
|
|
9
|
+
errorMessageMode: 'none';
|
|
10
|
+
};
|
|
11
|
+
export declare const getSealDetail: (id: string) => Promise<SealDetail>;
|
|
12
|
+
export declare const verifySealPassword: (request: {
|
|
13
|
+
id: string;
|
|
14
|
+
password: string;
|
|
15
|
+
}) => Promise<boolean>;
|
|
16
|
+
export declare const getSealUserTime: () => string;
|
|
17
|
+
export declare function isValidSealDetail(detail: SealDetail, id: string): boolean;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ConfirmResult, SealStepContext } from './types';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
context: SealStepContext;
|
|
4
|
+
onResult(result: ConfirmResult): void;
|
|
5
|
+
};
|
|
6
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
7
|
+
export default _default;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Doc } from '../../../../core/view/Doc';
|
|
2
|
+
import { SealFieldEntry } from '../../../../domain/field/seal/seal-binding';
|
|
3
|
+
import { SealPosition } from '../../../../domain/field/seal/seal-value';
|
|
4
|
+
export declare function sealPermissions(doc: Doc, entry: SealFieldEntry): {
|
|
5
|
+
canMove: boolean;
|
|
6
|
+
canStamp: boolean;
|
|
7
|
+
};
|
|
8
|
+
/** The flow belongs to the field, not to a layout component that is recreated after a move. */
|
|
9
|
+
export declare class SealRuntime {
|
|
10
|
+
private doc;
|
|
11
|
+
private initializeField?;
|
|
12
|
+
private pending;
|
|
13
|
+
private busy;
|
|
14
|
+
private disposed;
|
|
15
|
+
private epoch;
|
|
16
|
+
private off;
|
|
17
|
+
constructor(doc: Doc, initializeField?: ((field: SealFieldEntry["field"]) => void) | undefined);
|
|
18
|
+
onInit(): Promise<void>;
|
|
19
|
+
onHydrate(): void;
|
|
20
|
+
onFieldChanges(): void;
|
|
21
|
+
private prune;
|
|
22
|
+
private cancel;
|
|
23
|
+
destroy(): void;
|
|
24
|
+
private entry;
|
|
25
|
+
isBusy(id: string): boolean;
|
|
26
|
+
stamp(id: string): Promise<void>;
|
|
27
|
+
clear(id: string): void;
|
|
28
|
+
move(id: string, position: SealPosition): void;
|
|
29
|
+
}
|
|
30
|
+
export declare function getSealRuntime(doc: Doc, initializeField?: (field: SealFieldEntry['field']) => void): SealRuntime;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { SealStamp } from '../../../../domain/field/seal/seal-value';
|
|
2
|
+
export type SealUser = Pick<SealStamp, 'sealUserId' | 'sealUserName'>;
|
|
3
|
+
export interface SealFlowContext {
|
|
4
|
+
sealId: string;
|
|
5
|
+
getCurrentUser(): SealUser;
|
|
6
|
+
signal?: AbortSignal;
|
|
7
|
+
isActive(): boolean;
|
|
8
|
+
}
|
|
9
|
+
export interface SealStepContext extends SealFlowContext {
|
|
10
|
+
registerInvalidate(invalidate: () => void): void;
|
|
11
|
+
}
|
|
12
|
+
export type ConfirmResult = {
|
|
13
|
+
action: 'done';
|
|
14
|
+
stamp: SealStamp;
|
|
15
|
+
} | {
|
|
16
|
+
action: 'cancel';
|
|
17
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { SealStamp } from '../../../../domain/field/seal/seal-value';
|
|
2
|
+
import { SealDetail } from './seal-api';
|
|
3
|
+
import { SealUser } from './types';
|
|
4
|
+
export interface SealConfirmDependencies {
|
|
5
|
+
sealId: string;
|
|
6
|
+
getCurrentUser(): SealUser;
|
|
7
|
+
isActive(): boolean;
|
|
8
|
+
fetchDetail(id: string): Promise<SealDetail>;
|
|
9
|
+
verifyPassword(request: {
|
|
10
|
+
id: string;
|
|
11
|
+
password: string;
|
|
12
|
+
}): Promise<boolean>;
|
|
13
|
+
now(): string;
|
|
14
|
+
}
|
|
15
|
+
export declare function useSealConfirm(deps: SealConfirmDependencies): {
|
|
16
|
+
detail: import('vue').Ref<SealDetail | undefined, SealDetail | undefined>;
|
|
17
|
+
loading: import('vue').Ref<boolean, boolean>;
|
|
18
|
+
submitting: import('vue').Ref<boolean, boolean>;
|
|
19
|
+
password: import('vue').Ref<string, string>;
|
|
20
|
+
passwordStatus: import('vue').Ref<"idle" | "invalid" | "validating" | "valid", "idle" | "invalid" | "validating" | "valid">;
|
|
21
|
+
passwordError: import('vue').Ref<string, string>;
|
|
22
|
+
error: import('vue').Ref<string, string>;
|
|
23
|
+
loadDetail: () => Promise<void>;
|
|
24
|
+
validatePassword: () => Promise<boolean>;
|
|
25
|
+
confirm: () => Promise<SealStamp | undefined>;
|
|
26
|
+
dispose: () => void;
|
|
27
|
+
};
|
package/dist/runtime/renderer/dialogs/signature/authentication/signature-authentication.vue.d.ts
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { AuthenticationState } from './types';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
defaultLoginAccount?: string;
|
|
4
|
+
enableSignPassword?: number;
|
|
5
|
+
imageDirection?: string;
|
|
6
|
+
showForm?: boolean;
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
submitCard: (code: string) => Promise<void>;
|
|
9
|
+
};
|
|
10
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
11
|
+
authenticatePassword(): Promise<import('./types').AuthenticationAttempt | undefined>;
|
|
12
|
+
authenticateCard(code: string): Promise<import('./types').AuthenticationAttempt>;
|
|
13
|
+
hasInput(): boolean;
|
|
14
|
+
reset(): void;
|
|
15
|
+
invalidate(): void;
|
|
16
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
17
|
+
"state-change": (state: AuthenticationState) => any;
|
|
18
|
+
"card-complete": () => any;
|
|
19
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
20
|
+
"onState-change"?: ((state: AuthenticationState) => any) | undefined;
|
|
21
|
+
"onCard-complete"?: (() => any) | undefined;
|
|
22
|
+
}>, {
|
|
23
|
+
disabled: boolean;
|
|
24
|
+
enableSignPassword: number;
|
|
25
|
+
showForm: boolean;
|
|
26
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
27
|
+
export default _default;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { SignInfo } from '../logic';
|
|
2
|
+
export type AuthenticationMethod = 'PASSWORD' | 'CARD';
|
|
3
|
+
export type AuthenticationCardStatus = 'waiting' | 'success' | 'warning' | 'error';
|
|
4
|
+
export interface AuthenticationAttempt {
|
|
5
|
+
info: SignInfo;
|
|
6
|
+
/** Recheck after asynchronous business validation, before committing. */
|
|
7
|
+
isCurrent(): boolean;
|
|
8
|
+
}
|
|
9
|
+
export interface AuthenticationOptions {
|
|
10
|
+
defaultLoginAccount(): string | undefined;
|
|
11
|
+
enableSignPassword(): number;
|
|
12
|
+
imageDirection(): string | undefined;
|
|
13
|
+
isActive?: () => boolean;
|
|
14
|
+
}
|
|
15
|
+
export interface AuthenticationExpose {
|
|
16
|
+
authenticatePassword(): Promise<AuthenticationAttempt | undefined>;
|
|
17
|
+
authenticateCard(code: string): Promise<AuthenticationAttempt>;
|
|
18
|
+
hasInput(): boolean;
|
|
19
|
+
reset(): void;
|
|
20
|
+
invalidate(): void;
|
|
21
|
+
}
|
|
22
|
+
export interface AuthenticationState {
|
|
23
|
+
ready: boolean;
|
|
24
|
+
loading: boolean;
|
|
25
|
+
method: AuthenticationMethod | '';
|
|
26
|
+
cardStatus: AuthenticationCardStatus;
|
|
27
|
+
}
|
|
28
|
+
export declare class AuthenticationCancelled extends Error {
|
|
29
|
+
constructor();
|
|
30
|
+
}
|
package/dist/runtime/renderer/dialogs/signature/authentication/useSignatureAuthentication.d.ts
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { AuthenticationAttempt, AuthenticationMethod, AuthenticationOptions } from './types';
|
|
2
|
+
type Field = 'username' | 'password';
|
|
3
|
+
export declare function useSignatureAuthentication(options: AuthenticationOptions): {
|
|
4
|
+
formState: {
|
|
5
|
+
username?: string | undefined;
|
|
6
|
+
password?: string | undefined;
|
|
7
|
+
};
|
|
8
|
+
errors: {
|
|
9
|
+
password: string;
|
|
10
|
+
username: string;
|
|
11
|
+
};
|
|
12
|
+
methods: import('vue').ComputedRef<("CARD" | "PASSWORD")[]>;
|
|
13
|
+
signMethod: import('vue').Ref<"" | AuthenticationMethod, "" | AuthenticationMethod>;
|
|
14
|
+
signWay: import('vue').ComputedRef<{
|
|
15
|
+
label: string;
|
|
16
|
+
type: string;
|
|
17
|
+
}>;
|
|
18
|
+
configLoading: import('vue').Ref<boolean, boolean>;
|
|
19
|
+
configError: import('vue').Ref<string, string>;
|
|
20
|
+
busy: import('vue').Ref<boolean, boolean>;
|
|
21
|
+
ready: import('vue').ComputedRef<boolean>;
|
|
22
|
+
authenticatePassword: () => Promise<AuthenticationAttempt | undefined>;
|
|
23
|
+
authenticateCard: (code: string) => Promise<AuthenticationAttempt>;
|
|
24
|
+
validateField: (field: Field) => Promise<void>;
|
|
25
|
+
hasInput: () => boolean;
|
|
26
|
+
reset: () => void;
|
|
27
|
+
invalidate: () => void;
|
|
28
|
+
};
|
|
29
|
+
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ExternalComponentType } from '../../../../core/widget';
|
|
2
2
|
import { WidgetNode } from '../../../canvas/types';
|
|
3
|
+
import { AuthenticationState } from './authentication/types';
|
|
3
4
|
type __VLS_Props = {
|
|
4
5
|
widgetType: ExternalComponentType;
|
|
5
6
|
widget: WidgetNode;
|
|
@@ -19,5 +20,57 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
19
20
|
} | undefined>;
|
|
20
21
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
21
22
|
enableSignPassword: number;
|
|
22
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
23
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
24
|
+
authenticationRef: import('vue').CreateComponentPublicInstanceWithMixins<Readonly<{
|
|
25
|
+
defaultLoginAccount?: string;
|
|
26
|
+
enableSignPassword?: number;
|
|
27
|
+
imageDirection?: string;
|
|
28
|
+
showForm?: boolean;
|
|
29
|
+
disabled?: boolean;
|
|
30
|
+
submitCard: (code: string) => Promise<void>;
|
|
31
|
+
}> & Readonly<{
|
|
32
|
+
"onState-change"?: ((state: AuthenticationState) => any) | undefined;
|
|
33
|
+
"onCard-complete"?: (() => any) | undefined;
|
|
34
|
+
}>, {
|
|
35
|
+
authenticatePassword(): Promise<import('./authentication/types').AuthenticationAttempt | undefined>;
|
|
36
|
+
authenticateCard(code: string): Promise<import('./authentication/types').AuthenticationAttempt>;
|
|
37
|
+
hasInput(): boolean;
|
|
38
|
+
reset(): void;
|
|
39
|
+
invalidate(): void;
|
|
40
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
41
|
+
"state-change": (state: AuthenticationState) => any;
|
|
42
|
+
"card-complete": () => any;
|
|
43
|
+
}, import('vue').PublicProps, {
|
|
44
|
+
disabled: boolean;
|
|
45
|
+
enableSignPassword: number;
|
|
46
|
+
showForm: boolean;
|
|
47
|
+
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
|
|
48
|
+
P: {};
|
|
49
|
+
B: {};
|
|
50
|
+
D: {};
|
|
51
|
+
C: {};
|
|
52
|
+
M: {};
|
|
53
|
+
Defaults: {};
|
|
54
|
+
}, Readonly<{
|
|
55
|
+
defaultLoginAccount?: string;
|
|
56
|
+
enableSignPassword?: number;
|
|
57
|
+
imageDirection?: string;
|
|
58
|
+
showForm?: boolean;
|
|
59
|
+
disabled?: boolean;
|
|
60
|
+
submitCard: (code: string) => Promise<void>;
|
|
61
|
+
}> & Readonly<{
|
|
62
|
+
"onState-change"?: ((state: AuthenticationState) => any) | undefined;
|
|
63
|
+
"onCard-complete"?: (() => any) | undefined;
|
|
64
|
+
}>, {
|
|
65
|
+
authenticatePassword(): Promise<import('./authentication/types').AuthenticationAttempt | undefined>;
|
|
66
|
+
authenticateCard(code: string): Promise<import('./authentication/types').AuthenticationAttempt>;
|
|
67
|
+
hasInput(): boolean;
|
|
68
|
+
reset(): void;
|
|
69
|
+
invalidate(): void;
|
|
70
|
+
}, {}, {}, {}, {
|
|
71
|
+
disabled: boolean;
|
|
72
|
+
enableSignPassword: number;
|
|
73
|
+
showForm: boolean;
|
|
74
|
+
}> | null;
|
|
75
|
+
}, HTMLDivElement>;
|
|
23
76
|
export default _default;
|
|
@@ -15,6 +15,7 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
15
15
|
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
16
16
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
17
17
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
18
|
+
videoRef: HTMLVideoElement;
|
|
18
19
|
inputRef: HTMLInputElement;
|
|
19
20
|
}, HTMLDivElement>;
|
|
20
21
|
export default _default;
|
|
@@ -30,6 +30,7 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
30
30
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
31
31
|
"update:modelValue": (...args: any[]) => void;
|
|
32
32
|
}, import('vue').PublicProps, {}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {
|
|
33
|
+
videoRef: HTMLVideoElement;
|
|
33
34
|
inputRef: HTMLInputElement;
|
|
34
35
|
}, HTMLDivElement, import('vue').ComponentProvideOptions, {
|
|
35
36
|
P: {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare const materialConsumeHistoryColumns: ({
|
|
2
|
+
field: string;
|
|
3
|
+
type: string;
|
|
4
|
+
minWidth: number;
|
|
5
|
+
width: number;
|
|
6
|
+
showOverflow: boolean;
|
|
7
|
+
} | {
|
|
8
|
+
title: string;
|
|
9
|
+
field: string;
|
|
10
|
+
minWidth: number;
|
|
11
|
+
formatter: ({ row }: any) => unknown;
|
|
12
|
+
} | {
|
|
13
|
+
title: string;
|
|
14
|
+
field: string;
|
|
15
|
+
minWidth: number;
|
|
16
|
+
formatter?: undefined;
|
|
17
|
+
})[];
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { Doc } from '../../../../../../core';
|
|
3
|
+
/** 被替换物料仅按当前行生产批查询,未选择时阻断;仅允许 SN 查询历史消耗。 */
|
|
4
|
+
export declare function useMaterialSubstitutionSource(doc: Ref<Doc>, enabled: () => boolean, runtimeValuePath: () => string, fieldName: () => string | undefined): {
|
|
5
|
+
message: import('vue').ComputedRef<string>;
|
|
6
|
+
resolveQuery: () => Promise<Record<string, unknown> | null>;
|
|
7
|
+
};
|
|
@@ -9,6 +9,26 @@ export declare function buildWidgetPathIndex(doc: Doc): Map<string, any>;
|
|
|
9
9
|
export declare function listWidgetNodes(doc: Doc): WidgetLayoutEntry[];
|
|
10
10
|
/** 校验批注连线坐标:优先按 valuePath 存取,兼容旧版 modelId */
|
|
11
11
|
export declare function getValidationCommentPoints(widgetMeta: any, runtimeValuePath: string, modelId?: string): any;
|
|
12
|
+
/** Floating seals do not mount the inline field overlay that normally records these points. */
|
|
13
|
+
export declare function getSealValidationCommentPoints(doc: Doc, widget: any): {
|
|
14
|
+
fieldLeft?: undefined;
|
|
15
|
+
fieldTop?: undefined;
|
|
16
|
+
startX?: undefined;
|
|
17
|
+
startY?: undefined;
|
|
18
|
+
lineWidth?: undefined;
|
|
19
|
+
midX?: undefined;
|
|
20
|
+
midY?: undefined;
|
|
21
|
+
panelLeft?: undefined;
|
|
22
|
+
} | {
|
|
23
|
+
fieldLeft: number;
|
|
24
|
+
fieldTop: number;
|
|
25
|
+
startX: number;
|
|
26
|
+
startY: number;
|
|
27
|
+
lineWidth: number;
|
|
28
|
+
midX: number;
|
|
29
|
+
midY: number;
|
|
30
|
+
panelLeft: number;
|
|
31
|
+
};
|
|
12
32
|
/** 收集当前文档里所有可校验字段的 runtime valuePath */
|
|
13
33
|
export declare function listWidgetValuePaths(doc: Doc): string[];
|
|
14
34
|
/** 由 modelId 解析运行时 valuePath(优先布局 run,兼容子表行) */
|
|
@@ -6,7 +6,8 @@ export type ValidationCommentMap = Record<string, Array<{
|
|
|
6
6
|
}>> | null;
|
|
7
7
|
type ValidationSource = 'interactive' | 'manual' | 'business' | 'display';
|
|
8
8
|
export type ValidationRun = {
|
|
9
|
-
|
|
9
|
+
scopePaths?: ReadonlySet<string>;
|
|
10
|
+
isCurrent(source: ValidationSource, path?: string): boolean;
|
|
10
11
|
};
|
|
11
12
|
export type ValidationUpdate = Partial<Record<ValidationSource, ValidationCommentMap>> & {
|
|
12
13
|
validatedPaths?: string[];
|
|
@@ -16,8 +17,11 @@ export type ValidationUpdate = Partial<Record<ValidationSource, ValidationCommen
|
|
|
16
17
|
};
|
|
17
18
|
/** 等待 settle 的任务也属于当前会话,重置后不能重新创建旧结果。 */
|
|
18
19
|
export declare function captureValidationSession(doc: Doc): () => boolean;
|
|
19
|
-
/**
|
|
20
|
-
export declare function
|
|
20
|
+
/** 提交前扩展也属于提交请求;较早请求的裁决不能覆盖后发请求。 */
|
|
21
|
+
export declare function captureSubmissionValidation(doc: Doc, showComments: boolean): () => boolean;
|
|
22
|
+
export declare function listManualValidationPaths(doc: Doc): string[];
|
|
23
|
+
/** 按来源和字段范围控制异步写回,分别维护提交、实时、业务和展示结果。 */
|
|
24
|
+
export declare function beginValidationRun(doc: Doc, sources: ValidationSource[], scopePaths?: ReadonlySet<string>, isRequestCurrent?: () => boolean): ValidationRun;
|
|
21
25
|
/** 只更新本轮拥有的来源和实际执行规则的字段。 */
|
|
22
26
|
export declare function applyValidationResults(doc: Doc, run: ValidationRun, update: ValidationUpdate): ValidationCommentMap;
|
|
23
27
|
/** 数据变化清理旧业务快照,不取消业务校验自身写回数据后的在途结果。 */
|
|
@@ -12,6 +12,10 @@ export declare function disposeDocValidationScheduler(doc: Doc): void;
|
|
|
12
12
|
export declare const validateAllFields: (doc: Doc, options?: {
|
|
13
13
|
showComments?: boolean;
|
|
14
14
|
}) => Promise<Record<string, any[]> | null>;
|
|
15
|
+
/** 对指定运行时字段路径执行提交级完整校验。 */
|
|
16
|
+
export declare const validateFields: (doc: Doc, paths: Iterable<string>, options?: {
|
|
17
|
+
showComments?: boolean;
|
|
18
|
+
}) => Promise<Record<string, any[]> | null>;
|
|
15
19
|
type ValidateOptions = {
|
|
16
20
|
/** 调用方已 settle 时可跳过,避免打开时重复等待 */
|
|
17
21
|
settle?: boolean;
|
|
@@ -27,9 +27,9 @@ export interface DocumentFieldContext {
|
|
|
27
27
|
}
|
|
28
28
|
export declare function prepareDocumentFieldContext(options: PrepareFieldContextOptions): Promise<DocumentFieldContext>;
|
|
29
29
|
export interface PrepareRenderDataOptions {
|
|
30
|
+
fillModeType: DocModeType;
|
|
30
31
|
requestInfo: Execute['requestInfo'];
|
|
31
32
|
initializeValues?: boolean;
|
|
32
|
-
fillModeType: DocModeType;
|
|
33
33
|
payload: IDocPayload;
|
|
34
34
|
materialNo: string;
|
|
35
35
|
query: Record<string, any>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { Doc } from '../../../core';
|
|
2
|
+
import { DataSourceConfig, DataSourceManagerOptions } from '@gct-paas/form-base';
|
|
3
|
+
interface RuntimeDataSourceOptions {
|
|
4
|
+
doc: Doc;
|
|
5
|
+
canExecute: NonNullable<DataSourceManagerOptions['canExecute']>;
|
|
6
|
+
getContext: DataSourceManagerOptions['getContext'];
|
|
7
|
+
getInstanceId: DataSourceManagerOptions['getInstanceId'];
|
|
8
|
+
adapters?: DataSourceManagerOptions['adapters'];
|
|
9
|
+
}
|
|
10
|
+
/** 为单份 Word 文档绑定数源与字段填充;初始化和释放由文档生命周期调度。 */
|
|
11
|
+
export declare function createRuntimeDataSourceBinding(options: RuntimeDataSourceOptions): {
|
|
12
|
+
manager: {
|
|
13
|
+
getSources: () => DataSourceConfig[];
|
|
14
|
+
getContext: () => Record<string, unknown>;
|
|
15
|
+
canExecute: () => boolean;
|
|
16
|
+
reload: (key: string) => Promise<unknown>;
|
|
17
|
+
reloadAll: () => Promise<PromiseSettledResult<unknown>[]>;
|
|
18
|
+
states: {
|
|
19
|
+
readonly [x: string]: {
|
|
20
|
+
readonly status: import('@gct-paas/form-base').DataSourceQueryStatus;
|
|
21
|
+
readonly data?: Readonly<unknown> | undefined;
|
|
22
|
+
readonly clearTargets?: boolean | undefined;
|
|
23
|
+
readonly error?: string | undefined;
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
query: (key: string, parameters?: import('@gct-paas/form-base').DataSourceParameters, clearOnEmpty?: boolean) => Promise<unknown>;
|
|
27
|
+
cancel: (key: string) => boolean;
|
|
28
|
+
getResult(key: string): unknown;
|
|
29
|
+
initialize: () => Promise<PromiseSettledResult<unknown>[]>;
|
|
30
|
+
queryOnValueChange(keys: readonly string[], changeOptions?: {
|
|
31
|
+
cleared?: boolean;
|
|
32
|
+
}): Promise<PromiseSettledResult<unknown>[]>;
|
|
33
|
+
dispose(): void;
|
|
34
|
+
};
|
|
35
|
+
initialize(): Promise<void>;
|
|
36
|
+
refresh: () => void | undefined;
|
|
37
|
+
dispose(): void;
|
|
38
|
+
};
|
|
39
|
+
export {};
|
|
@@ -4,6 +4,7 @@ import { DocInfo, FieldPermissionInfo, IDeviceConfig } from '../../types';
|
|
|
4
4
|
import { DesignSuiteContext } from '../../../runtime/_register_/context/DesignSuiteContext';
|
|
5
5
|
import { OnlineFormInstanceResponse, OnlineFormTmplResponse } from '@gct-paas/api/apaas';
|
|
6
6
|
import { FormTmplBomController } from '../../../runtime/canvas/table/render/material-consume';
|
|
7
|
+
import { DataSourceManager, DataSourceManagerOptions } from '@gct-paas/form-base';
|
|
7
8
|
export interface IDocProps {
|
|
8
9
|
/** 文档实例id或者文档模板id */
|
|
9
10
|
requestId: MaybeRef<string | undefined>;
|
|
@@ -27,6 +28,8 @@ export interface IDocInstancePayload {
|
|
|
27
28
|
export interface IDocPayload extends IDocTemplatePayload, IDocInstancePayload {
|
|
28
29
|
/** 工厂类型 */
|
|
29
30
|
factoryType: 'template' | 'instance';
|
|
31
|
+
/** 表单、实体和业务等数源的宿主查询适配器。 */
|
|
32
|
+
dataSourceAdapters?: DataSourceManagerOptions['adapters'];
|
|
30
33
|
/** 模型 key */
|
|
31
34
|
modelKey?: ModelKey;
|
|
32
35
|
/** 设备配置信息 */
|
|
@@ -48,6 +51,8 @@ export interface IDocPayload extends IDocTemplatePayload, IDocInstancePayload {
|
|
|
48
51
|
}
|
|
49
52
|
/** 文档加载工厂 — 只负责响应式加载与生命周期,不包含业务操作 */
|
|
50
53
|
export interface DocumentFactory {
|
|
54
|
+
/** 当前填报实例的数源查询、状态与手动刷新入口。 */
|
|
55
|
+
dataSourceManager: ShallowRef<DataSourceManager | undefined>;
|
|
51
56
|
/** 文档引擎实例 */
|
|
52
57
|
docIns: ShallowRef<Doc | null>;
|
|
53
58
|
/** 文档页面信息(响应式,驱动 canvas 渲染) */
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Doc } from '../../../core';
|
|
2
|
+
import { DocumentRuntimeExtension } from '../../../core/runtime/DocumentRuntimeManager';
|
|
3
|
+
import { DataSourceManager } from '@gct-paas/form-base';
|
|
4
|
+
/** 初始化就绪时补查带值字段;后续只响应用户编辑,hydrate 不重复触发。 */
|
|
5
|
+
export declare function createValueChangeDataSourceRuntime(doc: Doc, manager: Pick<DataSourceManager, 'queryOnValueChange' | 'states'>, canExecute: () => boolean): DocumentRuntimeExtension & {
|
|
6
|
+
initialize: () => Promise<void>;
|
|
7
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { PlacedFormField } from '../../types/placed-form-field';
|
|
2
|
+
/** 从已保存的 Word 模板数据提取指定类型的拖入字段。 */
|
|
3
|
+
export declare function collectPlacedFieldsFromTemplateJson(runtimeJson: string | object | null | undefined, mainModelKey: string | undefined, fieldType: string): PlacedFormField[];
|
|
4
|
+
/** 按模板 ID 查询已保存 Word 表单中拖入的指定类型字段,无需调用 useWord。 */
|
|
5
|
+
export declare function getPlacedFieldsByType(fieldType: string, templateId: string): Promise<PlacedFormField[]>;
|
|
6
|
+
/** 按模板 ID 查询已保存 Word 表单中拖入的印章字段。 */
|
|
7
|
+
export declare function getPlacedSealFields(templateId: string): Promise<PlacedFormField[]>;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
export { DocModeTypeConst, PaperSizeConst, BuiltinComponentTypeConst } from '../../core';
|
|
6
6
|
export type { DocModeType, CompleteComponentType, BuiltinComponentType } from '../../core';
|
|
7
|
-
export type { DocController, DocQueryAPI, WordRuntime, DocInfo, DocRuntimeMeta, DocRuntimeMetaHandleInfo, DocUnsavedChanges, DocGetUnsavedChangesOptions, DesignerValidationError, DesignerValidationResult, DesignerValidationSource, UseWordProps, UseWordOptions, WordPrintCaptureOptions, FieldModelQuery, IDeviceConfig, } from '../types';
|
|
7
|
+
export type { DocController, DocQueryAPI, WordRuntime, DocInfo, DocRuntimeMeta, DocRuntimeMetaHandleInfo, DocUnsavedChanges, DocGetUnsavedChangesOptions, DesignerValidationError, DesignerValidationResult, DesignerValidationSource, UseWordProps, UseWordOptions, WordPrintCaptureOptions, FieldModelQuery, IDeviceConfig, PlacedFormField, } from '../types';
|
|
8
8
|
export type { Execute } from '../doc-runtime/factories/useDocumentFactory';
|
|
9
9
|
export { useWord } from '../doc-runtime/useWord';
|
|
10
10
|
export { useDocSuite } from '../doc-runtime/composables/useDocSuite';
|
|
@@ -12,6 +12,8 @@ export { useDocumentFactory } from '../doc-runtime/factories/useDocumentFactory'
|
|
|
12
12
|
export { useDocRuntimeProvider } from '../doc-runtime/composables/useDocRuntimeProvider';
|
|
13
13
|
export { useDocOperations } from '../doc-runtime/composables/useDocOperations';
|
|
14
14
|
export { useDocController } from '../doc-runtime/composables/useDocController';
|
|
15
|
+
export { getPlacedFieldsByType, getPlacedSealFields, } from '../doc-runtime/queries/template-placed-fields';
|
|
15
16
|
export { useFormTmplAndModelInit } from '../doc-runtime/device-link/useFormTmplAndModelInit';
|
|
16
17
|
export { calcUsedFieldsFromRuntimeJson, type CalcUsedFieldsFromRuntimeJsonOptions, type UsedFieldInfo, } from '../../utils/func/calc-used-fields';
|
|
17
18
|
export type { TableBorderPreset } from '../../core/model/types/table-border';
|
|
19
|
+
export { withWordMessageRuleFields } from '../../suites/edhr/panel-schema/rule/message-config/with-word-message-rule-fields';
|