@gct-paas/word 0.2.41 → 0.2.43-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/breadcrumb/src/breadcrumb-item.vue.d.ts +1 -1
- package/dist/base/checkbox/src/checkbox-group.vue.d.ts +1 -1
- package/dist/base/date-time-picker/src/DateTimePicker.vue.d.ts +1 -1
- package/dist/base/form-item/src/form-item.vue.d.ts +1 -1
- package/dist/base/icon/src/icon.vue.d.ts +1 -1
- package/dist/base/index.d.ts +1 -0
- package/dist/base/input/src/input-number.vue.d.ts +1 -0
- package/dist/base/input/src/input.vue.d.ts +3 -3
- package/dist/base/input/src/text-area.vue.d.ts +1 -1
- 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/radio/src/radio-group.vue.d.ts +1 -1
- package/dist/base/rdo-tree-select/src/rdo-tree-select.vue.d.ts +1 -1
- package/dist/base/select/src/basic-select.vue.d.ts +17 -5
- package/dist/base/select/src/searchable-select.vue.d.ts +1 -1
- package/dist/base/switch/src/switch.vue.d.ts +1 -1
- package/dist/base/table/src/table.vue.d.ts +1 -1
- package/dist/base/time-picker/index.d.ts +1 -0
- package/dist/base/time-picker/src/TimePicker.vue.d.ts +29 -0
- 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 +8 -2
- package/dist/core/data/enrichers/inspection-module-qty-enricher.d.ts +19 -0
- package/dist/core/data/enrichers/received-qty-enricher.d.ts +4 -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 -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-consume/profile/product-fields.d.ts +6 -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/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/hooks/on-field-attach.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 +13 -3
- package/dist/index.es.js +42773 -6497
- package/dist/runtime/_register_/runtime/SuiteRuntime.d.ts +4 -0
- 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/initial-product-autofill.d.ts +6 -0
- package/dist/runtime/canvas/table/render/material-consume/material-consume-table-controller.d.ts +18 -8
- package/dist/runtime/canvas/table/render/material-consume/product-autofill.d.ts +7 -0
- package/dist/runtime/canvas/table/render/material-consume/product-source.d.ts +4 -0
- package/dist/runtime/canvas/table/render/material-consume/scan-fill.d.ts +7 -2
- package/dist/runtime/canvas/table/render/material-consume/service.d.ts +5 -2
- package/dist/runtime/designer/toolkit/renderer/add-field-btn.vue.d.ts +8 -0
- package/dist/runtime/designer/toolkit/renderer/toolkit-content-fields.vue.d.ts +3 -1
- package/dist/runtime/designer/toolkit/toolkit-item.vue.d.ts +3 -16
- package/dist/runtime/designer/toolkit/toolkit.vue.d.ts +16 -16
- package/dist/runtime/factories/createDesignWidgetFactory.d.ts +2 -0
- 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/device-scan/device-scan-dialog.vue.d.ts +7 -7
- 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/card-signer.vue.d.ts +2 -2
- 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/option-dropdown.vue.d.ts +7 -7
- 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/renderer/dropdowns/components/tables/rdo-table-dropdown.vue.d.ts +7 -7
- package/dist/runtime/renderer/dropdowns/components/tables/table-dropdown.vue.d.ts +7 -7
- package/dist/runtime/renderer/dropdowns/components/tables/table-option-dropdown.vue.d.ts +7 -7
- package/dist/runtime/renderer/dropdowns/components/tree/tree-dropdown.vue.d.ts +7 -7
- 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/index.d.ts +1 -0
- 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/quantity-received-qty-manifest.d.ts +3 -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/data-init/material-consume-object/linkage.d.ts +7 -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 +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/components/field-map-row.vue.d.ts +1 -1
- 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/config/editor/ref-autofill-editor/autofill-runtime.d.ts +2 -0
- package/dist/suites/shared/panel/config/editor/ref-autofill-editor/field-tree-select.vue.d.ts +1 -1
- 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/adapters/TriggerUtil.d.ts +1 -1
- package/dist/utils/func/base-formula-functions.d.ts +8 -0
- package/dist/utils/pdf/collect-seal-draw-ops.d.ts +4 -0
- package/dist/word.css +1647 -654
- package/package.json +4 -4
|
@@ -10,6 +10,7 @@ import { FieldModelQuery } from '../../../sdk/types/field-model-query';
|
|
|
10
10
|
/** 套件唯一运行期入口 */
|
|
11
11
|
export declare class SuiteRuntime implements FieldModelQuery {
|
|
12
12
|
readonly suiteKey: SuiteKey;
|
|
13
|
+
private readonly fieldsUpdatedListeners;
|
|
13
14
|
readonly fieldService: FieldService;
|
|
14
15
|
readonly modelService: ModelService;
|
|
15
16
|
readonly fieldScope: FieldScope;
|
|
@@ -36,6 +37,9 @@ export declare class SuiteRuntime implements FieldModelQuery {
|
|
|
36
37
|
getMasterSlaveFieldList(modelKey: ModelKey): FieldMeta[];
|
|
37
38
|
getFieldManifest(type: FIELD_TYPE): import('../../../capabilities/field-manifest').FieldManifest | undefined;
|
|
38
39
|
reloadFields(modelKey: ModelKey): Promise<import('../../../capabilities/model-field-runtime').FieldListResult>;
|
|
40
|
+
onFieldsUpdated(listener: (modelKey: ModelKey) => void): () => void;
|
|
41
|
+
/** 通知正在使用指定模型的面板,从字段缓存更新列表;不重新请求字段或加载文档。 */
|
|
42
|
+
notifyFieldsUpdated(modelKey: ModelKey): void;
|
|
39
43
|
reloadModel(modelKey: ModelKey): Promise<[ModelMeta | undefined, import('../../../capabilities/model-field-runtime').FieldListResult]>;
|
|
40
44
|
dispose(): void;
|
|
41
45
|
}
|
|
@@ -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;
|
|
@@ -32,6 +32,8 @@ export declare class BomEntryValidator {
|
|
|
32
32
|
mainMaterialNo: string;
|
|
33
33
|
/** 物料消耗模式 */
|
|
34
34
|
noBomMode: boolean;
|
|
35
|
+
/** 自定义需求数量,由表格行手动填写 */
|
|
36
|
+
isCustomRequiredQty: boolean;
|
|
35
37
|
/** 该明细使用到的产品的id集合 */
|
|
36
38
|
productIds: string[];
|
|
37
39
|
/** 物料和code的映射 */
|
|
@@ -57,7 +59,9 @@ export declare class BomEntryValidator {
|
|
|
57
59
|
/** 表单实例的批次号 */
|
|
58
60
|
mainMaterialNo: string,
|
|
59
61
|
/** 物料消耗模式 */
|
|
60
|
-
noBomMode: boolean
|
|
62
|
+
noBomMode: boolean,
|
|
63
|
+
/** 自定义需求数量,由表格行手动填写 */
|
|
64
|
+
isCustomRequiredQty?: boolean);
|
|
61
65
|
/**
|
|
62
66
|
* 翻译物料的code
|
|
63
67
|
* @param productId
|
|
@@ -148,6 +152,8 @@ export declare class BomEntriesValidator {
|
|
|
148
152
|
mainMaterialNo: string;
|
|
149
153
|
/** 物料消耗模式 */
|
|
150
154
|
noBomMode: boolean;
|
|
155
|
+
/** 需求数量由表格行手动填写 */
|
|
156
|
+
isCustomRequiredQty: boolean;
|
|
151
157
|
bomEntryValidators: BomEntryValidator[];
|
|
152
158
|
constructor(entries: IBomEntry[],
|
|
153
159
|
/** 是否启用顺序投料 */
|
|
@@ -159,7 +165,9 @@ export declare class BomEntriesValidator {
|
|
|
159
165
|
/** 表单实例的批次号 */
|
|
160
166
|
mainMaterialNo: string,
|
|
161
167
|
/** 物料消耗模式 */
|
|
162
|
-
noBomMode: boolean
|
|
168
|
+
noBomMode: boolean,
|
|
169
|
+
/** 需求数量由表格行手动填写 */
|
|
170
|
+
isCustomRequiredQty?: boolean);
|
|
163
171
|
/** 当前批次/生产数量 */
|
|
164
172
|
get materialNoNum(): number;
|
|
165
173
|
/**
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Doc } from '../../../../../core';
|
|
2
|
+
import { IMaterialConsumeData } from '../../../../../domain/table/business/material/types';
|
|
3
|
+
type Updates = Record<string, unknown>;
|
|
4
|
+
/** 初值仅填 undefined,详情或规则错误均不阻断基础行初始化。 */
|
|
5
|
+
export declare function prepareConsumeInitialWrite(doc: Doc, subFieldKey: string, rows: readonly IMaterialConsumeData[]): Promise<Updates>;
|
|
6
|
+
export {};
|
package/dist/runtime/canvas/table/render/material-consume/material-consume-table-controller.d.ts
CHANGED
|
@@ -144,6 +144,12 @@ export declare class MaterialConsumeTableController {
|
|
|
144
144
|
*/
|
|
145
145
|
set actualTableData(value: IMaterialConsumeData[]);
|
|
146
146
|
constructor(tmplBomController: FormTmplBomController, tmplBom: IFormTmplBom);
|
|
147
|
+
get isCustomRequiredQty(): boolean;
|
|
148
|
+
private getBomGroupForRow;
|
|
149
|
+
private getMatchingBomGroupForRow;
|
|
150
|
+
/** 自定义规则的需求数量在同一 BOM 组内保持一致。 */
|
|
151
|
+
getCustomGroupRequiredQty(row: IMaterialConsumeData): number | undefined;
|
|
152
|
+
private syncCustomGroupRequiredQty;
|
|
147
153
|
/** 错误信息 */
|
|
148
154
|
error(message: string): void;
|
|
149
155
|
/**
|
|
@@ -169,7 +175,7 @@ export declare class MaterialConsumeTableController {
|
|
|
169
175
|
* 未填报时初始化消耗表行数据
|
|
170
176
|
* @param defaultData 子表行默认值(含工序等)
|
|
171
177
|
*/
|
|
172
|
-
initTableData(
|
|
178
|
+
initTableData(doc: Doc, subFieldKey: string, defaultData?: Record<string, any>): Promise<number[]>;
|
|
173
179
|
/**
|
|
174
180
|
* 根据数据计算需要禁用的字段
|
|
175
181
|
* @param row
|
|
@@ -256,7 +262,7 @@ export declare class MaterialConsumeTableController {
|
|
|
256
262
|
/** 校验有效期 */
|
|
257
263
|
validateExpiration(row: IMaterialConsumeData): void;
|
|
258
264
|
/**
|
|
259
|
-
*
|
|
265
|
+
* 物料+批次查复检日期、有效期;缺任一参数不查;无日期放过;小于当天则 throw
|
|
260
266
|
*/
|
|
261
267
|
private validateReinspectionDate;
|
|
262
268
|
/**
|
|
@@ -338,14 +344,18 @@ export declare class MaterialConsumeTableController {
|
|
|
338
344
|
*/
|
|
339
345
|
setDefaultValue(row: IMaterialConsumeData, doc: Doc): void;
|
|
340
346
|
getDefaultValue(row: IMaterialConsumeData): any;
|
|
341
|
-
/**
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
handleSelectChange({ changedData, selectedOption, doc, parsed, dataIndex, }: {
|
|
345
|
-
changedData: any;
|
|
347
|
+
/** 下拉写入前校验,只生成更新,不修改当前行。 */
|
|
348
|
+
prepareSelectChange({ pending, selectedOption, doc, parsed, dataIndex, }: {
|
|
349
|
+
pending: Record<string, unknown>;
|
|
346
350
|
selectedOption: any;
|
|
347
351
|
doc: Doc;
|
|
348
352
|
parsed: ParsedValuePath;
|
|
349
353
|
dataIndex: number;
|
|
350
|
-
}): Promise<
|
|
354
|
+
}): Promise<Record<string, unknown>>;
|
|
355
|
+
/** 提交成功后刷新查询条件、禁用状态及派生数量。 */
|
|
356
|
+
afterSelectChange({ doc, parsed, dataIndex, }: {
|
|
357
|
+
doc: Doc;
|
|
358
|
+
parsed: ParsedValuePath;
|
|
359
|
+
dataIndex: number;
|
|
360
|
+
}): void;
|
|
351
361
|
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Doc } from '../../../../../core';
|
|
2
|
+
type Updates = Record<string, unknown>;
|
|
3
|
+
/** 批次选择只填充实际变化的来源;扫码仍按本次命中行执行。 */
|
|
4
|
+
export declare function getChangedConsumeSourcePaths(doc: Doc, pending: Updates, sourcePaths: readonly string[]): string[];
|
|
5
|
+
/** 仅对指定来源生成填充更新;详情查询失败时保留业务更新。 */
|
|
6
|
+
export declare function prepareConsumeWrite(doc: Doc, pending: Updates, sourcePaths: readonly string[]): Promise<Updates>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export type ProductRecord = Record<string, unknown>;
|
|
2
|
+
export declare function productVersionId(value: unknown): string;
|
|
3
|
+
/** 初始化专用:单次批量查询,失败不抛错、不逐条补查。 */
|
|
4
|
+
export declare function loadConsumeInitialProducts(productRefs: readonly unknown[]): Promise<Map<string, ProductRecord>>;
|
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
import { BomEntryValidator, ScanFillPlan } from './bom-validator';
|
|
2
2
|
import { IMaterialConsumeData } from '../../../../../domain/table/business/material/types';
|
|
3
3
|
export type ValidateCurrentGroupForSwitch = (table: IMaterialConsumeData[], current: BomEntryValidator) => void | Promise<void>;
|
|
4
|
+
export interface ScanFillResult {
|
|
5
|
+
rows: IMaterialConsumeData[];
|
|
6
|
+
/** 本次扫码实际写入行的稳定身份 */
|
|
7
|
+
filledRowKey: string;
|
|
8
|
+
}
|
|
4
9
|
/**
|
|
5
|
-
* 按 ScanFillPlan 切组 / 建组 /
|
|
10
|
+
* 按 ScanFillPlan 切组 / 建组 / 填充,返回新表及本次写入行的身份(不改入参 arr)。
|
|
6
11
|
* needSwitch 时通过 options.validateCurrentGroupForSwitch 先校验当前组。
|
|
7
12
|
*/
|
|
8
13
|
export declare function applyScanFillPlan(arr: IMaterialConsumeData[], scanRow: IMaterialConsumeData, plan?: ScanFillPlan, options?: {
|
|
9
14
|
validateCurrentGroupForSwitch?: ValidateCurrentGroupForSwitch;
|
|
10
|
-
}): Promise<
|
|
15
|
+
}): Promise<ScanFillResult>;
|
|
@@ -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;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
/** 新字段的保存位置:主表的主模型、子表绑定的子模型,或二维表所选分组对应的模型。 */
|
|
3
|
+
model?: string;
|
|
4
|
+
/** 新字段所属的表单版本。 */
|
|
5
|
+
tmplVersionId: string;
|
|
6
|
+
};
|
|
7
|
+
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>;
|
|
8
|
+
export default _default;
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
declare const _default: import('vue').DefineComponent<{}, {
|
|
1
|
+
declare const _default: import('vue').DefineComponent<{}, {
|
|
2
|
+
addFieldModelKey: import('vue').ComputedRef<string | undefined>;
|
|
3
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
2
4
|
export default _default;
|
|
@@ -10,17 +10,11 @@ type __VLS_Props = {
|
|
|
10
10
|
declare function __VLS_template(): {
|
|
11
11
|
attrs: Partial<{}>;
|
|
12
12
|
slots: {
|
|
13
|
+
'title-actions'?(_: {}): any;
|
|
13
14
|
default?(_: {}): any;
|
|
14
15
|
};
|
|
15
16
|
refs: {
|
|
16
|
-
dropdownRef:
|
|
17
|
-
P: {};
|
|
18
|
-
B: {};
|
|
19
|
-
D: {};
|
|
20
|
-
C: {};
|
|
21
|
-
M: {};
|
|
22
|
-
Defaults: {};
|
|
23
|
-
}, Record<string, any> & {}, {}, {}, {}, {}, {}> | null;
|
|
17
|
+
dropdownRef: unknown;
|
|
24
18
|
};
|
|
25
19
|
rootEl: HTMLDivElement;
|
|
26
20
|
};
|
|
@@ -46,14 +40,7 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {
|
|
|
46
40
|
active: boolean;
|
|
47
41
|
noDropdown: boolean;
|
|
48
42
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
49
|
-
dropdownRef:
|
|
50
|
-
P: {};
|
|
51
|
-
B: {};
|
|
52
|
-
D: {};
|
|
53
|
-
C: {};
|
|
54
|
-
M: {};
|
|
55
|
-
Defaults: {};
|
|
56
|
-
}, Record<string, any> & {}, {}, {}, {}, {}, {}> | null;
|
|
43
|
+
dropdownRef: unknown;
|
|
57
44
|
}, HTMLDivElement>;
|
|
58
45
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
59
46
|
export default _default;
|
|
@@ -17,14 +17,7 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import
|
|
|
17
17
|
$refs: {
|
|
18
18
|
[x: string]: unknown;
|
|
19
19
|
} & {
|
|
20
|
-
dropdownRef:
|
|
21
|
-
P: {};
|
|
22
|
-
B: {};
|
|
23
|
-
D: {};
|
|
24
|
-
C: {};
|
|
25
|
-
M: {};
|
|
26
|
-
Defaults: {};
|
|
27
|
-
}, Record<string, any> & {}, {}, {}, {}, {}, {}> | null;
|
|
20
|
+
dropdownRef: unknown;
|
|
28
21
|
};
|
|
29
22
|
$slots: Readonly<{
|
|
30
23
|
[name: string]: import('vue').Slot<any> | undefined;
|
|
@@ -105,9 +98,22 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import
|
|
|
105
98
|
isVisible: import('vue').Ref<boolean, boolean>;
|
|
106
99
|
}> & {} & import('vue').ComponentCustomProperties & {} & {
|
|
107
100
|
$slots: {
|
|
101
|
+
'title-actions'?(_: {}): any;
|
|
108
102
|
default?(_: {}): any;
|
|
109
103
|
};
|
|
110
104
|
}) | null;
|
|
105
|
+
fieldContentRef: import('vue').CreateComponentPublicInstanceWithMixins<Readonly<{}> & Readonly<{}>, {
|
|
106
|
+
addFieldModelKey: import('vue').ComputedRef<string | undefined>;
|
|
107
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, import('vue').PublicProps, {}, true, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
|
|
108
|
+
P: {};
|
|
109
|
+
B: {};
|
|
110
|
+
D: {};
|
|
111
|
+
C: {};
|
|
112
|
+
M: {};
|
|
113
|
+
Defaults: {};
|
|
114
|
+
}, Readonly<{}> & Readonly<{}>, {
|
|
115
|
+
addFieldModelKey: import('vue').ComputedRef<string | undefined>;
|
|
116
|
+
}, {}, {}, {}, {}> | null;
|
|
111
117
|
widgetToolkitRef: ({
|
|
112
118
|
$: import('vue').ComponentInternalInstance;
|
|
113
119
|
$data: {};
|
|
@@ -126,14 +132,7 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import
|
|
|
126
132
|
$refs: {
|
|
127
133
|
[x: string]: unknown;
|
|
128
134
|
} & {
|
|
129
|
-
dropdownRef:
|
|
130
|
-
P: {};
|
|
131
|
-
B: {};
|
|
132
|
-
D: {};
|
|
133
|
-
C: {};
|
|
134
|
-
M: {};
|
|
135
|
-
Defaults: {};
|
|
136
|
-
}, Record<string, any> & {}, {}, {}, {}, {}, {}> | null;
|
|
135
|
+
dropdownRef: unknown;
|
|
137
136
|
};
|
|
138
137
|
$slots: Readonly<{
|
|
139
138
|
[name: string]: import('vue').Slot<any> | undefined;
|
|
@@ -214,6 +213,7 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import
|
|
|
214
213
|
isVisible: import('vue').Ref<boolean, boolean>;
|
|
215
214
|
}> & {} & import('vue').ComponentCustomProperties & {} & {
|
|
216
215
|
$slots: {
|
|
216
|
+
'title-actions'?(_: {}): any;
|
|
217
217
|
default?(_: {}): any;
|
|
218
218
|
};
|
|
219
219
|
}) | null;
|
|
@@ -14,6 +14,8 @@ export interface CreateWidgetFromPaletteOptions {
|
|
|
14
14
|
overrideProps?: Record<string, any>;
|
|
15
15
|
/** 用于解析子表业务 Profile */
|
|
16
16
|
refModelType?: string;
|
|
17
|
+
/** 当前模型的完整字段列表,包含对象及对象子字段。 */
|
|
18
|
+
modelFields?: readonly FieldMeta[];
|
|
17
19
|
}
|
|
18
20
|
export declare function createDesignFieldToWidgetFactory(getFieldManifestForField: (f: FieldTypeSource) => FieldManifest | undefined): (field: FieldMeta, opts?: CreateWidgetFromPaletteOptions) => WidgetMeta;
|
|
19
21
|
export declare function createDesignPaperWidgetToWidgetFactory(getManifest: (type: PAPER_WIDGET_TYPE) => PaperWidgetManifest | undefined): (widget: PaperWidgetMeta, opts?: CreateWidgetFromPaletteOptions) => WidgetMeta;
|
|
@@ -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>;
|
|
@@ -105,13 +105,13 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
105
105
|
keyup: (event: KeyboardEvent) => any;
|
|
106
106
|
pressEnter: (event: KeyboardEvent) => any;
|
|
107
107
|
}, string, {
|
|
108
|
-
type: import('../../../../base/input/src/types').InputType;
|
|
109
108
|
id: string;
|
|
109
|
+
type: import('../../../../base/input/src/types').InputType;
|
|
110
110
|
name: string;
|
|
111
|
+
placeholder: string;
|
|
112
|
+
size: import('../../../../base/input/src/types').InputSize;
|
|
111
113
|
readonly: boolean;
|
|
112
114
|
disabled: boolean;
|
|
113
|
-
size: import('../../../../base/input/src/types').InputSize;
|
|
114
|
-
placeholder: string;
|
|
115
115
|
modelValue: string | number;
|
|
116
116
|
prefix: string;
|
|
117
117
|
suffix: string;
|
|
@@ -149,13 +149,13 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
149
149
|
$nextTick: typeof nextTick;
|
|
150
150
|
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import('@vue/reactivity').OnCleanup]) => any : (...args: [any, any, import('@vue/reactivity').OnCleanup]) => any, options?: import('vue').WatchOptions): import('vue').WatchStopHandle;
|
|
151
151
|
} & Readonly<{
|
|
152
|
-
type: import('../../../../base/input/src/types').InputType;
|
|
153
152
|
id: string;
|
|
153
|
+
type: import('../../../../base/input/src/types').InputType;
|
|
154
154
|
name: string;
|
|
155
|
+
placeholder: string;
|
|
156
|
+
size: import('../../../../base/input/src/types').InputSize;
|
|
155
157
|
readonly: boolean;
|
|
156
158
|
disabled: boolean;
|
|
157
|
-
size: import('../../../../base/input/src/types').InputSize;
|
|
158
|
-
placeholder: string;
|
|
159
159
|
modelValue: string | number;
|
|
160
160
|
prefix: string;
|
|
161
161
|
suffix: string;
|
|
@@ -184,7 +184,7 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {
|
|
|
184
184
|
onKeypress?: ((event: KeyboardEvent) => any) | undefined;
|
|
185
185
|
onKeyup?: ((event: KeyboardEvent) => any) | undefined;
|
|
186
186
|
onPressEnter?: ((event: KeyboardEvent) => any) | undefined;
|
|
187
|
-
}>, "select" | "blur" | "focus" | "inputRef" | ("
|
|
187
|
+
}>, "select" | "blur" | "focus" | "inputRef" | ("id" | "type" | "name" | "placeholder" | "size" | "readonly" | "disabled" | "modelValue" | "prefix" | "suffix" | "addonBefore" | "addonAfter" | "allowClear" | "showCount" | "showPasswordToggle" | "maxLength" | "autofocus" | "autocomplete" | "rows" | "bordered" | "showSearchButton" | "spellcheck" | "customStyle")> & import('vue').ShallowUnwrapRef<{
|
|
188
188
|
focus: () => void;
|
|
189
189
|
blur: () => void;
|
|
190
190
|
select: () => void;
|
|
@@ -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 {};
|
|
@@ -4,10 +4,10 @@ type __VLS_Props = {
|
|
|
4
4
|
};
|
|
5
5
|
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
6
6
|
success: () => any;
|
|
7
|
-
status: (status: "
|
|
7
|
+
status: (status: "success" | "warning" | "error" | "waiting") => any;
|
|
8
8
|
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
9
9
|
onSuccess?: (() => any) | undefined;
|
|
10
|
-
onStatus?: ((status: "
|
|
10
|
+
onStatus?: ((status: "success" | "warning" | "error" | "waiting") => any) | undefined;
|
|
11
11
|
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
12
12
|
inputRef: HTMLInputElement;
|
|
13
13
|
}, HTMLDivElement>;
|