@gct-paas/word 0.2.22 → 0.2.23-beta.1
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/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/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 +68 -2
- 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-consume/profile/fields.d.ts +2 -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 +4 -0
- package/dist/domain/table/business/material/types.d.ts +2 -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 +5 -2
- 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 +13 -3
- package/dist/index.es.js +31495 -9713
- 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 +10 -2
- package/dist/runtime/canvas/table/render/material-consume/material-consume-table-controller.d.ts +6 -0
- package/dist/runtime/interface/computed.d.ts +1 -1
- package/dist/runtime/interface/sterilization-date.d.ts +9 -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/useDocumentFactory.d.ts +5 -0
- package/dist/sdk/doc-runtime/queries/template-placed-fields.d.ts +7 -0
- package/dist/sdk/engine/index.d.ts +2 -1
- package/dist/sdk/setup.d.ts +6 -0
- 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/inspection-module-qty-manifest.d.ts +2 -0
- 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/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 +8 -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/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 +3 -0
- package/dist/suites/edhr/panel-schema/rule/use-rules-config.d.ts +12 -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 +1414 -1150
- package/package.json +4 -4
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { FieldQueryFilter } from '../../field/query-filter';
|
|
2
|
+
import { BusinessFieldQueryContext } from '../types';
|
|
3
|
+
/** 按业务场景与字段匹配规则;规则失败时保留原查询,失败结果不进入缓存。 */
|
|
4
|
+
export declare function resolveBusinessFieldFilters(context: BusinessFieldQueryContext): Promise<FieldQueryFilter[]>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FIELD_TYPE } from '../field/field-type';
|
|
2
|
+
import { FieldQueryFilter } from '../field/query-filter';
|
|
3
|
+
/** detail 业务类型、实例参数与当前查询字段;业务规则无需依赖 Doc 或组件。 */
|
|
4
|
+
export interface BusinessFieldQueryContext {
|
|
5
|
+
businessType?: string;
|
|
6
|
+
paramsConfig: Readonly<Record<string, unknown>>;
|
|
7
|
+
fieldType?: FIELD_TYPE;
|
|
8
|
+
}
|
|
9
|
+
export interface BusinessFieldQueryRule {
|
|
10
|
+
id: string;
|
|
11
|
+
match: {
|
|
12
|
+
fieldType: FIELD_TYPE;
|
|
13
|
+
};
|
|
14
|
+
/** 声明结果缓存的依赖参数,由 Runtime 统一执行缓存和请求去重。 */
|
|
15
|
+
cache?: {
|
|
16
|
+
key: (context: BusinessFieldQueryContext) => unknown;
|
|
17
|
+
ttlMs?: number;
|
|
18
|
+
};
|
|
19
|
+
resolveFilters: (context: BusinessFieldQueryContext) => Promise<readonly FieldQueryFilter[]>;
|
|
20
|
+
}
|
|
21
|
+
export interface DocumentBusinessProfile {
|
|
22
|
+
businessType: string;
|
|
23
|
+
fieldQueries: readonly BusinessFieldQueryRule[];
|
|
24
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DecisionRuleGroup, InspectionDecisionRule } from '../types';
|
|
2
|
+
type DataRow = Record<string, unknown>;
|
|
3
|
+
/** 安全解析设计端保存的规则树;无效或空配置不命中。 */
|
|
4
|
+
export declare function parseInspectionDecisionRuleTree(dataRuleConfig?: string): DecisionRuleGroup | null;
|
|
5
|
+
/**
|
|
6
|
+
* 计算规则树。
|
|
7
|
+
*
|
|
8
|
+
* 同一子表的多个条件绑定到同一条有效行;多个子表则按行组合判断。
|
|
9
|
+
* 子表为空时使用 undefined 占位,使 OR 中的主表条件仍可独立命中。
|
|
10
|
+
*/
|
|
11
|
+
export declare function evaluateDecisionRuleTree(root: DecisionRuleGroup, rawData: DataRow): boolean;
|
|
12
|
+
export declare function evaluateInspectionDecisionRule(rule: InspectionDecisionRule | null | undefined, rawData: DataRow): boolean;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Doc } from '../../../core/view/Doc';
|
|
2
|
+
import { DocumentRuntimeExtension, DocumentValidationContext, DocumentValidationDecision } from '../../../core/runtime/DocumentRuntimeManager';
|
|
3
|
+
import { FieldChangeMap } from '../../../core/data';
|
|
4
|
+
export declare const DOCUMENT_RULE_PROMPT_EVENT = "document-rule:prompt";
|
|
5
|
+
export interface DocumentRulePromptPayload {
|
|
6
|
+
rule: 'inspection-decision';
|
|
7
|
+
message: string;
|
|
8
|
+
}
|
|
9
|
+
/** 文档级规则运行时:统一处理状态迁移、提示事件及提交前裁决。 */
|
|
10
|
+
export declare class DocumentRuleRuntime implements DocumentRuntimeExtension {
|
|
11
|
+
private readonly doc;
|
|
12
|
+
private inspectionDecisionMatched;
|
|
13
|
+
constructor(doc: Doc);
|
|
14
|
+
/** 装载和整表换数只建立状态基线,不弹提示。 */
|
|
15
|
+
onHydrate(): void;
|
|
16
|
+
onFieldChanges(changedMap: FieldChangeMap): void;
|
|
17
|
+
beforeValidate(context: DocumentValidationContext): DocumentValidationDecision;
|
|
18
|
+
private evaluateInspectionDecision;
|
|
19
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export type DecisionRuleRelation = 'AND' | 'OR';
|
|
2
|
+
export type DecisionRuleValueType = 'FIXED' | 'FIELD';
|
|
3
|
+
/** 判定规则字段。保留所属模型/容器信息,供运行时准确取值。 */
|
|
4
|
+
export interface DecisionRuleField {
|
|
5
|
+
id: string;
|
|
6
|
+
key: string;
|
|
7
|
+
name: string;
|
|
8
|
+
type: string;
|
|
9
|
+
modelKey: string;
|
|
10
|
+
modelName?: string;
|
|
11
|
+
/** 主表 / 子表 / 对象字段 */
|
|
12
|
+
scope: 'main' | 'sub' | 'object';
|
|
13
|
+
subFieldKey?: string;
|
|
14
|
+
objectFieldKey?: string;
|
|
15
|
+
options?: Array<{
|
|
16
|
+
label: string;
|
|
17
|
+
value: string | number | boolean;
|
|
18
|
+
}>;
|
|
19
|
+
}
|
|
20
|
+
export interface DecisionRuleRightValue {
|
|
21
|
+
valueType: DecisionRuleValueType;
|
|
22
|
+
result?: string | number | boolean;
|
|
23
|
+
/** FIELD 类型右值的完整字段信息。 */
|
|
24
|
+
field?: DecisionRuleField;
|
|
25
|
+
}
|
|
26
|
+
export interface DecisionRuleCondition {
|
|
27
|
+
key: string;
|
|
28
|
+
pid: string;
|
|
29
|
+
level: number;
|
|
30
|
+
firstRow?: boolean;
|
|
31
|
+
class?: string;
|
|
32
|
+
leftValue?: DecisionRuleField;
|
|
33
|
+
operatorValue?: string;
|
|
34
|
+
rightValue?: DecisionRuleRightValue[];
|
|
35
|
+
}
|
|
36
|
+
export interface DecisionRuleGroup {
|
|
37
|
+
key: string;
|
|
38
|
+
pid: string;
|
|
39
|
+
level: number;
|
|
40
|
+
class?: string;
|
|
41
|
+
type: 'group';
|
|
42
|
+
operatorType: DecisionRuleRelation;
|
|
43
|
+
children: Array<DecisionRuleGroup | DecisionRuleCondition>;
|
|
44
|
+
}
|
|
45
|
+
export interface InspectionDecisionRule {
|
|
46
|
+
dataRuleEnabled: boolean;
|
|
47
|
+
dataRule: string;
|
|
48
|
+
dataRuleConfig: string;
|
|
49
|
+
prompt: string;
|
|
50
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** 字段配置-渲染组件标识 */
|
|
2
|
-
export type FieldPropsSchemaKey = 'schema:field-text' | 'schema:field-boolean' | 'schema:field-number' | 'schema:field-datetime' | 'schema:field-user' | 'schema:field-org' | 'schema:field-sign' | 'schema:field-enum' | 'schema:field-file' | 'schema:field-image' | 'schema:field-trace' | 'schema:field-business' | 'schema:field-ref' | 'schema:field-rdo-ref' | 'schema:field-e-sop-version';
|
|
2
|
+
export type FieldPropsSchemaKey = 'schema:field-seal' | 'schema:field-text' | 'schema:field-boolean' | 'schema:field-number' | 'schema:field-datetime' | 'schema:field-user' | 'schema:field-org' | 'schema:field-sign' | 'schema:field-enum' | 'schema:field-file' | 'schema:field-image' | 'schema:field-trace' | 'schema:field-business' | 'schema:field-ref' | 'schema:field-rdo-ref' | 'schema:field-e-sop-version';
|
|
3
3
|
/** 优先级规则 */
|
|
4
4
|
export interface PriorityRule {
|
|
5
5
|
type: 'priority';
|
|
@@ -218,6 +218,7 @@ export declare const BASE_FIELD_TYPE: {
|
|
|
218
218
|
export type BaseFieldType = (typeof BASE_FIELD_TYPE)[keyof typeof BASE_FIELD_TYPE];
|
|
219
219
|
/** 业务字段(基础类型上的业务身份)。后续重构前仍并入 FIELD_TYPE,当作一个字段用。 */
|
|
220
220
|
export declare const BUSINESS_FIELD_TYPE: {
|
|
221
|
+
readonly SEAL: "seal";
|
|
221
222
|
/**
|
|
222
223
|
* 关联批次
|
|
223
224
|
*/
|
|
@@ -326,14 +327,22 @@ export declare const BUSINESS_FIELD_TYPE: {
|
|
|
326
327
|
* 产品检验数量
|
|
327
328
|
*/
|
|
328
329
|
readonly PRODUCT_CHECK_QTY: "product_check_qty";
|
|
330
|
+
/**
|
|
331
|
+
* 放行数量
|
|
332
|
+
*/
|
|
333
|
+
readonly PRODUCT_RELEASE_QTY: "product_release_qty";
|
|
329
334
|
/**
|
|
330
335
|
* 材料检验数量
|
|
331
336
|
*/
|
|
332
337
|
readonly MATERIAL_CHECK_QTY: "material_check_qty";
|
|
333
338
|
/**
|
|
334
|
-
*
|
|
339
|
+
* 送检数量
|
|
335
340
|
*/
|
|
336
341
|
readonly INSPECTION_QTY: "inspection_qty";
|
|
342
|
+
/**
|
|
343
|
+
* 检验数量
|
|
344
|
+
*/
|
|
345
|
+
readonly INSPECTION_MODULE_QTY: "inspection_module_qty";
|
|
337
346
|
/**
|
|
338
347
|
* 工序接收数量
|
|
339
348
|
*/
|
|
@@ -386,6 +395,18 @@ export declare const BUSINESS_FIELD_TYPE: {
|
|
|
386
395
|
* 物料日期对象
|
|
387
396
|
*/
|
|
388
397
|
readonly DATE_OBJECT: "date_object";
|
|
398
|
+
/**
|
|
399
|
+
* 检验参数对象
|
|
400
|
+
*/
|
|
401
|
+
readonly INSPECTION_PARAMETER_OBJECT: "inspection_parameter_object";
|
|
402
|
+
/**
|
|
403
|
+
* 工艺参数对象
|
|
404
|
+
*/
|
|
405
|
+
readonly PROCESS_PARAMETER_OBJECT: "process_parameter_object";
|
|
406
|
+
/**
|
|
407
|
+
* 设备参数对象
|
|
408
|
+
*/
|
|
409
|
+
readonly DEVICE_PARAMETER_OBJECT: "device_parameter_object";
|
|
389
410
|
/**
|
|
390
411
|
* 有效期
|
|
391
412
|
*/
|
|
@@ -418,6 +439,10 @@ export declare const BUSINESS_FIELD_TYPE: {
|
|
|
418
439
|
* 表单实例数
|
|
419
440
|
*/
|
|
420
441
|
readonly OF_INST_NUM: "of_inst_num";
|
|
442
|
+
/**
|
|
443
|
+
* 医疗器械唯一标识
|
|
444
|
+
*/
|
|
445
|
+
readonly UDI: "udi";
|
|
421
446
|
/**
|
|
422
447
|
* 生产数量
|
|
423
448
|
*/
|
|
@@ -434,10 +459,19 @@ export declare const BUSINESS_FIELD_TYPE: {
|
|
|
434
459
|
* 灭菌批(追溯)
|
|
435
460
|
*/
|
|
436
461
|
readonly STERILIZATION_CONTAINER: "sterilization_container";
|
|
462
|
+
/**
|
|
463
|
+
* 检验批
|
|
464
|
+
*/
|
|
465
|
+
readonly INSPECTION_CONTAINER: "inspection_container";
|
|
466
|
+
/**
|
|
467
|
+
* 灭菌日期
|
|
468
|
+
*/
|
|
469
|
+
readonly STERILIZATION_DATE: "sterilization_date";
|
|
437
470
|
};
|
|
438
471
|
export type BusinessFieldType = (typeof BUSINESS_FIELD_TYPE)[keyof typeof BUSINESS_FIELD_TYPE];
|
|
439
472
|
/** 字段类型 = 基础 + 业务 */
|
|
440
473
|
export declare const FIELD_TYPE: {
|
|
474
|
+
readonly SEAL: "seal";
|
|
441
475
|
/**
|
|
442
476
|
* 关联批次
|
|
443
477
|
*/
|
|
@@ -546,14 +580,22 @@ export declare const FIELD_TYPE: {
|
|
|
546
580
|
* 产品检验数量
|
|
547
581
|
*/
|
|
548
582
|
readonly PRODUCT_CHECK_QTY: "product_check_qty";
|
|
583
|
+
/**
|
|
584
|
+
* 放行数量
|
|
585
|
+
*/
|
|
586
|
+
readonly PRODUCT_RELEASE_QTY: "product_release_qty";
|
|
549
587
|
/**
|
|
550
588
|
* 材料检验数量
|
|
551
589
|
*/
|
|
552
590
|
readonly MATERIAL_CHECK_QTY: "material_check_qty";
|
|
553
591
|
/**
|
|
554
|
-
*
|
|
592
|
+
* 送检数量
|
|
555
593
|
*/
|
|
556
594
|
readonly INSPECTION_QTY: "inspection_qty";
|
|
595
|
+
/**
|
|
596
|
+
* 检验数量
|
|
597
|
+
*/
|
|
598
|
+
readonly INSPECTION_MODULE_QTY: "inspection_module_qty";
|
|
557
599
|
/**
|
|
558
600
|
* 工序接收数量
|
|
559
601
|
*/
|
|
@@ -606,6 +648,18 @@ export declare const FIELD_TYPE: {
|
|
|
606
648
|
* 物料日期对象
|
|
607
649
|
*/
|
|
608
650
|
readonly DATE_OBJECT: "date_object";
|
|
651
|
+
/**
|
|
652
|
+
* 检验参数对象
|
|
653
|
+
*/
|
|
654
|
+
readonly INSPECTION_PARAMETER_OBJECT: "inspection_parameter_object";
|
|
655
|
+
/**
|
|
656
|
+
* 工艺参数对象
|
|
657
|
+
*/
|
|
658
|
+
readonly PROCESS_PARAMETER_OBJECT: "process_parameter_object";
|
|
659
|
+
/**
|
|
660
|
+
* 设备参数对象
|
|
661
|
+
*/
|
|
662
|
+
readonly DEVICE_PARAMETER_OBJECT: "device_parameter_object";
|
|
609
663
|
/**
|
|
610
664
|
* 有效期
|
|
611
665
|
*/
|
|
@@ -638,6 +692,10 @@ export declare const FIELD_TYPE: {
|
|
|
638
692
|
* 表单实例数
|
|
639
693
|
*/
|
|
640
694
|
readonly OF_INST_NUM: "of_inst_num";
|
|
695
|
+
/**
|
|
696
|
+
* 医疗器械唯一标识
|
|
697
|
+
*/
|
|
698
|
+
readonly UDI: "udi";
|
|
641
699
|
/**
|
|
642
700
|
* 生产数量
|
|
643
701
|
*/
|
|
@@ -654,6 +712,14 @@ export declare const FIELD_TYPE: {
|
|
|
654
712
|
* 灭菌批(追溯)
|
|
655
713
|
*/
|
|
656
714
|
readonly STERILIZATION_CONTAINER: "sterilization_container";
|
|
715
|
+
/**
|
|
716
|
+
* 检验批
|
|
717
|
+
*/
|
|
718
|
+
readonly INSPECTION_CONTAINER: "inspection_container";
|
|
719
|
+
/**
|
|
720
|
+
* 灭菌日期
|
|
721
|
+
*/
|
|
722
|
+
readonly STERILIZATION_DATE: "sterilization_date";
|
|
657
723
|
/**
|
|
658
724
|
* 文本
|
|
659
725
|
*/
|
|
@@ -80,6 +80,12 @@ type NormalizeNumberTextResult = {
|
|
|
80
80
|
* - fw:number 根据 digits 执行整数化或小数截断
|
|
81
81
|
*/
|
|
82
82
|
export declare function normalizeNumberTextOnCommit(rawText: string, options: NormalizeNumberTextOptions): NormalizeNumberTextResult;
|
|
83
|
+
/** 配置检查:返回错误说明,不抛异常。 */
|
|
84
|
+
export declare function getNumberInputConfigError(fieldType: FIELD_TYPE | undefined, digits: unknown): string | null;
|
|
85
|
+
/** 填报失焦时处理数字长度和整数上限。 */
|
|
86
|
+
export declare function normalizeNumberInputOnBlur(rawText: string, options: NormalizeNumberTextOptions, fieldType?: FIELD_TYPE): NormalizeNumberTextResult & {
|
|
87
|
+
configError?: string;
|
|
88
|
+
};
|
|
83
89
|
export declare function buildNumberFormats(props: any, type: NumberFieldType): {
|
|
84
90
|
type: NumberFieldType;
|
|
85
91
|
digits: number | undefined;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** 下拉接口使用的查询结构,与渲染组件解耦。 */
|
|
2
|
+
export interface FieldQuery {
|
|
3
|
+
queryData?: Record<string, unknown>;
|
|
4
|
+
exp?: string;
|
|
5
|
+
}
|
|
6
|
+
/** 业务规则提供的附加条件;空 values 明确表示无候选,空条件列表表示不追加过滤。 */
|
|
7
|
+
export interface FieldQueryFilter {
|
|
8
|
+
field: string;
|
|
9
|
+
operator: 'in';
|
|
10
|
+
values: readonly string[];
|
|
11
|
+
}
|
|
12
|
+
/** 空 in 可能被接口视为不筛选,使用占位值表达无候选。 */
|
|
13
|
+
export declare const EMPTY_QUERY_VALUE = "__word_no_matching_query_value__";
|
|
14
|
+
/** 附加条件统一按 AND 合并;同字段 IN 条件取交集,保留已有搜索表达式。 */
|
|
15
|
+
export declare function mergeQueryFilters(query: FieldQuery, filters: readonly FieldQueryFilter[]): FieldQuery;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { DocModel } from '../../../core/model/DocModel';
|
|
2
|
+
import { Doc } from '../../../core/view/Doc';
|
|
3
|
+
import { Page } from '../../../core/view/Page';
|
|
4
|
+
import { WrField } from '../../../core/model/document';
|
|
5
|
+
import { Wlayout } from '../../../core/model/overlays/Wlayout';
|
|
6
|
+
import { WidgetMeta } from '../../../core/widget/types';
|
|
7
|
+
import { SealPosition } from './seal-value';
|
|
8
|
+
export declare function isMainSealBinding(meta: WidgetMeta, mainModelKey: string): boolean;
|
|
9
|
+
export declare function listSealFields(model?: DocModel): {
|
|
10
|
+
overlay: import('../../../core/model/overlays/Woverlay').Woverlay;
|
|
11
|
+
layout: Wlayout;
|
|
12
|
+
field: WrField;
|
|
13
|
+
}[];
|
|
14
|
+
export type SealFieldEntry = ReturnType<typeof listSealFields>[number];
|
|
15
|
+
export declare function getSealTemplatePosition({ overlay, layout }: SealFieldEntry): SealPosition;
|
|
16
|
+
export declare function getSealInstancePosition(doc: Doc, entry: SealFieldEntry): SealPosition;
|
|
17
|
+
export declare function findSealPage(pages: Page[], position: SealPosition): Page | undefined;
|
|
18
|
+
export declare function getSealPagePosition(doc: Doc, page: Page, x: number, y: number): SealPosition;
|
|
19
|
+
export declare function initializeDocumentSeals(doc: Doc): void;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { Doc } from '../../../core/view/Doc';
|
|
2
|
+
import { ImageWidget } from '../../../core/view/runs/ImageWidget';
|
|
3
|
+
export declare function resolveSealDisplay(doc: Doc, widget: ImageWidget): {
|
|
4
|
+
stamped: boolean;
|
|
5
|
+
visible: boolean;
|
|
6
|
+
hasError: boolean;
|
|
7
|
+
emptySymbol: string;
|
|
8
|
+
readonlyEmpty: boolean;
|
|
9
|
+
showEmptySymbol: boolean;
|
|
10
|
+
placeholder: string;
|
|
11
|
+
requiredBorder: boolean | undefined;
|
|
12
|
+
state: undefined;
|
|
13
|
+
disabled: boolean;
|
|
14
|
+
isReadonly: boolean;
|
|
15
|
+
blocked: boolean;
|
|
16
|
+
} | {
|
|
17
|
+
stamped: boolean;
|
|
18
|
+
visible: boolean;
|
|
19
|
+
hasError: boolean;
|
|
20
|
+
emptySymbol: string;
|
|
21
|
+
readonlyEmpty: boolean;
|
|
22
|
+
showEmptySymbol: boolean;
|
|
23
|
+
placeholder: string;
|
|
24
|
+
requiredBorder: boolean | undefined;
|
|
25
|
+
state: {
|
|
26
|
+
required: boolean;
|
|
27
|
+
readonly: boolean;
|
|
28
|
+
disabled: boolean;
|
|
29
|
+
displayStatus: import('../../../core/widget/state').WidgetDisplayStatus;
|
|
30
|
+
};
|
|
31
|
+
disabled: boolean;
|
|
32
|
+
isReadonly: boolean;
|
|
33
|
+
blocked: boolean;
|
|
34
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export interface SealPosition {
|
|
2
|
+
sheetId: string;
|
|
3
|
+
pageIndex: number;
|
|
4
|
+
leftMm: number;
|
|
5
|
+
topMm: number;
|
|
6
|
+
}
|
|
7
|
+
export interface SealStamp {
|
|
8
|
+
sealId: string;
|
|
9
|
+
sealName: string;
|
|
10
|
+
sealType: string;
|
|
11
|
+
sealImage: string;
|
|
12
|
+
sealUserId: string;
|
|
13
|
+
sealUserName: string;
|
|
14
|
+
sealUserTime: string;
|
|
15
|
+
}
|
|
16
|
+
export interface SealFieldValue extends SealStamp {
|
|
17
|
+
sealPosition: SealPosition;
|
|
18
|
+
}
|
|
19
|
+
export declare function parseSealValue(raw: unknown): Record<string, unknown> | undefined;
|
|
20
|
+
export declare function isSealPosition(value: unknown): value is SealPosition;
|
|
21
|
+
/** Position is instance metadata, not evidence that the field has been filled. */
|
|
22
|
+
export declare function classifySealValue(raw: unknown): 'empty' | 'stamped' | 'invalid';
|
|
23
|
+
export declare const isSealStamped: (raw: unknown) => boolean;
|
|
24
|
+
export declare function readSealValue(raw: unknown, fallback: SealPosition): SealFieldValue;
|
|
25
|
+
export declare function stampSealValue(raw: unknown, fallback: SealPosition, stamp: SealStamp): string;
|
|
26
|
+
export declare function clearSealValue(raw: unknown, fallback: SealPosition): string;
|
|
27
|
+
export declare function moveSealValue(raw: unknown, fallback: SealPosition, position: SealPosition): string;
|
|
28
|
+
/** Only missing positions are repaired; malformed historical values remain available to validation. */
|
|
29
|
+
export declare function initializeSealValue(raw: unknown, fallback: SealPosition): unknown;
|
|
30
|
+
export declare function normalizeSealDiameter(value: unknown): number;
|
|
31
|
+
export declare const mmToPx: (mm: number) => number;
|
|
32
|
+
export declare const pxToMm: (px: number) => number;
|
|
33
|
+
export declare function clampSealPosition(p: SealPosition, widthPx: number, heightPx: number, diameterMm: number): SealPosition;
|
|
34
|
+
export declare function containSealImage(width: number, height: number, size: number): {
|
|
35
|
+
x: number;
|
|
36
|
+
y: number;
|
|
37
|
+
width: number;
|
|
38
|
+
height: number;
|
|
39
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { profile as maintenanceProfile } from './profile';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { profile as pointInspectionProfile } from './profile';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Doc } from '../../../../../core';
|
|
2
|
+
/**
|
|
3
|
+
* 设备点检/保养签字锁定引擎。
|
|
4
|
+
*
|
|
5
|
+
* 由 TableRuntime 生命周期驱动,只在初始化、行初始化或用户数据变更后重算;
|
|
6
|
+
* 不依赖组件是否已挂载,也不在渲染过程中反向写状态。
|
|
7
|
+
*/
|
|
8
|
+
export declare class DeviceSignatureLockEngine {
|
|
9
|
+
private readonly doc;
|
|
10
|
+
constructor(doc: Doc);
|
|
11
|
+
apply(): void;
|
|
12
|
+
private collectConstraint;
|
|
13
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Doc } from '../../../../core';
|
|
2
|
+
export type DeviceOperationControlField = 'inspector_' | 'reviewer_';
|
|
3
|
+
export interface FixedDeviceOperationConfig {
|
|
4
|
+
/** 签名后一并锁定的主表字段 */
|
|
5
|
+
mainFieldBindings?: string[];
|
|
6
|
+
/** 触发当前行数据锁定的签名字段 */
|
|
7
|
+
dataLockControlField?: DeviceOperationControlField;
|
|
8
|
+
}
|
|
9
|
+
export interface FixedDeviceOperationFieldState {
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
readonly?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export interface FixedDeviceOperationTable {
|
|
14
|
+
subFieldKey: string;
|
|
15
|
+
config: FixedDeviceOperationConfig;
|
|
16
|
+
}
|
|
17
|
+
/** 签名字段有有效数据时,认为该行已进入锁定状态。 */
|
|
18
|
+
export declare function hasSignatureValue(value: unknown): boolean;
|
|
19
|
+
export declare function isSignatureLockActive(config: FixedDeviceOperationConfig | undefined, rowData: Record<string, any> | undefined): boolean;
|
|
20
|
+
/** 已保存的固定表行,其控制签名不可再删除。 */
|
|
21
|
+
export declare function isPersistedSignatureLockActive(config: FixedDeviceOperationConfig | undefined, rowData: Record<string, any> | undefined): boolean;
|
|
22
|
+
export declare function getFixedDeviceOperationTables(doc: Doc): FixedDeviceOperationTable[];
|
|
23
|
+
/** 根据字段实际运行时路径解析设备点检/保养表的动态禁用、只读状态。 */
|
|
24
|
+
export declare function resolveFixedDeviceOperationFieldState(doc: Doc, runtimeValuePath: string): FixedDeviceOperationFieldState;
|
|
25
|
+
/** 组装设备点检/保养控制签名前需校验的主表与当前行字段路径。 */
|
|
26
|
+
export declare function resolveDeviceSignatureValidationPaths(doc: Doc, runtimeValuePath: string, candidatePaths: Iterable<string>): string[];
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 物料替换表(MATERIAL_SUBSTITUTION)字段 key
|
|
3
|
+
*/
|
|
4
|
+
export declare const F: {
|
|
5
|
+
/** 工序节点 */
|
|
6
|
+
readonly routingOperation: "routing_operation_id_";
|
|
7
|
+
/** SN */
|
|
8
|
+
readonly productionContainer: "production_container_id_";
|
|
9
|
+
/** 被替换物料批号 */
|
|
10
|
+
readonly sourceMaterialNo: "source_material_no_";
|
|
11
|
+
/** 被替换物料 */
|
|
12
|
+
readonly sourceProduct: "source_product_id_";
|
|
13
|
+
/** 被替换物料名称 */
|
|
14
|
+
readonly sourceProductName: "source_product_id_name_";
|
|
15
|
+
/** 被替换物料编码 */
|
|
16
|
+
readonly sourceProductCode: "source_product_id_code_";
|
|
17
|
+
/** 被替换物料规格 */
|
|
18
|
+
readonly sourceProductSpec: "source_product_id_spec_";
|
|
19
|
+
/** 原上料数量 */
|
|
20
|
+
readonly sourceQtyConsumed: "source_qty_consumed_";
|
|
21
|
+
/** 替换物料批号 */
|
|
22
|
+
readonly targetMaterialNo: "target_material_no_";
|
|
23
|
+
/** 替换物料 */
|
|
24
|
+
readonly targetProduct: "target_product_id_";
|
|
25
|
+
/** 替换物料名称 */
|
|
26
|
+
readonly targetProductName: "target_product_id_name_";
|
|
27
|
+
/** 替换物料编码 */
|
|
28
|
+
readonly targetProductCode: "target_product_id_code_";
|
|
29
|
+
/** 替换物料规格 */
|
|
30
|
+
readonly targetProductSpec: "target_product_id_spec_";
|
|
31
|
+
/** 替换数量 */
|
|
32
|
+
readonly targetQtyConsumed: "target_qty_consumed_";
|
|
33
|
+
};
|
|
34
|
+
export type MaterialSubstitutionFieldKey = (typeof F)[keyof typeof F];
|
|
35
|
+
/** 设计态固定禁用、运行态只读的物料信息字段 */
|
|
36
|
+
export declare const DISABLED_INPUT_FIELDS: readonly ["source_material_no_", "source_product_id_name_", "source_product_id_code_", "source_product_id_spec_", "source_qty_consumed_", "target_product_id_name_", "target_product_id_code_", "target_product_id_spec_"];
|
|
37
|
+
export declare const CLEAR_ON_SOURCE_PRODUCT_EMPTY: readonly ["source_material_no_", "source_product_id_name_", "source_product_id_code_", "source_product_id_spec_", "source_qty_consumed_"];
|
|
38
|
+
/** 替换物料批号清空 / 手输时需清空的物料字段 */
|
|
39
|
+
export declare const CLEAR_ON_TARGET_MATERIAL_NO_EMPTY: readonly ["target_product_id_name_", "target_product_id_code_", "target_product_id_spec_"];
|
|
40
|
+
/** 替换料清空时同步清除批次、数量和物料信息。 */
|
|
41
|
+
export declare const CLEAR_ON_TARGET_PRODUCT_EMPTY: readonly ["target_material_no_", "target_product_id_name_", "target_product_id_code_", "target_product_id_spec_", "target_qty_consumed_"];
|
package/dist/domain/table/business/material/material-substitution/runtime/register-handlers.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/domain/table/business/material/material-substitution/runtime/row-change-handlers.d.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Doc } from '../../../../../../core';
|
|
2
|
+
export declare function handleTargetMaterialNoChange(doc: Doc, subFieldKey: string, rowIndex: number): void;
|
|
3
|
+
export declare function handleSourceProductChange(doc: Doc, subFieldKey: string, rowIndex: number): void;
|
|
4
|
+
export declare function handleTargetProductChange(doc: Doc, subFieldKey: string, rowIndex: number): void;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { FieldMeta } from '../../../capabilities/model-field-runtime';
|
|
2
2
|
import { DropdownOption } from '../../../base';
|
|
3
|
+
/** 是否为仅能通过固定表入口选择的业务子模型。 */
|
|
4
|
+
export declare function isFixedOnlyBusinessRefModelType(refModelType: string | undefined | null): boolean;
|
|
3
5
|
/**
|
|
4
6
|
* 生成「选择子模型」下拉选项
|
|
5
7
|
* @param tableTypeOrRibbonAction 表类型或 Ribbon action
|
|
@@ -13,5 +13,8 @@ export * from './runtime/table-runtime';
|
|
|
13
13
|
export * from './design/hooks/on-subtable-create';
|
|
14
14
|
export * from './design/hooks/on-field-attach';
|
|
15
15
|
export * from './design/hooks/on-repeating-default-props';
|
|
16
|
+
export * from './design/hooks/on-bounded-default-props';
|
|
16
17
|
export * from './design/validate-table-selection';
|
|
17
18
|
export * from './design/validate-nested-table-region';
|
|
19
|
+
export * from './design/validate-nested-table-insert';
|
|
20
|
+
export * from './business/device/signature-lock';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BusinessSubTableProfile, TableCategory, TableProfile } from './types';
|
|
1
|
+
import { BusinessFieldProfile, BusinessSubTableProfile, TableCategory, TableProfile } from './types';
|
|
2
|
+
import { FieldMeta } from '../../capabilities/model-field-runtime';
|
|
2
3
|
/** 所有已注册的子表 Profile */
|
|
3
4
|
declare const ALL_TABLE_PROFILES: TableProfile[];
|
|
4
5
|
/** 按分类获取 Profile 列表 */
|
|
@@ -15,5 +16,7 @@ export declare function getProfileByLayoutType(layoutType: string): TableProfile
|
|
|
15
16
|
*/
|
|
16
17
|
export declare function getAllBusinessRefModelTypes(): string[];
|
|
17
18
|
/** 按 refModelType 获取业务表 Profile */
|
|
18
|
-
export declare function getBusinessProfileByRefModelType(refModelType: string): BusinessSubTableProfile | undefined;
|
|
19
|
+
export declare function getBusinessProfileByRefModelType(refModelType: string | undefined | null): BusinessSubTableProfile | undefined;
|
|
20
|
+
/** 与设计态使用同一匹配顺序,读取业务表字段配置。 */
|
|
21
|
+
export declare function getBusinessFieldProfileByRefModelType(refModelType: string | undefined | null, field: Pick<FieldMeta, 'key' | 'type' | 'bizType'>): BusinessFieldProfile | undefined;
|
|
19
22
|
export { ALL_TABLE_PROFILES };
|