sy-form-components 0.2.9 → 0.2.10
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/index.d.mts +6 -1
- package/dist/index.d.ts +6 -1
- package/dist/index.js +132 -45
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +131 -46
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -908,6 +908,10 @@ declare function exportDataManagementRows(request: FormRuntimeApi['request'], pa
|
|
|
908
908
|
embedImages?: 'y' | 'n';
|
|
909
909
|
exportFields?: string[];
|
|
910
910
|
}): Promise<Blob | RuntimeResponse<any>>;
|
|
911
|
+
declare function downloadDataManagementImportTemplate(request: FormRuntimeApi['request'], params: {
|
|
912
|
+
appType: string;
|
|
913
|
+
formUuid: string;
|
|
914
|
+
}): Promise<Blob | RuntimeResponse<any>>;
|
|
911
915
|
declare function importPreviewDataManagementRows(request: FormRuntimeApi['request'], params: {
|
|
912
916
|
appType: string;
|
|
913
917
|
formUuid: string;
|
|
@@ -1460,6 +1464,7 @@ interface DataManagementRowAction {
|
|
|
1460
1464
|
interface DataManagementListProps {
|
|
1461
1465
|
appType: string;
|
|
1462
1466
|
formUuid: string;
|
|
1467
|
+
detailBasePath?: string;
|
|
1463
1468
|
menuFormUuid?: string;
|
|
1464
1469
|
readonly?: boolean;
|
|
1465
1470
|
fullHeight?: boolean;
|
|
@@ -1549,4 +1554,4 @@ interface PageSkeletonProps {
|
|
|
1549
1554
|
}
|
|
1550
1555
|
declare const PageSkeleton: React__default.FC<PageSkeletonProps>;
|
|
1551
1556
|
|
|
1552
|
-
export { type ActionConfig, AddressField, type AddressFieldProps, type AddressValue, ApprovalActionBar, type ApprovalActionBarProps, type ApprovalActionType, ApprovalActions, type ApprovalActionsProps, type ApprovalPermission, ApprovalTimeline, type ApprovalTimelineProps, type ApproveParams, type AssociationFormConfig, AssociationFormField, type AssociationFormFieldProps, type AssociationValue, AttachmentField, type AttachmentFieldProps, type AttachmentItem, type BaseFieldProps, CascadeDateField, type CascadeDateFieldProps, CascadeSelectField, type CascadeSelectFieldProps, type ChangeRecord, type ChangeRecordListResponse, type ChangeRecordQueryParams, ChangeRecords, type ChangeRecordsProps, CheckboxField, type CheckboxFieldProps, ComponentRegistryContext, type ComponentRegistryContextValue, ComponentRegistryProvider, type DataManagementConfig, type DataManagementConfigScope, type DataManagementDensity, type DataManagementField, type DataManagementFilterGroup, type DataManagementFilterRule, DataManagementList, type DataManagementListProps, type DataManagementListResult, type DataManagementQuery, type DataManagementRowAction, type DataManagementSort, DateField, type DateFieldProps, DepartmentSelectField, type DepartmentSelectFieldProps, type DepartmentTreeNode, type DeviceDetectResult, DigitalSignatureField, type DigitalSignatureFieldProps, type DigitalSignatureValue, DraftManager, type DraftManagerProps, EditorField, type EditorFieldProps, UserSelectField as EmployeeSelectField, type FieldBehavior, type FieldDefinition, FieldWrapper, type FieldWrapperProps, FormActionBar, type FormActionBarProps, FormActions, type FormActionsProps, FormContainer, type FormContainerProps, FormContext, type FormContextValue, type FormDataDeleteParams, type FormDataQueryParams, FormDetailTemplate, type FormDetailTemplateProps, type FormEffect, type FormEngineConfig, FormGrid, type FormGridProps, type FormInstanceData, FormProvider, type FormProviderProps, FormRenderer, type FormRendererProps, type FormRuntimeApi, type FormRuntimeApiConfig, type FormSchema, FormSection, type FormSectionProps, type FormStepItem, FormSteps, type FormStepsProps, FormSubmitTemplate, type FormSubmitTemplateProps, FormSummary, FormSummaryCard, type FormSummaryCardProps, type FormSummaryProps, type FormTabItem, FormTabs, type FormTabsProps, ImageField, type ImageFieldProps, JSONField, type JSONFieldProps, LocationField, type LocationFieldProps, type LocationValue, MultiSelectField, type MultiSelectFieldProps, NumberField, type NumberFieldProps, type OptionItem, PROCESS_STATUS_META, PageSkeleton, type PageSkeletonProps, type PreviewParams, type ProcessAction, type ProcessBasicInfo, type ProcessDefinition, ProcessDetailTemplate, type ProcessDetailTemplateProps, type ProcessNodeType, ProcessPreview, type ProcessPreviewProps, type ProcessRoute, type ProcessStatus, type ProcessTask, RadioField, type RadioFieldProps, RecordChangePanel, type RecordChangePanelProps, type ResubmitParams, type ReturnParams, type ReturnableNode, RuntimePageShell, type RuntimePageShellProps, type RuntimeRequestConfig, type RuntimeResponse, type SaveTaskParams, SelectField, type SelectFieldProps, SerialNumberField, type SerialNumberFieldProps, type SignaturePoint, type StatusMeta, StickyActionBar, type StickyActionBarProps, type SubFormColumn, SubFormField, type SubFormFieldProps, type SubmitConfig, type SubmitSuccessInfo, SummaryPanel, type SummaryPanelMetaItem, type SummaryPanelProps, TASK_STATUS_META, type TaskStatus, TextAreaField, type TextAreaFieldProps, TextField, type TextFieldProps, TextAreaField as TextareaField, type TransferParams, type UseApprovalActionsOptions, type UseApprovalActionsReturn, type UseChangeRecordsOptions, type UseChangeRecordsReturn, type UseDraftStorageOptions, type UseDraftStorageReturn, type UseFieldBehaviorOptions, type UseFieldPermissionOptions, type UseFieldPermissionReturn, type UseFormDataReturn, type UseFormDetailOptions, type UseFormDetailReturn, type UseFormEngineReturn, type UseFormNavigationOptions, type UseFormNavigationReturn, type UseFormSubmitReturn, type UseProcessDetailOptions, type UseProcessDetailReturn, type UserItem, UserSelectField, type UserSelectFieldProps, type ValidationRule, type ViewPermissionQueryParams, type ViewPermissionSummary, type WithdrawParams, advancedSearchDataManagement, batchApproveDataManagementRows, buildFilterPayload, checkUserApproval, createFormRuntimeApi, defaultComponentRegistry, defineFormSchema, deleteDataManagementRows, deleteFormData, evaluateEffects, exportDataManagementRows, extractFormValues, getChangeRecords, getDataManagementConfig, getDataManagementSchema, getDataManagementTransferRecords, getFormData, getProcessBasic, getProcessDefinition, getProcessProgress, getReturnableNodes, getSystemFieldsForFormType, getViewPermission, handleApproval, hasViewOperation, hasViewPermission, importDataManagementRows, importPreviewDataManagementRows, normalizeColumnConfig, normalizeDataManagementFields, normalizeDataManagementList, normalizeFieldBehaviors, normalizeOperation, previewProcess, resubmitTask, returnTask, saveDataManagementConfig, saveTask, transferTask, triggerCallbackTask, useApprovalActions, useChangeRecords, useComponent, useDeviceDetect, useDraftStorage, useFieldBehavior, useFieldPermission, useFormContext, useFormData, useFormDetail, useFormEngine, useFormNavigation, useFormSubmit, useProcessDetail, validateAllFields, validateField, withdrawProcess };
|
|
1557
|
+
export { type ActionConfig, AddressField, type AddressFieldProps, type AddressValue, ApprovalActionBar, type ApprovalActionBarProps, type ApprovalActionType, ApprovalActions, type ApprovalActionsProps, type ApprovalPermission, ApprovalTimeline, type ApprovalTimelineProps, type ApproveParams, type AssociationFormConfig, AssociationFormField, type AssociationFormFieldProps, type AssociationValue, AttachmentField, type AttachmentFieldProps, type AttachmentItem, type BaseFieldProps, CascadeDateField, type CascadeDateFieldProps, CascadeSelectField, type CascadeSelectFieldProps, type ChangeRecord, type ChangeRecordListResponse, type ChangeRecordQueryParams, ChangeRecords, type ChangeRecordsProps, CheckboxField, type CheckboxFieldProps, ComponentRegistryContext, type ComponentRegistryContextValue, ComponentRegistryProvider, type DataManagementConfig, type DataManagementConfigScope, type DataManagementDensity, type DataManagementField, type DataManagementFilterGroup, type DataManagementFilterRule, DataManagementList, type DataManagementListProps, type DataManagementListResult, type DataManagementQuery, type DataManagementRowAction, type DataManagementSort, DateField, type DateFieldProps, DepartmentSelectField, type DepartmentSelectFieldProps, type DepartmentTreeNode, type DeviceDetectResult, DigitalSignatureField, type DigitalSignatureFieldProps, type DigitalSignatureValue, DraftManager, type DraftManagerProps, EditorField, type EditorFieldProps, UserSelectField as EmployeeSelectField, type FieldBehavior, type FieldDefinition, FieldWrapper, type FieldWrapperProps, FormActionBar, type FormActionBarProps, FormActions, type FormActionsProps, FormContainer, type FormContainerProps, FormContext, type FormContextValue, type FormDataDeleteParams, type FormDataQueryParams, FormDetailTemplate, type FormDetailTemplateProps, type FormEffect, type FormEngineConfig, FormGrid, type FormGridProps, type FormInstanceData, FormProvider, type FormProviderProps, FormRenderer, type FormRendererProps, type FormRuntimeApi, type FormRuntimeApiConfig, type FormSchema, FormSection, type FormSectionProps, type FormStepItem, FormSteps, type FormStepsProps, FormSubmitTemplate, type FormSubmitTemplateProps, FormSummary, FormSummaryCard, type FormSummaryCardProps, type FormSummaryProps, type FormTabItem, FormTabs, type FormTabsProps, ImageField, type ImageFieldProps, JSONField, type JSONFieldProps, LocationField, type LocationFieldProps, type LocationValue, MultiSelectField, type MultiSelectFieldProps, NumberField, type NumberFieldProps, type OptionItem, PROCESS_STATUS_META, PageSkeleton, type PageSkeletonProps, type PreviewParams, type ProcessAction, type ProcessBasicInfo, type ProcessDefinition, ProcessDetailTemplate, type ProcessDetailTemplateProps, type ProcessNodeType, ProcessPreview, type ProcessPreviewProps, type ProcessRoute, type ProcessStatus, type ProcessTask, RadioField, type RadioFieldProps, RecordChangePanel, type RecordChangePanelProps, type ResubmitParams, type ReturnParams, type ReturnableNode, RuntimePageShell, type RuntimePageShellProps, type RuntimeRequestConfig, type RuntimeResponse, type SaveTaskParams, SelectField, type SelectFieldProps, SerialNumberField, type SerialNumberFieldProps, type SignaturePoint, type StatusMeta, StickyActionBar, type StickyActionBarProps, type SubFormColumn, SubFormField, type SubFormFieldProps, type SubmitConfig, type SubmitSuccessInfo, SummaryPanel, type SummaryPanelMetaItem, type SummaryPanelProps, TASK_STATUS_META, type TaskStatus, TextAreaField, type TextAreaFieldProps, TextField, type TextFieldProps, TextAreaField as TextareaField, type TransferParams, type UseApprovalActionsOptions, type UseApprovalActionsReturn, type UseChangeRecordsOptions, type UseChangeRecordsReturn, type UseDraftStorageOptions, type UseDraftStorageReturn, type UseFieldBehaviorOptions, type UseFieldPermissionOptions, type UseFieldPermissionReturn, type UseFormDataReturn, type UseFormDetailOptions, type UseFormDetailReturn, type UseFormEngineReturn, type UseFormNavigationOptions, type UseFormNavigationReturn, type UseFormSubmitReturn, type UseProcessDetailOptions, type UseProcessDetailReturn, type UserItem, UserSelectField, type UserSelectFieldProps, type ValidationRule, type ViewPermissionQueryParams, type ViewPermissionSummary, type WithdrawParams, advancedSearchDataManagement, batchApproveDataManagementRows, buildFilterPayload, checkUserApproval, createFormRuntimeApi, defaultComponentRegistry, defineFormSchema, deleteDataManagementRows, deleteFormData, downloadDataManagementImportTemplate, evaluateEffects, exportDataManagementRows, extractFormValues, getChangeRecords, getDataManagementConfig, getDataManagementSchema, getDataManagementTransferRecords, getFormData, getProcessBasic, getProcessDefinition, getProcessProgress, getReturnableNodes, getSystemFieldsForFormType, getViewPermission, handleApproval, hasViewOperation, hasViewPermission, importDataManagementRows, importPreviewDataManagementRows, normalizeColumnConfig, normalizeDataManagementFields, normalizeDataManagementList, normalizeFieldBehaviors, normalizeOperation, previewProcess, resubmitTask, returnTask, saveDataManagementConfig, saveTask, transferTask, triggerCallbackTask, useApprovalActions, useChangeRecords, useComponent, useDeviceDetect, useDraftStorage, useFieldBehavior, useFieldPermission, useFormContext, useFormData, useFormDetail, useFormEngine, useFormNavigation, useFormSubmit, useProcessDetail, validateAllFields, validateField, withdrawProcess };
|
package/dist/index.d.ts
CHANGED
|
@@ -908,6 +908,10 @@ declare function exportDataManagementRows(request: FormRuntimeApi['request'], pa
|
|
|
908
908
|
embedImages?: 'y' | 'n';
|
|
909
909
|
exportFields?: string[];
|
|
910
910
|
}): Promise<Blob | RuntimeResponse<any>>;
|
|
911
|
+
declare function downloadDataManagementImportTemplate(request: FormRuntimeApi['request'], params: {
|
|
912
|
+
appType: string;
|
|
913
|
+
formUuid: string;
|
|
914
|
+
}): Promise<Blob | RuntimeResponse<any>>;
|
|
911
915
|
declare function importPreviewDataManagementRows(request: FormRuntimeApi['request'], params: {
|
|
912
916
|
appType: string;
|
|
913
917
|
formUuid: string;
|
|
@@ -1460,6 +1464,7 @@ interface DataManagementRowAction {
|
|
|
1460
1464
|
interface DataManagementListProps {
|
|
1461
1465
|
appType: string;
|
|
1462
1466
|
formUuid: string;
|
|
1467
|
+
detailBasePath?: string;
|
|
1463
1468
|
menuFormUuid?: string;
|
|
1464
1469
|
readonly?: boolean;
|
|
1465
1470
|
fullHeight?: boolean;
|
|
@@ -1549,4 +1554,4 @@ interface PageSkeletonProps {
|
|
|
1549
1554
|
}
|
|
1550
1555
|
declare const PageSkeleton: React__default.FC<PageSkeletonProps>;
|
|
1551
1556
|
|
|
1552
|
-
export { type ActionConfig, AddressField, type AddressFieldProps, type AddressValue, ApprovalActionBar, type ApprovalActionBarProps, type ApprovalActionType, ApprovalActions, type ApprovalActionsProps, type ApprovalPermission, ApprovalTimeline, type ApprovalTimelineProps, type ApproveParams, type AssociationFormConfig, AssociationFormField, type AssociationFormFieldProps, type AssociationValue, AttachmentField, type AttachmentFieldProps, type AttachmentItem, type BaseFieldProps, CascadeDateField, type CascadeDateFieldProps, CascadeSelectField, type CascadeSelectFieldProps, type ChangeRecord, type ChangeRecordListResponse, type ChangeRecordQueryParams, ChangeRecords, type ChangeRecordsProps, CheckboxField, type CheckboxFieldProps, ComponentRegistryContext, type ComponentRegistryContextValue, ComponentRegistryProvider, type DataManagementConfig, type DataManagementConfigScope, type DataManagementDensity, type DataManagementField, type DataManagementFilterGroup, type DataManagementFilterRule, DataManagementList, type DataManagementListProps, type DataManagementListResult, type DataManagementQuery, type DataManagementRowAction, type DataManagementSort, DateField, type DateFieldProps, DepartmentSelectField, type DepartmentSelectFieldProps, type DepartmentTreeNode, type DeviceDetectResult, DigitalSignatureField, type DigitalSignatureFieldProps, type DigitalSignatureValue, DraftManager, type DraftManagerProps, EditorField, type EditorFieldProps, UserSelectField as EmployeeSelectField, type FieldBehavior, type FieldDefinition, FieldWrapper, type FieldWrapperProps, FormActionBar, type FormActionBarProps, FormActions, type FormActionsProps, FormContainer, type FormContainerProps, FormContext, type FormContextValue, type FormDataDeleteParams, type FormDataQueryParams, FormDetailTemplate, type FormDetailTemplateProps, type FormEffect, type FormEngineConfig, FormGrid, type FormGridProps, type FormInstanceData, FormProvider, type FormProviderProps, FormRenderer, type FormRendererProps, type FormRuntimeApi, type FormRuntimeApiConfig, type FormSchema, FormSection, type FormSectionProps, type FormStepItem, FormSteps, type FormStepsProps, FormSubmitTemplate, type FormSubmitTemplateProps, FormSummary, FormSummaryCard, type FormSummaryCardProps, type FormSummaryProps, type FormTabItem, FormTabs, type FormTabsProps, ImageField, type ImageFieldProps, JSONField, type JSONFieldProps, LocationField, type LocationFieldProps, type LocationValue, MultiSelectField, type MultiSelectFieldProps, NumberField, type NumberFieldProps, type OptionItem, PROCESS_STATUS_META, PageSkeleton, type PageSkeletonProps, type PreviewParams, type ProcessAction, type ProcessBasicInfo, type ProcessDefinition, ProcessDetailTemplate, type ProcessDetailTemplateProps, type ProcessNodeType, ProcessPreview, type ProcessPreviewProps, type ProcessRoute, type ProcessStatus, type ProcessTask, RadioField, type RadioFieldProps, RecordChangePanel, type RecordChangePanelProps, type ResubmitParams, type ReturnParams, type ReturnableNode, RuntimePageShell, type RuntimePageShellProps, type RuntimeRequestConfig, type RuntimeResponse, type SaveTaskParams, SelectField, type SelectFieldProps, SerialNumberField, type SerialNumberFieldProps, type SignaturePoint, type StatusMeta, StickyActionBar, type StickyActionBarProps, type SubFormColumn, SubFormField, type SubFormFieldProps, type SubmitConfig, type SubmitSuccessInfo, SummaryPanel, type SummaryPanelMetaItem, type SummaryPanelProps, TASK_STATUS_META, type TaskStatus, TextAreaField, type TextAreaFieldProps, TextField, type TextFieldProps, TextAreaField as TextareaField, type TransferParams, type UseApprovalActionsOptions, type UseApprovalActionsReturn, type UseChangeRecordsOptions, type UseChangeRecordsReturn, type UseDraftStorageOptions, type UseDraftStorageReturn, type UseFieldBehaviorOptions, type UseFieldPermissionOptions, type UseFieldPermissionReturn, type UseFormDataReturn, type UseFormDetailOptions, type UseFormDetailReturn, type UseFormEngineReturn, type UseFormNavigationOptions, type UseFormNavigationReturn, type UseFormSubmitReturn, type UseProcessDetailOptions, type UseProcessDetailReturn, type UserItem, UserSelectField, type UserSelectFieldProps, type ValidationRule, type ViewPermissionQueryParams, type ViewPermissionSummary, type WithdrawParams, advancedSearchDataManagement, batchApproveDataManagementRows, buildFilterPayload, checkUserApproval, createFormRuntimeApi, defaultComponentRegistry, defineFormSchema, deleteDataManagementRows, deleteFormData, evaluateEffects, exportDataManagementRows, extractFormValues, getChangeRecords, getDataManagementConfig, getDataManagementSchema, getDataManagementTransferRecords, getFormData, getProcessBasic, getProcessDefinition, getProcessProgress, getReturnableNodes, getSystemFieldsForFormType, getViewPermission, handleApproval, hasViewOperation, hasViewPermission, importDataManagementRows, importPreviewDataManagementRows, normalizeColumnConfig, normalizeDataManagementFields, normalizeDataManagementList, normalizeFieldBehaviors, normalizeOperation, previewProcess, resubmitTask, returnTask, saveDataManagementConfig, saveTask, transferTask, triggerCallbackTask, useApprovalActions, useChangeRecords, useComponent, useDeviceDetect, useDraftStorage, useFieldBehavior, useFieldPermission, useFormContext, useFormData, useFormDetail, useFormEngine, useFormNavigation, useFormSubmit, useProcessDetail, validateAllFields, validateField, withdrawProcess };
|
|
1557
|
+
export { type ActionConfig, AddressField, type AddressFieldProps, type AddressValue, ApprovalActionBar, type ApprovalActionBarProps, type ApprovalActionType, ApprovalActions, type ApprovalActionsProps, type ApprovalPermission, ApprovalTimeline, type ApprovalTimelineProps, type ApproveParams, type AssociationFormConfig, AssociationFormField, type AssociationFormFieldProps, type AssociationValue, AttachmentField, type AttachmentFieldProps, type AttachmentItem, type BaseFieldProps, CascadeDateField, type CascadeDateFieldProps, CascadeSelectField, type CascadeSelectFieldProps, type ChangeRecord, type ChangeRecordListResponse, type ChangeRecordQueryParams, ChangeRecords, type ChangeRecordsProps, CheckboxField, type CheckboxFieldProps, ComponentRegistryContext, type ComponentRegistryContextValue, ComponentRegistryProvider, type DataManagementConfig, type DataManagementConfigScope, type DataManagementDensity, type DataManagementField, type DataManagementFilterGroup, type DataManagementFilterRule, DataManagementList, type DataManagementListProps, type DataManagementListResult, type DataManagementQuery, type DataManagementRowAction, type DataManagementSort, DateField, type DateFieldProps, DepartmentSelectField, type DepartmentSelectFieldProps, type DepartmentTreeNode, type DeviceDetectResult, DigitalSignatureField, type DigitalSignatureFieldProps, type DigitalSignatureValue, DraftManager, type DraftManagerProps, EditorField, type EditorFieldProps, UserSelectField as EmployeeSelectField, type FieldBehavior, type FieldDefinition, FieldWrapper, type FieldWrapperProps, FormActionBar, type FormActionBarProps, FormActions, type FormActionsProps, FormContainer, type FormContainerProps, FormContext, type FormContextValue, type FormDataDeleteParams, type FormDataQueryParams, FormDetailTemplate, type FormDetailTemplateProps, type FormEffect, type FormEngineConfig, FormGrid, type FormGridProps, type FormInstanceData, FormProvider, type FormProviderProps, FormRenderer, type FormRendererProps, type FormRuntimeApi, type FormRuntimeApiConfig, type FormSchema, FormSection, type FormSectionProps, type FormStepItem, FormSteps, type FormStepsProps, FormSubmitTemplate, type FormSubmitTemplateProps, FormSummary, FormSummaryCard, type FormSummaryCardProps, type FormSummaryProps, type FormTabItem, FormTabs, type FormTabsProps, ImageField, type ImageFieldProps, JSONField, type JSONFieldProps, LocationField, type LocationFieldProps, type LocationValue, MultiSelectField, type MultiSelectFieldProps, NumberField, type NumberFieldProps, type OptionItem, PROCESS_STATUS_META, PageSkeleton, type PageSkeletonProps, type PreviewParams, type ProcessAction, type ProcessBasicInfo, type ProcessDefinition, ProcessDetailTemplate, type ProcessDetailTemplateProps, type ProcessNodeType, ProcessPreview, type ProcessPreviewProps, type ProcessRoute, type ProcessStatus, type ProcessTask, RadioField, type RadioFieldProps, RecordChangePanel, type RecordChangePanelProps, type ResubmitParams, type ReturnParams, type ReturnableNode, RuntimePageShell, type RuntimePageShellProps, type RuntimeRequestConfig, type RuntimeResponse, type SaveTaskParams, SelectField, type SelectFieldProps, SerialNumberField, type SerialNumberFieldProps, type SignaturePoint, type StatusMeta, StickyActionBar, type StickyActionBarProps, type SubFormColumn, SubFormField, type SubFormFieldProps, type SubmitConfig, type SubmitSuccessInfo, SummaryPanel, type SummaryPanelMetaItem, type SummaryPanelProps, TASK_STATUS_META, type TaskStatus, TextAreaField, type TextAreaFieldProps, TextField, type TextFieldProps, TextAreaField as TextareaField, type TransferParams, type UseApprovalActionsOptions, type UseApprovalActionsReturn, type UseChangeRecordsOptions, type UseChangeRecordsReturn, type UseDraftStorageOptions, type UseDraftStorageReturn, type UseFieldBehaviorOptions, type UseFieldPermissionOptions, type UseFieldPermissionReturn, type UseFormDataReturn, type UseFormDetailOptions, type UseFormDetailReturn, type UseFormEngineReturn, type UseFormNavigationOptions, type UseFormNavigationReturn, type UseFormSubmitReturn, type UseProcessDetailOptions, type UseProcessDetailReturn, type UserItem, UserSelectField, type UserSelectFieldProps, type ValidationRule, type ViewPermissionQueryParams, type ViewPermissionSummary, type WithdrawParams, advancedSearchDataManagement, batchApproveDataManagementRows, buildFilterPayload, checkUserApproval, createFormRuntimeApi, defaultComponentRegistry, defineFormSchema, deleteDataManagementRows, deleteFormData, downloadDataManagementImportTemplate, evaluateEffects, exportDataManagementRows, extractFormValues, getChangeRecords, getDataManagementConfig, getDataManagementSchema, getDataManagementTransferRecords, getFormData, getProcessBasic, getProcessDefinition, getProcessProgress, getReturnableNodes, getSystemFieldsForFormType, getViewPermission, handleApproval, hasViewOperation, hasViewPermission, importDataManagementRows, importPreviewDataManagementRows, normalizeColumnConfig, normalizeDataManagementFields, normalizeDataManagementList, normalizeFieldBehaviors, normalizeOperation, previewProcess, resubmitTask, returnTask, saveDataManagementConfig, saveTask, transferTask, triggerCallbackTask, useApprovalActions, useChangeRecords, useComponent, useDeviceDetect, useDraftStorage, useFieldBehavior, useFieldPermission, useFormContext, useFormData, useFormDetail, useFormEngine, useFormNavigation, useFormSubmit, useProcessDetail, validateAllFields, validateField, withdrawProcess };
|
package/dist/index.js
CHANGED
|
@@ -95,6 +95,7 @@ __export(index_exports, {
|
|
|
95
95
|
defineFormSchema: () => defineFormSchema,
|
|
96
96
|
deleteDataManagementRows: () => deleteDataManagementRows,
|
|
97
97
|
deleteFormData: () => deleteFormData,
|
|
98
|
+
downloadDataManagementImportTemplate: () => downloadDataManagementImportTemplate,
|
|
98
99
|
evaluateEffects: () => evaluateEffects,
|
|
99
100
|
exportDataManagementRows: () => exportDataManagementRows,
|
|
100
101
|
extractFormValues: () => extractFormValues,
|
|
@@ -7147,6 +7148,16 @@ async function exportDataManagementRows(request, params) {
|
|
|
7147
7148
|
}
|
|
7148
7149
|
});
|
|
7149
7150
|
}
|
|
7151
|
+
async function downloadDataManagementImportTemplate(request, params) {
|
|
7152
|
+
return request({
|
|
7153
|
+
url: `/${params.appType}/v1/form/advancedExportTemplate.xlsx`,
|
|
7154
|
+
method: "get",
|
|
7155
|
+
responseType: "blob",
|
|
7156
|
+
params: {
|
|
7157
|
+
formUuid: params.formUuid
|
|
7158
|
+
}
|
|
7159
|
+
});
|
|
7160
|
+
}
|
|
7150
7161
|
async function importPreviewDataManagementRows(request, params) {
|
|
7151
7162
|
const response = await request({
|
|
7152
7163
|
url: `/${params.appType}/v1/form/importPreview.xlsx`,
|
|
@@ -10111,6 +10122,74 @@ var fileToBase64 = (file) => new Promise((resolve, reject) => {
|
|
|
10111
10122
|
reader.onerror = reject;
|
|
10112
10123
|
reader.readAsDataURL(file);
|
|
10113
10124
|
});
|
|
10125
|
+
var normalizeBasePath2 = (basePath) => {
|
|
10126
|
+
const normalized = String(basePath || "").replace(/^\/+|\/+$/g, "");
|
|
10127
|
+
return normalized ? `/${normalized}` : "";
|
|
10128
|
+
};
|
|
10129
|
+
var inferBasePath2 = (appType) => {
|
|
10130
|
+
if (typeof window === "undefined") return "";
|
|
10131
|
+
const pathname = window.location?.pathname || "";
|
|
10132
|
+
const marker = `/${appType}/`;
|
|
10133
|
+
const markerIndex = pathname.indexOf(marker);
|
|
10134
|
+
if (markerIndex <= 0) return "";
|
|
10135
|
+
return pathname.slice(0, markerIndex);
|
|
10136
|
+
};
|
|
10137
|
+
var buildDefaultDetailUrl = ({
|
|
10138
|
+
appType,
|
|
10139
|
+
formUuid,
|
|
10140
|
+
formType,
|
|
10141
|
+
formInstanceId,
|
|
10142
|
+
basePath
|
|
10143
|
+
}) => {
|
|
10144
|
+
const prefix = normalizeBasePath2(basePath ?? inferBasePath2(appType));
|
|
10145
|
+
const detailType = formType === "process" ? "processDetail" : "formDetail";
|
|
10146
|
+
return `${prefix}/${appType}/${detailType}/${formUuid}?formInstId=${encodeURIComponent(formInstanceId)}`;
|
|
10147
|
+
};
|
|
10148
|
+
var getHeaderValue = (headers, key) => {
|
|
10149
|
+
if (!headers) return "";
|
|
10150
|
+
if (typeof headers.get === "function")
|
|
10151
|
+
return headers.get(key) || headers.get(key.toLowerCase()) || "";
|
|
10152
|
+
return headers[key] || headers[key.toLowerCase()] || "";
|
|
10153
|
+
};
|
|
10154
|
+
var resolveDownloadFilename = (headers, fallbackName) => {
|
|
10155
|
+
const disposition = getHeaderValue(headers, "content-disposition");
|
|
10156
|
+
if (typeof disposition !== "string") return fallbackName;
|
|
10157
|
+
const matchStar = disposition.match(/filename\*=UTF-8''([^;]+)/i);
|
|
10158
|
+
if (matchStar?.[1]) return decodeURIComponent(matchStar[1]);
|
|
10159
|
+
const match = disposition.match(/filename="?([^";]+)"?/i);
|
|
10160
|
+
if (match?.[1]) return decodeURIComponent(match[1]);
|
|
10161
|
+
return fallbackName;
|
|
10162
|
+
};
|
|
10163
|
+
var downloadBlobResponse = async (response, fallbackName) => {
|
|
10164
|
+
if (typeof window === "undefined" || typeof document === "undefined") return;
|
|
10165
|
+
const headers = response?.headers;
|
|
10166
|
+
const payload = response?.data ?? response;
|
|
10167
|
+
const contentType = getHeaderValue(headers, "content-type") || payload?.type || "";
|
|
10168
|
+
const hasBlob = typeof Blob !== "undefined";
|
|
10169
|
+
if (hasBlob && payload instanceof Blob && String(contentType).includes("application/json")) {
|
|
10170
|
+
const text = await payload.text();
|
|
10171
|
+
try {
|
|
10172
|
+
const json = JSON.parse(text);
|
|
10173
|
+
throw new Error(json?.message || "\u4E0B\u8F7D\u5931\u8D25");
|
|
10174
|
+
} catch (error) {
|
|
10175
|
+
if (error instanceof SyntaxError) throw new Error("\u4E0B\u8F7D\u5931\u8D25");
|
|
10176
|
+
if (error instanceof Error) throw error;
|
|
10177
|
+
throw new Error("\u4E0B\u8F7D\u5931\u8D25");
|
|
10178
|
+
}
|
|
10179
|
+
}
|
|
10180
|
+
const blob = hasBlob && payload instanceof Blob ? payload : hasBlob && payload instanceof ArrayBuffer ? new Blob([payload], { type: contentType || "application/octet-stream" }) : new Blob([typeof payload === "string" ? payload : JSON.stringify(payload ?? "")], {
|
|
10181
|
+
type: contentType || "application/octet-stream"
|
|
10182
|
+
});
|
|
10183
|
+
const filename = resolveDownloadFilename(headers, fallbackName);
|
|
10184
|
+
const url = window.URL.createObjectURL(blob);
|
|
10185
|
+
const anchor = document.createElement("a");
|
|
10186
|
+
anchor.href = url;
|
|
10187
|
+
anchor.download = filename;
|
|
10188
|
+
document.body.appendChild(anchor);
|
|
10189
|
+
anchor.click();
|
|
10190
|
+
anchor.remove();
|
|
10191
|
+
window.URL.revokeObjectURL(url);
|
|
10192
|
+
};
|
|
10114
10193
|
function FilterGroupEditor({
|
|
10115
10194
|
group,
|
|
10116
10195
|
fields,
|
|
@@ -10270,12 +10349,16 @@ function ResizableColumnTitle({
|
|
|
10270
10349
|
"span",
|
|
10271
10350
|
{
|
|
10272
10351
|
"aria-hidden": true,
|
|
10273
|
-
className: "absolute -right-
|
|
10274
|
-
|
|
10352
|
+
className: "absolute -right-3 top-0 h-full w-4 cursor-col-resize after:absolute after:right-1 after:top-1/2 after:h-5 after:w-0.5 after:-translate-y-1/2 after:rounded after:bg-transparent hover:after:bg-ant-color-primary",
|
|
10353
|
+
onClickCapture: (event) => {
|
|
10275
10354
|
event.preventDefault();
|
|
10276
10355
|
event.stopPropagation();
|
|
10277
10356
|
},
|
|
10278
|
-
|
|
10357
|
+
onDoubleClickCapture: (event) => {
|
|
10358
|
+
event.preventDefault();
|
|
10359
|
+
event.stopPropagation();
|
|
10360
|
+
},
|
|
10361
|
+
onMouseDownCapture: handleMouseDown,
|
|
10279
10362
|
title: "\u62D6\u62FD\u8C03\u6574\u5217\u5BBD"
|
|
10280
10363
|
}
|
|
10281
10364
|
)
|
|
@@ -10284,6 +10367,7 @@ function ResizableColumnTitle({
|
|
|
10284
10367
|
var DataManagementList = ({
|
|
10285
10368
|
appType,
|
|
10286
10369
|
formUuid,
|
|
10370
|
+
detailBasePath,
|
|
10287
10371
|
menuFormUuid,
|
|
10288
10372
|
readonly = false,
|
|
10289
10373
|
fullHeight = true,
|
|
@@ -10330,6 +10414,7 @@ var DataManagementList = ({
|
|
|
10330
10414
|
const [importOpen, setImportOpen] = (0, import_react61.useState)(false);
|
|
10331
10415
|
const [importPreview, setImportPreview] = (0, import_react61.useState)([]);
|
|
10332
10416
|
const [importBase64, setImportBase64] = (0, import_react61.useState)("");
|
|
10417
|
+
const [templateDownloading, setTemplateDownloading] = (0, import_react61.useState)(false);
|
|
10333
10418
|
const [recordsOpen, setRecordsOpen] = (0, import_react61.useState)(false);
|
|
10334
10419
|
const [recordTab, setRecordTab] = (0, import_react61.useState)("export");
|
|
10335
10420
|
const [transferRecords, setTransferRecords] = (0, import_react61.useState)([]);
|
|
@@ -10425,7 +10510,6 @@ var DataManagementList = ({
|
|
|
10425
10510
|
}).catch(() => void 0);
|
|
10426
10511
|
if (!mounted) return;
|
|
10427
10512
|
const resolved = normalizeColumnConfig(saved, allFields);
|
|
10428
|
-
const resolvedDetailOpenMode = detailPageUrlBuilder ? resolved.detailOpenMode : "drawer";
|
|
10429
10513
|
const nextSearchKeyWord = saved?.filter?.searchKeyWord || "";
|
|
10430
10514
|
const nextFilterGroup = hydrateFilterGroup(saved?.filter?.group);
|
|
10431
10515
|
setFields(allFields);
|
|
@@ -10436,7 +10520,7 @@ var DataManagementList = ({
|
|
|
10436
10520
|
setLockFieldIds(resolved.lockFieldIds);
|
|
10437
10521
|
setSort(resolved.sort);
|
|
10438
10522
|
setDensity(resolved.density);
|
|
10439
|
-
setDetailOpenMode(
|
|
10523
|
+
setDetailOpenMode(resolved.detailOpenMode);
|
|
10440
10524
|
setPageSize(resolved.pageSize);
|
|
10441
10525
|
setSearchKeyWord(nextSearchKeyWord);
|
|
10442
10526
|
setFilterGroup(nextFilterGroup);
|
|
@@ -10458,7 +10542,7 @@ var DataManagementList = ({
|
|
|
10458
10542
|
return () => {
|
|
10459
10543
|
mounted = false;
|
|
10460
10544
|
};
|
|
10461
|
-
}, [appType, configScope,
|
|
10545
|
+
}, [appType, configScope, formUuid, loadData, menuFormUuid, request]);
|
|
10462
10546
|
const persistConfig = (0, import_react61.useCallback)(
|
|
10463
10547
|
async (patch) => {
|
|
10464
10548
|
const nextConfig = { ...config, ...patch };
|
|
@@ -10524,20 +10608,23 @@ var DataManagementList = ({
|
|
|
10524
10608
|
import_antd32.message.warning("\u5F53\u524D\u8BB0\u5F55\u7F3A\u5C11\u5B9E\u4F8B ID\uFF0C\u65E0\u6CD5\u6253\u5F00\u8BE6\u60C5");
|
|
10525
10609
|
return;
|
|
10526
10610
|
}
|
|
10527
|
-
if (detailOpenMode === "newPage" &&
|
|
10528
|
-
const detailUrl = detailPageUrlBuilder({ record, formInstanceId: String(formInstanceId) })
|
|
10611
|
+
if (detailOpenMode === "newPage" && typeof window !== "undefined") {
|
|
10612
|
+
const detailUrl = detailPageUrlBuilder?.({ record, formInstanceId: String(formInstanceId) }) || buildDefaultDetailUrl({
|
|
10613
|
+
appType,
|
|
10614
|
+
formUuid,
|
|
10615
|
+
formType,
|
|
10616
|
+
formInstanceId: String(formInstanceId),
|
|
10617
|
+
basePath: detailBasePath
|
|
10618
|
+
});
|
|
10529
10619
|
if (detailUrl) {
|
|
10530
10620
|
window.open(detailUrl, "_blank");
|
|
10531
10621
|
return;
|
|
10532
10622
|
}
|
|
10533
10623
|
}
|
|
10534
|
-
if (detailOpenMode === "newPage" && !detailPageUrlBuilder) {
|
|
10535
|
-
setDetailOpenMode("drawer");
|
|
10536
|
-
}
|
|
10537
10624
|
setActiveRecord(record);
|
|
10538
10625
|
setDetailOpen(true);
|
|
10539
10626
|
},
|
|
10540
|
-
[detailOpenMode, detailPageUrlBuilder]
|
|
10627
|
+
[appType, detailBasePath, detailOpenMode, detailPageUrlBuilder, formType, formUuid]
|
|
10541
10628
|
);
|
|
10542
10629
|
const handleDelete = (0, import_react61.useCallback)(
|
|
10543
10630
|
async (ids) => {
|
|
@@ -10619,6 +10706,19 @@ var DataManagementList = ({
|
|
|
10619
10706
|
setExporting(false);
|
|
10620
10707
|
}
|
|
10621
10708
|
};
|
|
10709
|
+
const handleDownloadTemplate = async () => {
|
|
10710
|
+
setTemplateDownloading(true);
|
|
10711
|
+
try {
|
|
10712
|
+
const response = await downloadDataManagementImportTemplate(request, { appType, formUuid });
|
|
10713
|
+
await downloadBlobResponse(response, `\u5BFC\u5165\u6A21\u677F-${formUuid}.xlsx`);
|
|
10714
|
+
import_antd32.message.success("\u6A21\u677F\u4E0B\u8F7D\u5DF2\u5F00\u59CB");
|
|
10715
|
+
} catch (error) {
|
|
10716
|
+
console.error("[DataManagementList] download template failed:", error);
|
|
10717
|
+
import_antd32.message.error(error instanceof Error ? error.message : "\u4E0B\u8F7D\u5BFC\u5165\u6A21\u677F\u5931\u8D25");
|
|
10718
|
+
} finally {
|
|
10719
|
+
setTemplateDownloading(false);
|
|
10720
|
+
}
|
|
10721
|
+
};
|
|
10622
10722
|
const loadTransferRecords = async (type) => {
|
|
10623
10723
|
setRecordTab(type);
|
|
10624
10724
|
setRecordsOpen(true);
|
|
@@ -10670,7 +10770,6 @@ var DataManagementList = ({
|
|
|
10670
10770
|
width: columnWidth,
|
|
10671
10771
|
fixed: lockFieldIds.includes(field.fieldId) ? "left" : void 0,
|
|
10672
10772
|
ellipsis: true,
|
|
10673
|
-
sorter: true,
|
|
10674
10773
|
render: (value) => renderCellValue(value, field)
|
|
10675
10774
|
};
|
|
10676
10775
|
}) || [];
|
|
@@ -10907,18 +11006,11 @@ var DataManagementList = ({
|
|
|
10907
11006
|
showSizeChanger: true,
|
|
10908
11007
|
showTotal: (count) => `\u5171 ${count} \u6761`
|
|
10909
11008
|
},
|
|
10910
|
-
onChange: (pagination
|
|
10911
|
-
const sorters = Array.isArray(sorter) ? sorter : [sorter];
|
|
10912
|
-
const nextSort = sorters.filter((item) => item?.field && item?.order).map((item) => ({
|
|
10913
|
-
id: String(item.field),
|
|
10914
|
-
isAsc: item.order === "ascend" ? "y" : "n"
|
|
10915
|
-
}));
|
|
10916
|
-
setSort(nextSort);
|
|
10917
|
-
persistConfig({ sort: nextSort });
|
|
11009
|
+
onChange: (pagination) => {
|
|
10918
11010
|
loadData({
|
|
10919
11011
|
current: pagination.current || 1,
|
|
10920
11012
|
pageSize: pagination.pageSize || pageSize,
|
|
10921
|
-
sort
|
|
11013
|
+
sort
|
|
10922
11014
|
});
|
|
10923
11015
|
}
|
|
10924
11016
|
}
|
|
@@ -10963,27 +11055,6 @@ var DataManagementList = ({
|
|
|
10963
11055
|
}
|
|
10964
11056
|
)
|
|
10965
11057
|
] }),
|
|
10966
|
-
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { children: [
|
|
10967
|
-
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "mb-2 text-sm font-medium text-ant-color-text", children: "\u5217\u5BBD" }),
|
|
10968
|
-
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "grid max-h-56 gap-2 overflow-auto rounded-lg border border-ant-border-secondary p-3 md:grid-cols-2", children: showFields.map((fieldId) => {
|
|
10969
|
-
const field = fields.find((item) => item.fieldId === fieldId);
|
|
10970
|
-
const width = widths[fieldId] || field?.width || 160;
|
|
10971
|
-
return /* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: "flex items-center justify-between gap-3", children: [
|
|
10972
|
-
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("span", { className: "min-w-0 truncate text-sm text-ant-color-text-secondary", children: field?.label || fieldId }),
|
|
10973
|
-
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
10974
|
-
import_antd32.InputNumber,
|
|
10975
|
-
{
|
|
10976
|
-
min: 96,
|
|
10977
|
-
max: 520,
|
|
10978
|
-
value: width,
|
|
10979
|
-
addonAfter: "px",
|
|
10980
|
-
onChange: (value) => updateColumnWidth(fieldId, Number(value || 160)),
|
|
10981
|
-
onBlur: () => commitColumnWidth(fieldId, widthsRef.current[fieldId] || width)
|
|
10982
|
-
}
|
|
10983
|
-
)
|
|
10984
|
-
] }, fieldId);
|
|
10985
|
-
}) })
|
|
10986
|
-
] }),
|
|
10987
11058
|
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { children: [
|
|
10988
11059
|
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "mb-2 text-sm font-medium text-ant-color-text", children: "\u51BB\u7ED3\u5217" }),
|
|
10989
11060
|
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
@@ -11065,10 +11136,10 @@ var DataManagementList = ({
|
|
|
11065
11136
|
{
|
|
11066
11137
|
block: true,
|
|
11067
11138
|
value: detailOpenMode,
|
|
11068
|
-
options:
|
|
11139
|
+
options: [
|
|
11069
11140
|
{ label: "\u62BD\u5C49", value: "drawer" },
|
|
11070
11141
|
{ label: "\u65B0\u9875", value: "newPage" }
|
|
11071
|
-
]
|
|
11142
|
+
],
|
|
11072
11143
|
onChange: (value) => setDetailOpenMode(value)
|
|
11073
11144
|
}
|
|
11074
11145
|
)
|
|
@@ -11174,6 +11245,21 @@ var DataManagementList = ({
|
|
|
11174
11245
|
okButtonProps: { disabled: !importBase64 },
|
|
11175
11246
|
okText: "\u786E\u8BA4\u5BFC\u5165",
|
|
11176
11247
|
children: [
|
|
11248
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { className: "mb-3 flex flex-col gap-3 rounded-lg border border-ant-border-secondary bg-ant-bg-container px-4 py-3 md:flex-row md:items-center md:justify-between", children: [
|
|
11249
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsxs)("div", { children: [
|
|
11250
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "text-sm font-medium text-ant-color-text", children: "\u5BFC\u5165\u6A21\u677F" }),
|
|
11251
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)("div", { className: "mt-1 text-xs text-ant-color-text-secondary", children: "\u5148\u4E0B\u8F7D\u6A21\u677F\u586B\u5199\u6570\u636E\uFF0C\u518D\u4E0A\u4F20 Excel \u6587\u4EF6\u5BFC\u5165" })
|
|
11252
|
+
] }),
|
|
11253
|
+
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
11254
|
+
import_antd32.Button,
|
|
11255
|
+
{
|
|
11256
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_icons11.DownloadOutlined, {}),
|
|
11257
|
+
loading: templateDownloading,
|
|
11258
|
+
onClick: handleDownloadTemplate,
|
|
11259
|
+
children: "\u4E0B\u8F7D\u5BFC\u5165\u6A21\u677F"
|
|
11260
|
+
}
|
|
11261
|
+
)
|
|
11262
|
+
] }),
|
|
11177
11263
|
/* @__PURE__ */ (0, import_jsx_runtime89.jsx)(
|
|
11178
11264
|
import_antd32.Upload.Dragger,
|
|
11179
11265
|
{
|
|
@@ -12206,6 +12292,7 @@ var ProcessDetailTemplate = (props) => {
|
|
|
12206
12292
|
defineFormSchema,
|
|
12207
12293
|
deleteDataManagementRows,
|
|
12208
12294
|
deleteFormData,
|
|
12295
|
+
downloadDataManagementImportTemplate,
|
|
12209
12296
|
evaluateEffects,
|
|
12210
12297
|
exportDataManagementRows,
|
|
12211
12298
|
extractFormValues,
|