openxiangda 1.0.122 → 1.0.124
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/openxiangda-skills/references/notifications.md +21 -0
- package/package.json +1 -1
- package/packages/sdk/dist/runtime/index.cjs +128 -10
- package/packages/sdk/dist/runtime/index.cjs.map +1 -1
- package/packages/sdk/dist/runtime/index.d.mts +1 -1
- package/packages/sdk/dist/runtime/index.d.ts +1 -1
- package/packages/sdk/dist/runtime/index.mjs +176 -58
- package/packages/sdk/dist/runtime/index.mjs.map +1 -1
- package/packages/sdk/dist/runtime/react.cjs +130 -12
- package/packages/sdk/dist/runtime/react.cjs.map +1 -1
- package/packages/sdk/dist/runtime/react.d.mts +64 -4
- package/packages/sdk/dist/runtime/react.d.ts +64 -4
- package/packages/sdk/dist/runtime/react.mjs +131 -13
- package/packages/sdk/dist/runtime/react.mjs.map +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PageContext, PageInfo, PageBridgeApi } from './react.mjs';
|
|
2
|
-
export { ApiPermissionListParams, AppAuthClient, AppFunctionConnectorApi, AppFunctionContext, AppFunctionDataViewApi, AppFunctionFormApi, AppFunctionFormGetByIdParams, AppFunctionFormQueryParams, AppFunctionFormWriteParams, AppFunctionNotificationApi, AppFunctionOperatorInfo, AppFunctionPermissionContext, AppFunctionRuntimeContext, ApproveTaskParams, AssignPermissionsParams, AssignRolesParams, AuthChallengePayload, AuthClientError, AuthClientErrorOptions, AuthClientOptions, AuthErrorExtra, AuthLogoutRedirectOptions, AuthMethod, AuthMethodType, AuthTokenData, AuthUser, BatchAddUsersToRoleParams, BatchSendNotificationByTypeParams, ChangeUserRoleParams, ConnectorCallParams, ConnectorInvokeParams, ConnectorInvokeResult, ConnectorRequestBodyType, ConnectorResponseType, CreateApiPermissionParams, CreateFormPermissionGroupDto, CreatePagePermissionGroupDto, CreateRoleParams, CreateUiPermissionParams, CreateUserParams, CurrentUserDepartmentParents, CustomPageEntryConfig, CustomPageEntryMode, DataManagementConfigParams, DataManagementFilterState, DataPermissionConditionDto, DataPermissionDto, DataPermissionRuleDto, DataViewQueryParams, DataViewQueryResult, DataViewStatsParams, DingTalkLoginInput, ExecuteProcessOperationInput, FieldAccessLevel, FieldAccessPolicyDto, FieldAccessPolicyItemDto, FieldPermissionDto, FindNotificationConfigParams, FormAdvancedSearchParams, FormChangeRecordParams, FormCreateParams, FormExportParams, FormGetDetailParams, FormImportParams, FormPermissionGroup, FormRemoveParams, FormSearchParams, FormUpdateParams, FunctionInvokeParams, FunctionInvokeResult, GetParentDepartmentsOptions, GetProcessInstanceParams, GetUserRolesParams, GuestLoginInput, ImportExportRecordDownloadParams, ImportExportRecordQuery, InitiatorApproverSelector, InstanceStatus, LoginMethodsResult, LoginPage, LoginPageProps, NotificationChannel, NotificationChannelConfig, NotificationChannelsConfig, NotificationConfigLevel, NotificationMessageRecord, NotificationTemplate, NotificationTemplatePreview, NotificationTypeConfig, OpenXiangdaPageProvider, OpenXiangdaPageProviderProps, OpenXiangdaProvider, OpenXiangdaProviderProps, PageApiPermissionRecord, PageApiResponse, PageAppInfo, PageBinaryResponse, PageDataManagementConfig, PageDataSourceDescriptor, PageDepartmentInfo, PageDepartmentRecord, PageHttpMethod, PageListResult, PageMessageApi, PageModalApi, PageNavigationApi, PageOffsetListResult, PagePermissionGroup, PagePermissionInfo, PageProvider, PageQueryValue, PageRequestOptions, PageRoleRecord, PageRouteInfo, PageScope, PageSdk, PageSdkError, PageSdkMeta, PageTransportDownloadPayload, PageTransportRequestPayload, PageUiPermissionRecord, PageUiPermissionType, PageUserInfo, PageUserRecord, PageUserType, PasswordLoginInput, PermissionBoundary, PermissionBoundaryFallback, PermissionBoundaryFallbackState, PermissionBoundaryProps, PhoneCodeInput, PhoneCodeLoginInput, PhoneCodeRegisterInput, PhoneCodeSendResult, PreviewNotificationTemplateParams, ProcessActionBar, ProcessActionBarProps, ProcessApproveAction, ProcessCapabilities, ProcessCapabilityOperation, ProcessInstanceLookupParams, ProcessPreviewPanel, ProcessPreviewPanelProps, ProcessTimeline, ProcessTimelineProps, PublicAccessClaim, PublicAccessClient, PublicAccessClientError, PublicAccessClientOptions, PublicAccessGate, PublicAccessGateProps, PublicAccessSessionData, PublicAccessSessionInput, QueryFormPermissionGroupDto, QueryPagePermissionGroupDto, RefreshInput, ResolveLoginUrlInput, ResolveProcessCapabilitiesParams, RoleListParams, RoleUsersParams, RouteAccessResult, RuntimeBootstrap, RuntimeErrorSnapshot, RuntimeErrorType, RuntimeLogoutOptions, RuntimeMenuItem, RuntimePagePermissions, RuntimeRedirectLoginOptions, RuntimeRequestError, RuntimeRequestState, RuntimeResolveLoginOptions, SaveDataManagementConfigParams, SearchComponentName, SearchExpression, SearchFieldKey, SearchGroup, SearchLogic, SearchOperator, SearchRule, SearchSortItem, SearchSystemField, SendNotificationByTypeParams, SendNotificationResult, SsoLoginUrlInput, SsoLoginUrlResult, SubFormRule, SwitchAppRoleParams, SwitchPlatformRoleParams, TerminateProcessInstanceParams, TriggerCallbackTaskParams, UiPermissionListParams, UpdateApiPermissionParams, UpdateFormPermissionGroupDto, UpdatePagePermissionGroupDto, UpdateRoleParams, UpdateUiPermissionParams, UpdateUserParams, UseAuthOptions, UseCanAccessRouteInput, UseLoginMethodsState, UseProcessActionsOptions, UseProcessActionsReturn, UseProcessCapabilitiesOptions, UseProcessCapabilitiesReturn, UsePublicAccessOptions, UsePublicAccessState, UserListParams, UserMenuPermissionsResponse, ValidateUserParams, ViewFieldPermissionValue, ViewOperationPermission, ViewPermissionSummary, WorkflowApproveParams, WorkflowCapabilityActionKey, WorkflowDefinitionByFormParams, WorkflowInitiatorSelectCandidatesParams, WorkflowInitiatorSelectRequirementsParams, WorkflowPreviewParams, WorkflowResubmitInitiatorSelectRequirementsParams, WorkflowResubmitParams, WorkflowReturnParams, WorkflowSaveTaskParams, WorkflowStartFromExistingInstanceParams, WorkflowTaskParams, WorkflowTransferParams, WorkflowWithdrawParams, createAuthClient, createPageSdk, createPublicAccessClient, createReactPage, getAuthErrorExtra, getAuthErrorReason, isAuthChallengeRequired, isAuthClientError, useAppMenus, useAuth, useCanAccessRoute, useCurrentUser, useDataSource, useFormViewPermissions, useLoginMethods, useMessage, useModal, useNavigation, useOpenXiangda, usePageContext, usePageProps, usePageRoute, usePageSdk, usePermission, useProcessActions, useProcessCapabilities, usePublicAccess, useRuntimeAuth, useRuntimeBootstrap } from './react.mjs';
|
|
2
|
+
export { ApiPermissionListParams, AppAuthClient, AppFunctionConnectorApi, AppFunctionContext, AppFunctionDataViewApi, AppFunctionFormApi, AppFunctionFormGetByIdParams, AppFunctionFormQueryParams, AppFunctionFormWriteParams, AppFunctionNotificationApi, AppFunctionOperatorInfo, AppFunctionPermissionContext, AppFunctionRuntimeContext, ApproveTaskParams, AssignPermissionsParams, AssignRolesParams, AuthChallengePayload, AuthClientError, AuthClientErrorOptions, AuthClientOptions, AuthErrorExtra, AuthLogoutRedirectOptions, AuthMethod, AuthMethodType, AuthTokenData, AuthUser, BatchAddUsersToRoleParams, BatchSendNotificationByTypeParams, ChangeUserRoleParams, ConnectorCallParams, ConnectorInvokeParams, ConnectorInvokeResult, ConnectorRequestBodyType, ConnectorResponseType, CreateApiPermissionParams, CreateFormPermissionGroupDto, CreatePagePermissionGroupDto, CreateRoleParams, CreateUiPermissionParams, CreateUserParams, CurrentUserDepartmentParents, CustomPageEntryConfig, CustomPageEntryMode, DataManagementConfigParams, DataManagementFilterState, DataPermissionConditionDto, DataPermissionDto, DataPermissionRuleDto, DataViewQueryParams, DataViewQueryResult, DataViewStatsParams, DingTalkLoginInput, ExecuteProcessOperationInput, FieldAccessLevel, FieldAccessPolicyDto, FieldAccessPolicyItemDto, FieldPermissionDto, FindNotificationConfigParams, FormAdvancedSearchParams, FormChangeRecordParams, FormCreateParams, FormExportParams, FormGetDetailParams, FormImportParams, FormPermissionGroup, FormRemoveParams, FormSearchParams, FormUpdateParams, FunctionInvokeParams, FunctionInvokeResult, GetParentDepartmentsOptions, GetProcessInstanceParams, GetUserRolesParams, GuestLoginInput, ImportExportRecordDownloadParams, ImportExportRecordQuery, InitiatorApproverSelector, InstanceStatus, ListNotificationInboxParams, LoginMethodsResult, LoginPage, LoginPageProps, MarkAllNotificationReadResult, NotificationChannel, NotificationChannelConfig, NotificationChannelsConfig, NotificationConfigLevel, NotificationInboxListResult, NotificationInboxMessage, NotificationInboxReadStatus, NotificationMessageRecord, NotificationTemplate, NotificationTemplatePreview, NotificationTypeConfig, NotificationUnreadCountResult, OpenXiangdaPageProvider, OpenXiangdaPageProviderProps, OpenXiangdaProvider, OpenXiangdaProviderProps, PageApiPermissionRecord, PageApiResponse, PageAppInfo, PageBinaryResponse, PageDataManagementConfig, PageDataSourceDescriptor, PageDepartmentInfo, PageDepartmentRecord, PageHttpMethod, PageListResult, PageMessageApi, PageModalApi, PageNavigationApi, PageOffsetListResult, PagePermissionGroup, PagePermissionInfo, PageProvider, PageQueryValue, PageRequestOptions, PageRoleRecord, PageRouteInfo, PageScope, PageSdk, PageSdkError, PageSdkMeta, PageTransportDownloadPayload, PageTransportRequestPayload, PageUiPermissionRecord, PageUiPermissionType, PageUserInfo, PageUserRecord, PageUserType, PasswordLoginInput, PermissionBoundary, PermissionBoundaryFallback, PermissionBoundaryFallbackState, PermissionBoundaryProps, PhoneCodeInput, PhoneCodeLoginInput, PhoneCodeRegisterInput, PhoneCodeSendResult, PreviewNotificationTemplateParams, ProcessActionBar, ProcessActionBarProps, ProcessApproveAction, ProcessCapabilities, ProcessCapabilityOperation, ProcessInstanceLookupParams, ProcessPreviewPanel, ProcessPreviewPanelProps, ProcessTimeline, ProcessTimelineProps, PublicAccessClaim, PublicAccessClient, PublicAccessClientError, PublicAccessClientOptions, PublicAccessGate, PublicAccessGateProps, PublicAccessSessionData, PublicAccessSessionInput, QueryFormPermissionGroupDto, QueryPagePermissionGroupDto, RefreshInput, ResolveLoginUrlInput, ResolveProcessCapabilitiesParams, RoleListParams, RoleUsersParams, RouteAccessResult, RuntimeBootstrap, RuntimeErrorSnapshot, RuntimeErrorType, RuntimeLogoutOptions, RuntimeMenuItem, RuntimePagePermissions, RuntimeRedirectLoginOptions, RuntimeRequestError, RuntimeRequestState, RuntimeResolveLoginOptions, SaveDataManagementConfigParams, SearchComponentName, SearchExpression, SearchFieldKey, SearchGroup, SearchLogic, SearchOperator, SearchRule, SearchSortItem, SearchSystemField, SendNotificationByTypeParams, SendNotificationResult, SsoLoginUrlInput, SsoLoginUrlResult, SubFormRule, SwitchAppRoleParams, SwitchPlatformRoleParams, TerminateProcessInstanceParams, TriggerCallbackTaskParams, UiPermissionListParams, UpdateApiPermissionParams, UpdateFormPermissionGroupDto, UpdatePagePermissionGroupDto, UpdateRoleParams, UpdateUiPermissionParams, UpdateUserParams, UseAuthOptions, UseCanAccessRouteInput, UseLoginMethodsState, UseProcessActionsOptions, UseProcessActionsReturn, UseProcessCapabilitiesOptions, UseProcessCapabilitiesReturn, UsePublicAccessOptions, UsePublicAccessState, UserListParams, UserMenuPermissionsResponse, ValidateUserParams, ViewFieldPermissionValue, ViewOperationPermission, ViewPermissionSummary, WorkflowApproveParams, WorkflowCapabilityActionKey, WorkflowDefinitionByFormParams, WorkflowInitiatorSelectCandidatesParams, WorkflowInitiatorSelectRequirementsParams, WorkflowPreviewParams, WorkflowResubmitInitiatorSelectRequirementsParams, WorkflowResubmitParams, WorkflowReturnParams, WorkflowSaveTaskParams, WorkflowStartFromExistingInstanceParams, WorkflowTaskParams, WorkflowTransferParams, WorkflowWithdrawParams, createAuthClient, createPageSdk, createPublicAccessClient, createReactPage, getAuthErrorExtra, getAuthErrorReason, isAuthChallengeRequired, isAuthClientError, useAppMenus, useAuth, useCanAccessRoute, useCurrentUser, useDataSource, useFormViewPermissions, useLoginMethods, useMessage, useModal, useNavigation, useOpenXiangda, usePageContext, usePageProps, usePageRoute, usePageSdk, usePermission, useProcessActions, useProcessCapabilities, usePublicAccess, useRuntimeAuth, useRuntimeBootstrap } from './react.mjs';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
import { a1 as FormSchema, _ as FormRuntimeApi, $ as FormRuntimeApiConfig, M as FieldDefinition } from '../ProcessPreview-Kexdosgu.mjs';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PageContext, PageInfo, PageBridgeApi } from './react.js';
|
|
2
|
-
export { ApiPermissionListParams, AppAuthClient, AppFunctionConnectorApi, AppFunctionContext, AppFunctionDataViewApi, AppFunctionFormApi, AppFunctionFormGetByIdParams, AppFunctionFormQueryParams, AppFunctionFormWriteParams, AppFunctionNotificationApi, AppFunctionOperatorInfo, AppFunctionPermissionContext, AppFunctionRuntimeContext, ApproveTaskParams, AssignPermissionsParams, AssignRolesParams, AuthChallengePayload, AuthClientError, AuthClientErrorOptions, AuthClientOptions, AuthErrorExtra, AuthLogoutRedirectOptions, AuthMethod, AuthMethodType, AuthTokenData, AuthUser, BatchAddUsersToRoleParams, BatchSendNotificationByTypeParams, ChangeUserRoleParams, ConnectorCallParams, ConnectorInvokeParams, ConnectorInvokeResult, ConnectorRequestBodyType, ConnectorResponseType, CreateApiPermissionParams, CreateFormPermissionGroupDto, CreatePagePermissionGroupDto, CreateRoleParams, CreateUiPermissionParams, CreateUserParams, CurrentUserDepartmentParents, CustomPageEntryConfig, CustomPageEntryMode, DataManagementConfigParams, DataManagementFilterState, DataPermissionConditionDto, DataPermissionDto, DataPermissionRuleDto, DataViewQueryParams, DataViewQueryResult, DataViewStatsParams, DingTalkLoginInput, ExecuteProcessOperationInput, FieldAccessLevel, FieldAccessPolicyDto, FieldAccessPolicyItemDto, FieldPermissionDto, FindNotificationConfigParams, FormAdvancedSearchParams, FormChangeRecordParams, FormCreateParams, FormExportParams, FormGetDetailParams, FormImportParams, FormPermissionGroup, FormRemoveParams, FormSearchParams, FormUpdateParams, FunctionInvokeParams, FunctionInvokeResult, GetParentDepartmentsOptions, GetProcessInstanceParams, GetUserRolesParams, GuestLoginInput, ImportExportRecordDownloadParams, ImportExportRecordQuery, InitiatorApproverSelector, InstanceStatus, LoginMethodsResult, LoginPage, LoginPageProps, NotificationChannel, NotificationChannelConfig, NotificationChannelsConfig, NotificationConfigLevel, NotificationMessageRecord, NotificationTemplate, NotificationTemplatePreview, NotificationTypeConfig, OpenXiangdaPageProvider, OpenXiangdaPageProviderProps, OpenXiangdaProvider, OpenXiangdaProviderProps, PageApiPermissionRecord, PageApiResponse, PageAppInfo, PageBinaryResponse, PageDataManagementConfig, PageDataSourceDescriptor, PageDepartmentInfo, PageDepartmentRecord, PageHttpMethod, PageListResult, PageMessageApi, PageModalApi, PageNavigationApi, PageOffsetListResult, PagePermissionGroup, PagePermissionInfo, PageProvider, PageQueryValue, PageRequestOptions, PageRoleRecord, PageRouteInfo, PageScope, PageSdk, PageSdkError, PageSdkMeta, PageTransportDownloadPayload, PageTransportRequestPayload, PageUiPermissionRecord, PageUiPermissionType, PageUserInfo, PageUserRecord, PageUserType, PasswordLoginInput, PermissionBoundary, PermissionBoundaryFallback, PermissionBoundaryFallbackState, PermissionBoundaryProps, PhoneCodeInput, PhoneCodeLoginInput, PhoneCodeRegisterInput, PhoneCodeSendResult, PreviewNotificationTemplateParams, ProcessActionBar, ProcessActionBarProps, ProcessApproveAction, ProcessCapabilities, ProcessCapabilityOperation, ProcessInstanceLookupParams, ProcessPreviewPanel, ProcessPreviewPanelProps, ProcessTimeline, ProcessTimelineProps, PublicAccessClaim, PublicAccessClient, PublicAccessClientError, PublicAccessClientOptions, PublicAccessGate, PublicAccessGateProps, PublicAccessSessionData, PublicAccessSessionInput, QueryFormPermissionGroupDto, QueryPagePermissionGroupDto, RefreshInput, ResolveLoginUrlInput, ResolveProcessCapabilitiesParams, RoleListParams, RoleUsersParams, RouteAccessResult, RuntimeBootstrap, RuntimeErrorSnapshot, RuntimeErrorType, RuntimeLogoutOptions, RuntimeMenuItem, RuntimePagePermissions, RuntimeRedirectLoginOptions, RuntimeRequestError, RuntimeRequestState, RuntimeResolveLoginOptions, SaveDataManagementConfigParams, SearchComponentName, SearchExpression, SearchFieldKey, SearchGroup, SearchLogic, SearchOperator, SearchRule, SearchSortItem, SearchSystemField, SendNotificationByTypeParams, SendNotificationResult, SsoLoginUrlInput, SsoLoginUrlResult, SubFormRule, SwitchAppRoleParams, SwitchPlatformRoleParams, TerminateProcessInstanceParams, TriggerCallbackTaskParams, UiPermissionListParams, UpdateApiPermissionParams, UpdateFormPermissionGroupDto, UpdatePagePermissionGroupDto, UpdateRoleParams, UpdateUiPermissionParams, UpdateUserParams, UseAuthOptions, UseCanAccessRouteInput, UseLoginMethodsState, UseProcessActionsOptions, UseProcessActionsReturn, UseProcessCapabilitiesOptions, UseProcessCapabilitiesReturn, UsePublicAccessOptions, UsePublicAccessState, UserListParams, UserMenuPermissionsResponse, ValidateUserParams, ViewFieldPermissionValue, ViewOperationPermission, ViewPermissionSummary, WorkflowApproveParams, WorkflowCapabilityActionKey, WorkflowDefinitionByFormParams, WorkflowInitiatorSelectCandidatesParams, WorkflowInitiatorSelectRequirementsParams, WorkflowPreviewParams, WorkflowResubmitInitiatorSelectRequirementsParams, WorkflowResubmitParams, WorkflowReturnParams, WorkflowSaveTaskParams, WorkflowStartFromExistingInstanceParams, WorkflowTaskParams, WorkflowTransferParams, WorkflowWithdrawParams, createAuthClient, createPageSdk, createPublicAccessClient, createReactPage, getAuthErrorExtra, getAuthErrorReason, isAuthChallengeRequired, isAuthClientError, useAppMenus, useAuth, useCanAccessRoute, useCurrentUser, useDataSource, useFormViewPermissions, useLoginMethods, useMessage, useModal, useNavigation, useOpenXiangda, usePageContext, usePageProps, usePageRoute, usePageSdk, usePermission, useProcessActions, useProcessCapabilities, usePublicAccess, useRuntimeAuth, useRuntimeBootstrap } from './react.js';
|
|
2
|
+
export { ApiPermissionListParams, AppAuthClient, AppFunctionConnectorApi, AppFunctionContext, AppFunctionDataViewApi, AppFunctionFormApi, AppFunctionFormGetByIdParams, AppFunctionFormQueryParams, AppFunctionFormWriteParams, AppFunctionNotificationApi, AppFunctionOperatorInfo, AppFunctionPermissionContext, AppFunctionRuntimeContext, ApproveTaskParams, AssignPermissionsParams, AssignRolesParams, AuthChallengePayload, AuthClientError, AuthClientErrorOptions, AuthClientOptions, AuthErrorExtra, AuthLogoutRedirectOptions, AuthMethod, AuthMethodType, AuthTokenData, AuthUser, BatchAddUsersToRoleParams, BatchSendNotificationByTypeParams, ChangeUserRoleParams, ConnectorCallParams, ConnectorInvokeParams, ConnectorInvokeResult, ConnectorRequestBodyType, ConnectorResponseType, CreateApiPermissionParams, CreateFormPermissionGroupDto, CreatePagePermissionGroupDto, CreateRoleParams, CreateUiPermissionParams, CreateUserParams, CurrentUserDepartmentParents, CustomPageEntryConfig, CustomPageEntryMode, DataManagementConfigParams, DataManagementFilterState, DataPermissionConditionDto, DataPermissionDto, DataPermissionRuleDto, DataViewQueryParams, DataViewQueryResult, DataViewStatsParams, DingTalkLoginInput, ExecuteProcessOperationInput, FieldAccessLevel, FieldAccessPolicyDto, FieldAccessPolicyItemDto, FieldPermissionDto, FindNotificationConfigParams, FormAdvancedSearchParams, FormChangeRecordParams, FormCreateParams, FormExportParams, FormGetDetailParams, FormImportParams, FormPermissionGroup, FormRemoveParams, FormSearchParams, FormUpdateParams, FunctionInvokeParams, FunctionInvokeResult, GetParentDepartmentsOptions, GetProcessInstanceParams, GetUserRolesParams, GuestLoginInput, ImportExportRecordDownloadParams, ImportExportRecordQuery, InitiatorApproverSelector, InstanceStatus, ListNotificationInboxParams, LoginMethodsResult, LoginPage, LoginPageProps, MarkAllNotificationReadResult, NotificationChannel, NotificationChannelConfig, NotificationChannelsConfig, NotificationConfigLevel, NotificationInboxListResult, NotificationInboxMessage, NotificationInboxReadStatus, NotificationMessageRecord, NotificationTemplate, NotificationTemplatePreview, NotificationTypeConfig, NotificationUnreadCountResult, OpenXiangdaPageProvider, OpenXiangdaPageProviderProps, OpenXiangdaProvider, OpenXiangdaProviderProps, PageApiPermissionRecord, PageApiResponse, PageAppInfo, PageBinaryResponse, PageDataManagementConfig, PageDataSourceDescriptor, PageDepartmentInfo, PageDepartmentRecord, PageHttpMethod, PageListResult, PageMessageApi, PageModalApi, PageNavigationApi, PageOffsetListResult, PagePermissionGroup, PagePermissionInfo, PageProvider, PageQueryValue, PageRequestOptions, PageRoleRecord, PageRouteInfo, PageScope, PageSdk, PageSdkError, PageSdkMeta, PageTransportDownloadPayload, PageTransportRequestPayload, PageUiPermissionRecord, PageUiPermissionType, PageUserInfo, PageUserRecord, PageUserType, PasswordLoginInput, PermissionBoundary, PermissionBoundaryFallback, PermissionBoundaryFallbackState, PermissionBoundaryProps, PhoneCodeInput, PhoneCodeLoginInput, PhoneCodeRegisterInput, PhoneCodeSendResult, PreviewNotificationTemplateParams, ProcessActionBar, ProcessActionBarProps, ProcessApproveAction, ProcessCapabilities, ProcessCapabilityOperation, ProcessInstanceLookupParams, ProcessPreviewPanel, ProcessPreviewPanelProps, ProcessTimeline, ProcessTimelineProps, PublicAccessClaim, PublicAccessClient, PublicAccessClientError, PublicAccessClientOptions, PublicAccessGate, PublicAccessGateProps, PublicAccessSessionData, PublicAccessSessionInput, QueryFormPermissionGroupDto, QueryPagePermissionGroupDto, RefreshInput, ResolveLoginUrlInput, ResolveProcessCapabilitiesParams, RoleListParams, RoleUsersParams, RouteAccessResult, RuntimeBootstrap, RuntimeErrorSnapshot, RuntimeErrorType, RuntimeLogoutOptions, RuntimeMenuItem, RuntimePagePermissions, RuntimeRedirectLoginOptions, RuntimeRequestError, RuntimeRequestState, RuntimeResolveLoginOptions, SaveDataManagementConfigParams, SearchComponentName, SearchExpression, SearchFieldKey, SearchGroup, SearchLogic, SearchOperator, SearchRule, SearchSortItem, SearchSystemField, SendNotificationByTypeParams, SendNotificationResult, SsoLoginUrlInput, SsoLoginUrlResult, SubFormRule, SwitchAppRoleParams, SwitchPlatformRoleParams, TerminateProcessInstanceParams, TriggerCallbackTaskParams, UiPermissionListParams, UpdateApiPermissionParams, UpdateFormPermissionGroupDto, UpdatePagePermissionGroupDto, UpdateRoleParams, UpdateUiPermissionParams, UpdateUserParams, UseAuthOptions, UseCanAccessRouteInput, UseLoginMethodsState, UseProcessActionsOptions, UseProcessActionsReturn, UseProcessCapabilitiesOptions, UseProcessCapabilitiesReturn, UsePublicAccessOptions, UsePublicAccessState, UserListParams, UserMenuPermissionsResponse, ValidateUserParams, ViewFieldPermissionValue, ViewOperationPermission, ViewPermissionSummary, WorkflowApproveParams, WorkflowCapabilityActionKey, WorkflowDefinitionByFormParams, WorkflowInitiatorSelectCandidatesParams, WorkflowInitiatorSelectRequirementsParams, WorkflowPreviewParams, WorkflowResubmitInitiatorSelectRequirementsParams, WorkflowResubmitParams, WorkflowReturnParams, WorkflowSaveTaskParams, WorkflowStartFromExistingInstanceParams, WorkflowTaskParams, WorkflowTransferParams, WorkflowWithdrawParams, createAuthClient, createPageSdk, createPublicAccessClient, createReactPage, getAuthErrorExtra, getAuthErrorReason, isAuthChallengeRequired, isAuthClientError, useAppMenus, useAuth, useCanAccessRoute, useCurrentUser, useDataSource, useFormViewPermissions, useLoginMethods, useMessage, useModal, useNavigation, useOpenXiangda, usePageContext, usePageProps, usePageRoute, usePageSdk, usePermission, useProcessActions, useProcessCapabilities, usePublicAccess, useRuntimeAuth, useRuntimeBootstrap } from './react.js';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
import { a1 as FormSchema, _ as FormRuntimeApi, $ as FormRuntimeApiConfig, M as FieldDefinition } from '../ProcessPreview-Kexdosgu.js';
|
|
@@ -2348,6 +2348,45 @@ var createPageSdk = (context) => {
|
|
|
2348
2348
|
...params,
|
|
2349
2349
|
appType: resolveAppType(context, params.appType)
|
|
2350
2350
|
}
|
|
2351
|
+
}),
|
|
2352
|
+
listInbox: (params = {}) => request({
|
|
2353
|
+
path: buildOpenXiangdaAppPath(
|
|
2354
|
+
context,
|
|
2355
|
+
params.appType,
|
|
2356
|
+
"/notifications/inbox"
|
|
2357
|
+
),
|
|
2358
|
+
method: "get",
|
|
2359
|
+
query: {
|
|
2360
|
+
page: params.page,
|
|
2361
|
+
limit: params.limit,
|
|
2362
|
+
readStatus: params.readStatus,
|
|
2363
|
+
keyword: params.keyword,
|
|
2364
|
+
templateCode: params.templateCode
|
|
2365
|
+
}
|
|
2366
|
+
}),
|
|
2367
|
+
getUnreadCount: (params = {}) => request({
|
|
2368
|
+
path: buildOpenXiangdaAppPath(
|
|
2369
|
+
context,
|
|
2370
|
+
params.appType,
|
|
2371
|
+
"/notifications/inbox/unread-count"
|
|
2372
|
+
),
|
|
2373
|
+
method: "get"
|
|
2374
|
+
}),
|
|
2375
|
+
markRead: (messageId, params = {}) => request({
|
|
2376
|
+
path: buildOpenXiangdaAppPath(
|
|
2377
|
+
context,
|
|
2378
|
+
params.appType,
|
|
2379
|
+
`/notifications/inbox/${encodePathSegment(messageId)}/read`
|
|
2380
|
+
),
|
|
2381
|
+
method: "post"
|
|
2382
|
+
}),
|
|
2383
|
+
markAllRead: (params = {}) => request({
|
|
2384
|
+
path: buildOpenXiangdaAppPath(
|
|
2385
|
+
context,
|
|
2386
|
+
params.appType,
|
|
2387
|
+
"/notifications/inbox/read-all"
|
|
2388
|
+
),
|
|
2389
|
+
method: "post"
|
|
2351
2390
|
})
|
|
2352
2391
|
};
|
|
2353
2392
|
const sdk = {
|
|
@@ -34468,10 +34507,18 @@ var OpenXiangdaProvider = ({
|
|
|
34468
34507
|
const [accessToken, setAccessTokenState] = useState61(null);
|
|
34469
34508
|
const accessTokenRef = useRef82(null);
|
|
34470
34509
|
const setAccessToken = useCallback22(
|
|
34471
|
-
(nextAccessToken) => {
|
|
34510
|
+
(nextAccessToken, options = {}) => {
|
|
34511
|
+
if (!nextAccessToken && options.clearIfToken && accessTokenRef.current?.token !== options.clearIfToken) {
|
|
34512
|
+
return;
|
|
34513
|
+
}
|
|
34472
34514
|
const normalizedAccessToken = nextAccessToken || null;
|
|
34473
|
-
|
|
34474
|
-
|
|
34515
|
+
const nextState = normalizedAccessToken ? {
|
|
34516
|
+
token: normalizedAccessToken,
|
|
34517
|
+
scope: options.scope || "default",
|
|
34518
|
+
path: options.path || null
|
|
34519
|
+
} : null;
|
|
34520
|
+
accessTokenRef.current = nextState;
|
|
34521
|
+
setAccessTokenState(nextState);
|
|
34475
34522
|
},
|
|
34476
34523
|
[]
|
|
34477
34524
|
);
|
|
@@ -34497,7 +34544,13 @@ var OpenXiangdaProvider = ({
|
|
|
34497
34544
|
return;
|
|
34498
34545
|
}
|
|
34499
34546
|
setState((prev) => ({ ...prev, loading: true, error: null }));
|
|
34500
|
-
const requestFetch = options.accessToken !== void 0 ? createAuthorizedFetch(
|
|
34547
|
+
const requestFetch = options.accessToken !== void 0 ? createAuthorizedFetch(
|
|
34548
|
+
resolvedFetch,
|
|
34549
|
+
createAccessTokenState(
|
|
34550
|
+
options.accessToken || null,
|
|
34551
|
+
options.accessTokenOptions
|
|
34552
|
+
)
|
|
34553
|
+
) : createAuthorizedFetch(resolvedFetch, accessTokenRef.current);
|
|
34501
34554
|
try {
|
|
34502
34555
|
const response = await requestFetch(
|
|
34503
34556
|
buildServiceUrl3(
|
|
@@ -34907,9 +34960,11 @@ var buildServiceUrl3 = (servicePrefix, path) => {
|
|
|
34907
34960
|
var createAuthorizedFetch = (baseFetch, accessToken) => {
|
|
34908
34961
|
if (!accessToken) return baseFetch;
|
|
34909
34962
|
return ((input, init = {}) => {
|
|
34963
|
+
const token = resolveAccessTokenForCurrentRoute(accessToken);
|
|
34964
|
+
if (!token) return baseFetch(input, init);
|
|
34910
34965
|
const headers = new Headers(init.headers || {});
|
|
34911
34966
|
if (!headers.has("authorization")) {
|
|
34912
|
-
headers.set("authorization", `Bearer ${
|
|
34967
|
+
headers.set("authorization", `Bearer ${token}`);
|
|
34913
34968
|
}
|
|
34914
34969
|
return baseFetch(input, {
|
|
34915
34970
|
...init,
|
|
@@ -34917,6 +34972,34 @@ var createAuthorizedFetch = (baseFetch, accessToken) => {
|
|
|
34917
34972
|
});
|
|
34918
34973
|
});
|
|
34919
34974
|
};
|
|
34975
|
+
var createAccessTokenState = (accessToken, options = {}) => accessToken ? {
|
|
34976
|
+
token: accessToken,
|
|
34977
|
+
scope: options.scope || "default",
|
|
34978
|
+
path: options.path || null
|
|
34979
|
+
} : null;
|
|
34980
|
+
var resolveAccessTokenForCurrentRoute = (accessToken) => {
|
|
34981
|
+
if (accessToken.scope !== "public") return accessToken.token;
|
|
34982
|
+
const scopedPath = normalizeRoutePath(accessToken.path);
|
|
34983
|
+
const currentPath = normalizeRoutePath(getCurrentPathname2());
|
|
34984
|
+
if (!scopedPath) {
|
|
34985
|
+
return isPublicRoutePath(currentPath) ? accessToken.token : null;
|
|
34986
|
+
}
|
|
34987
|
+
if (currentPath === scopedPath || isPublicRoutePath(currentPath) && currentPath.startsWith(`${scopedPath}/`)) {
|
|
34988
|
+
return accessToken.token;
|
|
34989
|
+
}
|
|
34990
|
+
return null;
|
|
34991
|
+
};
|
|
34992
|
+
var normalizeRoutePath = (path) => {
|
|
34993
|
+
const text = String(path || "").trim();
|
|
34994
|
+
if (!text) return "";
|
|
34995
|
+
try {
|
|
34996
|
+
const base = typeof window !== "undefined" ? window.location.origin : "http://localhost";
|
|
34997
|
+
return new URL(text, base).pathname.replace(/\/+$/, "") || "/";
|
|
34998
|
+
} catch {
|
|
34999
|
+
return text.split(/[?#]/, 1)[0].replace(/\/+$/, "") || "/";
|
|
35000
|
+
}
|
|
35001
|
+
};
|
|
35002
|
+
var isPublicRoutePath = (path) => /\/public(?:\/|$)/.test(path);
|
|
34920
35003
|
var readJsonPayload = async (response) => {
|
|
34921
35004
|
try {
|
|
34922
35005
|
return await response.json();
|
|
@@ -35017,6 +35100,7 @@ var attachCallback = (loginUrl, callback) => {
|
|
|
35017
35100
|
}
|
|
35018
35101
|
};
|
|
35019
35102
|
var getCurrentHref4 = () => typeof window === "undefined" ? "" : window.location.href;
|
|
35103
|
+
var getCurrentPathname2 = () => typeof window === "undefined" ? "" : window.location.pathname;
|
|
35020
35104
|
var getCurrentHostname2 = () => typeof window === "undefined" ? "" : window.location.hostname;
|
|
35021
35105
|
var getRuntimeEnv = (key) => {
|
|
35022
35106
|
const env = typeof process !== "undefined" ? process.env : void 0;
|
|
@@ -35087,7 +35171,7 @@ var resolveAppTypeFromLocation = () => {
|
|
|
35087
35171
|
};
|
|
35088
35172
|
|
|
35089
35173
|
// packages/sdk/src/runtime/react/publicAccess.tsx
|
|
35090
|
-
import { useCallback as useCallback23, useEffect as useEffect62, useMemo as useMemo43, useState as useState62 } from "react";
|
|
35174
|
+
import { useCallback as useCallback23, useEffect as useEffect62, useMemo as useMemo43, useRef as useRef83, useState as useState62 } from "react";
|
|
35091
35175
|
import { Fragment as Fragment10, jsx as jsx12 } from "react/jsx-runtime";
|
|
35092
35176
|
var usePublicAccess = (options = {}) => {
|
|
35093
35177
|
const runtime = useOpenXiangda();
|
|
@@ -35108,6 +35192,8 @@ var usePublicAccess = (options = {}) => {
|
|
|
35108
35192
|
const [session, setSession] = useState62(null);
|
|
35109
35193
|
const [error, setError] = useState62(null);
|
|
35110
35194
|
const [loading, setLoading] = useState62(Boolean(autoStart));
|
|
35195
|
+
const activeSessionRef = useRef83(null);
|
|
35196
|
+
const mountedRef = useRef83(true);
|
|
35111
35197
|
const sessionInputKey = JSON.stringify(sessionInput);
|
|
35112
35198
|
const stableSessionInput = useMemo43(() => sessionInput, [sessionInputKey]);
|
|
35113
35199
|
const client = useMemo43(
|
|
@@ -35123,15 +35209,31 @@ var usePublicAccess = (options = {}) => {
|
|
|
35123
35209
|
setLoading(true);
|
|
35124
35210
|
setError(null);
|
|
35125
35211
|
try {
|
|
35212
|
+
const resolvedPath = input.path || stableSessionInput.path || readPathFromLocation();
|
|
35126
35213
|
const data = await client.startSession({
|
|
35127
35214
|
...stableSessionInput,
|
|
35128
35215
|
...input,
|
|
35129
35216
|
ticket: input.ticket || stableSessionInput.ticket || readTicketFromLocation(),
|
|
35130
|
-
path:
|
|
35217
|
+
path: resolvedPath
|
|
35131
35218
|
});
|
|
35219
|
+
if (!mountedRef.current) return data;
|
|
35220
|
+
activeSessionRef.current = {
|
|
35221
|
+
accessToken: data.accessToken,
|
|
35222
|
+
path: resolvedPath
|
|
35223
|
+
};
|
|
35132
35224
|
setSession(data);
|
|
35133
|
-
setAccessToken(data.accessToken
|
|
35134
|
-
|
|
35225
|
+
setAccessToken(data.accessToken, {
|
|
35226
|
+
scope: "public",
|
|
35227
|
+
path: resolvedPath
|
|
35228
|
+
});
|
|
35229
|
+
await reloadRuntime({
|
|
35230
|
+
accessToken: data.accessToken,
|
|
35231
|
+
accessTokenOptions: {
|
|
35232
|
+
scope: "public",
|
|
35233
|
+
path: resolvedPath
|
|
35234
|
+
}
|
|
35235
|
+
});
|
|
35236
|
+
if (!mountedRef.current) return data;
|
|
35135
35237
|
setLoading(false);
|
|
35136
35238
|
return data;
|
|
35137
35239
|
} catch (caught) {
|
|
@@ -35139,8 +35241,10 @@ var usePublicAccess = (options = {}) => {
|
|
|
35139
35241
|
caught instanceof Error ? caught.message : "\u516C\u5F00\u8BBF\u95EE\u4F1A\u8BDD\u521B\u5EFA\u5931\u8D25",
|
|
35140
35242
|
{ payload: caught }
|
|
35141
35243
|
);
|
|
35142
|
-
|
|
35143
|
-
|
|
35244
|
+
if (mountedRef.current) {
|
|
35245
|
+
setError(nextError);
|
|
35246
|
+
setLoading(false);
|
|
35247
|
+
}
|
|
35144
35248
|
throw nextError;
|
|
35145
35249
|
}
|
|
35146
35250
|
},
|
|
@@ -35150,6 +35254,20 @@ var usePublicAccess = (options = {}) => {
|
|
|
35150
35254
|
if (!autoStart) return;
|
|
35151
35255
|
void startSession().catch(() => void 0);
|
|
35152
35256
|
}, [autoStart, startSession]);
|
|
35257
|
+
useEffect62(
|
|
35258
|
+
() => {
|
|
35259
|
+
mountedRef.current = true;
|
|
35260
|
+
return () => {
|
|
35261
|
+
mountedRef.current = false;
|
|
35262
|
+
const activeSession = activeSessionRef.current;
|
|
35263
|
+
if (!activeSession) return;
|
|
35264
|
+
activeSessionRef.current = null;
|
|
35265
|
+
setAccessToken(null, { clearIfToken: activeSession.accessToken });
|
|
35266
|
+
void reloadRuntime({ accessToken: null });
|
|
35267
|
+
};
|
|
35268
|
+
},
|
|
35269
|
+
[reloadRuntime, setAccessToken]
|
|
35270
|
+
);
|
|
35153
35271
|
return {
|
|
35154
35272
|
loading,
|
|
35155
35273
|
error,
|
|
@@ -35930,7 +36048,7 @@ function createFormRuntimeApi(config3) {
|
|
|
35930
36048
|
}
|
|
35931
36049
|
|
|
35932
36050
|
// packages/sdk/src/components/modules/DataManagementList.tsx
|
|
35933
|
-
import { useCallback as useCallback39, useEffect as useEffect101, useMemo as useMemo67, useRef as
|
|
36051
|
+
import { useCallback as useCallback39, useEffect as useEffect101, useMemo as useMemo67, useRef as useRef99, useState as useState93 } from "react";
|
|
35934
36052
|
import {
|
|
35935
36053
|
Alert as Alert3,
|
|
35936
36054
|
Button as Button16,
|
|
@@ -35972,11 +36090,11 @@ import {
|
|
|
35972
36090
|
import { useMemo as useMemo66 } from "react";
|
|
35973
36091
|
|
|
35974
36092
|
// packages/sdk/src/components/templates/FormDetailTemplate.tsx
|
|
35975
|
-
import { useCallback as useCallback31, useMemo as useMemo61, useRef as
|
|
36093
|
+
import { useCallback as useCallback31, useMemo as useMemo61, useRef as useRef93, useState as useState85 } from "react";
|
|
35976
36094
|
import dayjs19 from "dayjs";
|
|
35977
36095
|
|
|
35978
36096
|
// packages/sdk/src/components/core/FormProvider.tsx
|
|
35979
|
-
import React244, { useCallback as useCallback28, useEffect as useEffect92, useRef as
|
|
36097
|
+
import React244, { useCallback as useCallback28, useEffect as useEffect92, useRef as useRef90, useState as useState78, useMemo as useMemo59 } from "react";
|
|
35980
36098
|
|
|
35981
36099
|
// packages/sdk/src/components/core/FormContext.ts
|
|
35982
36100
|
import { createContext as createContext11, useContext as useContext17 } from "react";
|
|
@@ -36819,7 +36937,7 @@ function renderReadonlyOptions(options, coloredOptions, tagWhenPlain = false) {
|
|
|
36819
36937
|
}
|
|
36820
36938
|
|
|
36821
36939
|
// packages/sdk/src/components/fields/SelectField/useLinkedFormRemoteOptions.ts
|
|
36822
|
-
import { useCallback as useCallback24, useEffect as useEffect66, useMemo as useMemo44, useRef as
|
|
36940
|
+
import { useCallback as useCallback24, useEffect as useEffect66, useMemo as useMemo44, useRef as useRef84, useState as useState63 } from "react";
|
|
36823
36941
|
|
|
36824
36942
|
// packages/sdk/src/components/core/optionSource.ts
|
|
36825
36943
|
var DEFAULT_OPTION_PAGE_SIZE = 200;
|
|
@@ -37036,8 +37154,8 @@ function useLinkedFormRemoteOptions(optionSource, baseOptions, selectedOptions)
|
|
|
37036
37154
|
const minChars = linkedForm?.remoteSearchMinChars ?? 0;
|
|
37037
37155
|
const [remoteOptions, setRemoteOptions] = useState63(null);
|
|
37038
37156
|
const [loading, setLoading] = useState63(false);
|
|
37039
|
-
const timerRef =
|
|
37040
|
-
const requestRef =
|
|
37157
|
+
const timerRef = useRef84(null);
|
|
37158
|
+
const requestRef = useRef84(0);
|
|
37041
37159
|
const reset = useCallback24(() => {
|
|
37042
37160
|
requestRef.current += 1;
|
|
37043
37161
|
if (timerRef.current) {
|
|
@@ -41370,7 +41488,7 @@ function UserSelectField(props) {
|
|
|
41370
41488
|
import { useEffect as useEffect83 } from "react";
|
|
41371
41489
|
|
|
41372
41490
|
// packages/sdk/src/components/fields/DepartmentSelectField/DepartmentSelectFieldPC.tsx
|
|
41373
|
-
import { useEffect as useEffect81, useMemo as useMemo53, useRef as
|
|
41491
|
+
import { useEffect as useEffect81, useMemo as useMemo53, useRef as useRef85, useState as useState71 } from "react";
|
|
41374
41492
|
import { TreeSelect as TreeSelect2 } from "antd";
|
|
41375
41493
|
|
|
41376
41494
|
// packages/sdk/src/components/fields/shared/DepartmentPicker.tsx
|
|
@@ -41665,7 +41783,7 @@ function DepartmentSelectFieldPC({
|
|
|
41665
41783
|
const value = useMemo53(() => normalizeDepartmentArray(rawValue), [rawValue]);
|
|
41666
41784
|
const disabled = behavior === "DISABLED";
|
|
41667
41785
|
const configuredTreeData = treeData ?? EMPTY_TREE_DATA;
|
|
41668
|
-
const remoteLoadedRef =
|
|
41786
|
+
const remoteLoadedRef = useRef85(false);
|
|
41669
41787
|
const [loadedTreeData, setLoadedTreeData] = useState71(configuredTreeData);
|
|
41670
41788
|
const [pickerOpen, setPickerOpen] = useState71(false);
|
|
41671
41789
|
useEffect81(() => {
|
|
@@ -41773,7 +41891,7 @@ function DepartmentSelectFieldPC({
|
|
|
41773
41891
|
}
|
|
41774
41892
|
|
|
41775
41893
|
// packages/sdk/src/components/fields/DepartmentSelectField/DepartmentSelectFieldMobile.tsx
|
|
41776
|
-
import { useEffect as useEffect82, useMemo as useMemo54, useRef as
|
|
41894
|
+
import { useEffect as useEffect82, useMemo as useMemo54, useRef as useRef86, useState as useState72 } from "react";
|
|
41777
41895
|
import { jsx as jsx74, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
41778
41896
|
var EMPTY_TREE_DATA2 = [];
|
|
41779
41897
|
function toDepartmentValue2(item) {
|
|
@@ -41807,7 +41925,7 @@ function DepartmentSelectFieldMobile({
|
|
|
41807
41925
|
const disabled = behavior === "DISABLED";
|
|
41808
41926
|
const [showPicker, setShowPicker] = useState72(false);
|
|
41809
41927
|
const configuredTreeData = treeData ?? EMPTY_TREE_DATA2;
|
|
41810
|
-
const remoteLoadedRef =
|
|
41928
|
+
const remoteLoadedRef = useRef86(false);
|
|
41811
41929
|
const [loadedTreeData, setLoadedTreeData] = useState72(configuredTreeData);
|
|
41812
41930
|
useEffect82(() => {
|
|
41813
41931
|
if (configuredTreeData.length) {
|
|
@@ -42317,7 +42435,7 @@ function AddressField(props) {
|
|
|
42317
42435
|
}
|
|
42318
42436
|
|
|
42319
42437
|
// packages/sdk/src/components/fields/AssociationFormField/index.tsx
|
|
42320
|
-
import { useCallback as useCallback25, useEffect as useEffect86, useMemo as useMemo57, useRef as
|
|
42438
|
+
import { useCallback as useCallback25, useEffect as useEffect86, useMemo as useMemo57, useRef as useRef87, useState as useState74 } from "react";
|
|
42321
42439
|
import { Button as Button9, Drawer, Input as Input9, Modal as Modal7, Select as Select6, Space as Space7, Spin as Spin4, Table, Tag as Tag6 } from "antd";
|
|
42322
42440
|
import { jsx as jsx79, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
42323
42441
|
var DEFAULT_PAGE_SIZE = 10;
|
|
@@ -42395,8 +42513,8 @@ function AssociationFormField(props) {
|
|
|
42395
42513
|
});
|
|
42396
42514
|
const [selectedRowKeys, setSelectedRowKeys] = useState74([]);
|
|
42397
42515
|
const [selectedRecords, setSelectedRecords] = useState74([]);
|
|
42398
|
-
const formDataRef =
|
|
42399
|
-
const associationFormRef =
|
|
42516
|
+
const formDataRef = useRef87(formData);
|
|
42517
|
+
const associationFormRef = useRef87(associationForm);
|
|
42400
42518
|
useEffect86(() => {
|
|
42401
42519
|
registerField(fieldId);
|
|
42402
42520
|
if (defaultValue !== void 0 && formData[fieldId] === void 0) {
|
|
@@ -42799,7 +42917,7 @@ function AssociationFormField(props) {
|
|
|
42799
42917
|
}
|
|
42800
42918
|
|
|
42801
42919
|
// packages/sdk/src/components/fields/EditorField/index.tsx
|
|
42802
|
-
import { useCallback as useCallback26, useEffect as useEffect87, useMemo as useMemo58, useRef as
|
|
42920
|
+
import { useCallback as useCallback26, useEffect as useEffect87, useMemo as useMemo58, useRef as useRef88, useState as useState75 } from "react";
|
|
42803
42921
|
import { Extension } from "@tiptap/core";
|
|
42804
42922
|
import { EditorContent, useEditor } from "@tiptap/react";
|
|
42805
42923
|
import StarterKit from "@tiptap/starter-kit";
|
|
@@ -43453,7 +43571,7 @@ function RichTextEditorCore({
|
|
|
43453
43571
|
fieldId = "richText",
|
|
43454
43572
|
mobile = false
|
|
43455
43573
|
}) {
|
|
43456
|
-
const inputRef =
|
|
43574
|
+
const inputRef = useRef88(null);
|
|
43457
43575
|
const [uploading, setUploading] = useState75(false);
|
|
43458
43576
|
const [uploadError, setUploadError] = useState75("");
|
|
43459
43577
|
const [charCount, setCharCount] = useState75(0);
|
|
@@ -43468,7 +43586,7 @@ function RichTextEditorCore({
|
|
|
43468
43586
|
const [tableOpen, setTableOpen] = useState75(false);
|
|
43469
43587
|
const [tableRows, setTableRows] = useState75(3);
|
|
43470
43588
|
const [tableCols, setTableCols] = useState75(3);
|
|
43471
|
-
const onChangeRef =
|
|
43589
|
+
const onChangeRef = useRef88(onChange);
|
|
43472
43590
|
useEffect87(() => {
|
|
43473
43591
|
onChangeRef.current = onChange;
|
|
43474
43592
|
}, [onChange]);
|
|
@@ -44168,7 +44286,7 @@ function LocationField(props) {
|
|
|
44168
44286
|
}
|
|
44169
44287
|
|
|
44170
44288
|
// packages/sdk/src/components/fields/DigitalSignatureField/index.tsx
|
|
44171
|
-
import { useCallback as useCallback27, useEffect as useEffect90, useRef as
|
|
44289
|
+
import { useCallback as useCallback27, useEffect as useEffect90, useRef as useRef89, useState as useState77 } from "react";
|
|
44172
44290
|
import { Button as Button12, Modal as Modal9, Space as Space10 } from "antd";
|
|
44173
44291
|
import { jsx as jsx83, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
44174
44292
|
var CANVAS_HEIGHT = 260;
|
|
@@ -44206,9 +44324,9 @@ function DigitalSignatureField(props) {
|
|
|
44206
44324
|
const [saving, setSaving] = useState77(false);
|
|
44207
44325
|
const [drawn, setDrawn] = useState77(false);
|
|
44208
44326
|
const [error, setError] = useState77("");
|
|
44209
|
-
const canvasRef =
|
|
44210
|
-
const drawingRef =
|
|
44211
|
-
const pointsRef =
|
|
44327
|
+
const canvasRef = useRef89(null);
|
|
44328
|
+
const drawingRef = useRef89(false);
|
|
44329
|
+
const pointsRef = useRef89([]);
|
|
44212
44330
|
useEffect90(() => {
|
|
44213
44331
|
registerField(fieldId);
|
|
44214
44332
|
if (defaultValue !== void 0 && formData[fieldId] === void 0) {
|
|
@@ -44947,7 +45065,7 @@ function FormProvider3({
|
|
|
44947
45065
|
}
|
|
44948
45066
|
return { ...values, ...initialValues };
|
|
44949
45067
|
}, [schema, initialValues, mergedRuntime]);
|
|
44950
|
-
const initialValuesRef =
|
|
45068
|
+
const initialValuesRef = useRef90(computedInitialValues);
|
|
44951
45069
|
const [formData, setFormData] = useState78({ ...computedInitialValues });
|
|
44952
45070
|
const [fieldErrors, setFieldErrors] = useState78({});
|
|
44953
45071
|
const [registeredFields] = useState78(/* @__PURE__ */ new Set());
|
|
@@ -46059,7 +46177,7 @@ async function validateAndNotify(validateAllWithErrors) {
|
|
|
46059
46177
|
}
|
|
46060
46178
|
|
|
46061
46179
|
// packages/sdk/src/components/hooks/useFormDetail.ts
|
|
46062
|
-
import { useState as useState82, useEffect as useEffect94, useCallback as useCallback29, useRef as
|
|
46180
|
+
import { useState as useState82, useEffect as useEffect94, useCallback as useCallback29, useRef as useRef91 } from "react";
|
|
46063
46181
|
|
|
46064
46182
|
// packages/sdk/src/components/utils/formInstanceData.ts
|
|
46065
46183
|
var FORM_INSTANCE_METADATA_KEYS = /* @__PURE__ */ new Set([
|
|
@@ -46261,8 +46379,8 @@ function useFormDetail(options) {
|
|
|
46261
46379
|
const [formData, setFormData] = useState82(null);
|
|
46262
46380
|
const [instanceInfo, setInstanceInfo] = useState82(null);
|
|
46263
46381
|
const [permissions, setPermissions] = useState82(null);
|
|
46264
|
-
const mountedRef =
|
|
46265
|
-
const onPermissionDeniedRef =
|
|
46382
|
+
const mountedRef = useRef91(true);
|
|
46383
|
+
const onPermissionDeniedRef = useRef91(onPermissionDenied);
|
|
46266
46384
|
const fieldIdsKey = fieldIds?.join("") ?? "";
|
|
46267
46385
|
useEffect94(() => {
|
|
46268
46386
|
mountedRef.current = true;
|
|
@@ -46370,7 +46488,7 @@ function useFormDetail(options) {
|
|
|
46370
46488
|
}
|
|
46371
46489
|
|
|
46372
46490
|
// packages/sdk/src/components/hooks/useChangeRecords.ts
|
|
46373
|
-
import { useState as useState83, useEffect as useEffect95, useCallback as useCallback30, useRef as
|
|
46491
|
+
import { useState as useState83, useEffect as useEffect95, useCallback as useCallback30, useRef as useRef92 } from "react";
|
|
46374
46492
|
var normalizeChangeRecordList = (value) => {
|
|
46375
46493
|
const body = value && typeof value === "object" && !Array.isArray(value) ? Array.isArray(value.data) || Array.isArray(value.records) || Array.isArray(value.list) || Array.isArray(value.items) ? value : value.data ?? value.result ?? value : value;
|
|
46376
46494
|
const records = Array.isArray(body) ? body : body?.records ?? body?.data ?? body?.list ?? body?.items ?? [];
|
|
@@ -46389,7 +46507,7 @@ function useChangeRecords(options) {
|
|
|
46389
46507
|
const [loading, setLoading] = useState83(false);
|
|
46390
46508
|
const [total, setTotal] = useState83(0);
|
|
46391
46509
|
const [page, setPage] = useState83(1);
|
|
46392
|
-
const mountedRef =
|
|
46510
|
+
const mountedRef = useRef92(true);
|
|
46393
46511
|
useEffect95(() => {
|
|
46394
46512
|
mountedRef.current = true;
|
|
46395
46513
|
return () => {
|
|
@@ -46855,8 +46973,8 @@ var InnerDetailContent = ({
|
|
|
46855
46973
|
onSave,
|
|
46856
46974
|
inDrawer = false
|
|
46857
46975
|
}) => {
|
|
46858
|
-
const formDataRef =
|
|
46859
|
-
const validateRef =
|
|
46976
|
+
const formDataRef = useRef93(void 0);
|
|
46977
|
+
const validateRef = useRef93(void 0);
|
|
46860
46978
|
const [accessDenied, setAccessDenied] = useState85(false);
|
|
46861
46979
|
const fieldIds = useMemo61(() => schema.fields.map((field) => field.fieldId), [schema.fields]);
|
|
46862
46980
|
const {
|
|
@@ -47035,7 +47153,7 @@ var FormDetailTemplate = (props) => {
|
|
|
47035
47153
|
};
|
|
47036
47154
|
|
|
47037
47155
|
// packages/sdk/src/components/templates/FormSubmitTemplate.tsx
|
|
47038
|
-
import { useEffect as useEffect98, useRef as
|
|
47156
|
+
import { useEffect as useEffect98, useRef as useRef95, useState as useState88, useCallback as useCallback34 } from "react";
|
|
47039
47157
|
import { Button as Button15, message as message4, Modal as Modal10, Select as Select8 } from "antd";
|
|
47040
47158
|
import { CheckCircleFilled as CheckCircleFilled2 } from "@ant-design/icons";
|
|
47041
47159
|
|
|
@@ -47120,7 +47238,7 @@ function useDraftStorage(options) {
|
|
|
47120
47238
|
}
|
|
47121
47239
|
|
|
47122
47240
|
// packages/sdk/src/components/hooks/useFormNavigation.ts
|
|
47123
|
-
import { useState as useState87, useCallback as useCallback33, useRef as
|
|
47241
|
+
import { useState as useState87, useCallback as useCallback33, useRef as useRef94, useEffect as useEffect97 } from "react";
|
|
47124
47242
|
var normalizeBasePath = (basePath) => {
|
|
47125
47243
|
const normalized = String(basePath || "").replace(/^\/+|\/+$/g, "");
|
|
47126
47244
|
return normalized ? `/${normalized}` : "";
|
|
@@ -47154,9 +47272,9 @@ function useFormNavigation(options) {
|
|
|
47154
47272
|
} = options;
|
|
47155
47273
|
const [isRedirecting, setIsRedirecting] = useState87(false);
|
|
47156
47274
|
const [countdown, setCountdown] = useState87(0);
|
|
47157
|
-
const timerRef =
|
|
47158
|
-
const redirectTargetRef =
|
|
47159
|
-
const mountedRef =
|
|
47275
|
+
const timerRef = useRef94(null);
|
|
47276
|
+
const redirectTargetRef = useRef94(null);
|
|
47277
|
+
const mountedRef = useRef94(true);
|
|
47160
47278
|
useEffect97(() => {
|
|
47161
47279
|
mountedRef.current = true;
|
|
47162
47280
|
return () => {
|
|
@@ -47433,15 +47551,15 @@ var InnerFormContent = ({
|
|
|
47433
47551
|
const [submissionDepartmentModalOpen, setSubmissionDepartmentModalOpen] = useState88(false);
|
|
47434
47552
|
const [submissionDepartmentOptions, setSubmissionDepartmentOptions] = useState88([]);
|
|
47435
47553
|
const [selectedSubmissionDepartmentId, setSelectedSubmissionDepartmentId] = useState88();
|
|
47436
|
-
const submissionDepartmentResolverRef =
|
|
47554
|
+
const submissionDepartmentResolverRef = useRef95(null);
|
|
47437
47555
|
const [previewOpen, setPreviewOpen] = useState88(false);
|
|
47438
47556
|
const [previewLoading, setPreviewLoading] = useState88(false);
|
|
47439
47557
|
const [previewRoutes, setPreviewRoutes] = useState88([]);
|
|
47440
47558
|
const [pendingFormData, setPendingFormData] = useState88(null);
|
|
47441
47559
|
const [pendingSubmissionDepartmentId, setPendingSubmissionDepartmentId] = useState88();
|
|
47442
47560
|
const [pendingInitiatorSelectedApprovers, setPendingInitiatorSelectedApprovers] = useState88();
|
|
47443
|
-
const pendingSubmissionDepartmentIdRef =
|
|
47444
|
-
const pendingInitiatorSelectedApproversRef =
|
|
47561
|
+
const pendingSubmissionDepartmentIdRef = useRef95(void 0);
|
|
47562
|
+
const pendingInitiatorSelectedApproversRef = useRef95(
|
|
47445
47563
|
void 0
|
|
47446
47564
|
);
|
|
47447
47565
|
const [initiatorApproverOpen, setInitiatorApproverOpen] = useState88(false);
|
|
@@ -47949,12 +48067,12 @@ var FormSubmitTemplate = ({
|
|
|
47949
48067
|
};
|
|
47950
48068
|
|
|
47951
48069
|
// packages/sdk/src/components/templates/ProcessDetailTemplate.tsx
|
|
47952
|
-
import { useCallback as useCallback38, useMemo as useMemo65, useRef as
|
|
48070
|
+
import { useCallback as useCallback38, useMemo as useMemo65, useRef as useRef98, useState as useState92 } from "react";
|
|
47953
48071
|
import dayjs20 from "dayjs";
|
|
47954
48072
|
import { Form as AntForm, Input as Input13, Modal as Modal12, message as message5 } from "antd";
|
|
47955
48073
|
|
|
47956
48074
|
// packages/sdk/src/components/hooks/useProcessDetail.ts
|
|
47957
|
-
import { useState as useState89, useEffect as useEffect99, useCallback as useCallback36, useRef as
|
|
48075
|
+
import { useState as useState89, useEffect as useEffect99, useCallback as useCallback36, useRef as useRef96, useMemo as useMemo63 } from "react";
|
|
47958
48076
|
|
|
47959
48077
|
// packages/sdk/src/components/hooks/useFieldPermission.ts
|
|
47960
48078
|
import { useMemo as useMemo62, useCallback as useCallback35 } from "react";
|
|
@@ -48081,7 +48199,7 @@ function useProcessDetail(options) {
|
|
|
48081
48199
|
const [permissions, setPermissions] = useState89(null);
|
|
48082
48200
|
const [processDefinition, setProcessDefinition] = useState89(null);
|
|
48083
48201
|
const [dataVersion, setDataVersion] = useState89(0);
|
|
48084
|
-
const mountedRef =
|
|
48202
|
+
const mountedRef = useRef96(true);
|
|
48085
48203
|
const fieldIdsKey = fieldIds?.join("") ?? "";
|
|
48086
48204
|
useEffect99(() => {
|
|
48087
48205
|
mountedRef.current = true;
|
|
@@ -48276,7 +48394,7 @@ function useProcessDetail(options) {
|
|
|
48276
48394
|
}
|
|
48277
48395
|
|
|
48278
48396
|
// packages/sdk/src/components/hooks/useApprovalActions.ts
|
|
48279
|
-
import { useState as useState90, useCallback as useCallback37, useRef as
|
|
48397
|
+
import { useState as useState90, useCallback as useCallback37, useRef as useRef97, useEffect as useEffect100 } from "react";
|
|
48280
48398
|
function useApprovalActions(options) {
|
|
48281
48399
|
const { formInstanceId, formUuid, appType, currentTaskId, onActionComplete, getFormValues } = options;
|
|
48282
48400
|
const { api } = useFormContext();
|
|
@@ -48285,7 +48403,7 @@ function useApprovalActions(options) {
|
|
|
48285
48403
|
const [currentAction, setCurrentAction] = useState90(null);
|
|
48286
48404
|
const [returnableNodes, setReturnableNodes] = useState90([]);
|
|
48287
48405
|
const [returnPolicy, setReturnPolicy] = useState90(null);
|
|
48288
|
-
const mountedRef =
|
|
48406
|
+
const mountedRef = useRef97(true);
|
|
48289
48407
|
useEffect100(() => {
|
|
48290
48408
|
mountedRef.current = true;
|
|
48291
48409
|
return () => {
|
|
@@ -48913,8 +49031,8 @@ var InnerProcessContent = ({
|
|
|
48913
49031
|
onDelete,
|
|
48914
49032
|
inDrawer = false
|
|
48915
49033
|
}) => {
|
|
48916
|
-
const formDataRef =
|
|
48917
|
-
const validateRef =
|
|
49034
|
+
const formDataRef = useRef98(void 0);
|
|
49035
|
+
const validateRef = useRef98(void 0);
|
|
48918
49036
|
const [withdrawForm] = AntForm.useForm();
|
|
48919
49037
|
const [withdrawOpen, setWithdrawOpen] = useState92(false);
|
|
48920
49038
|
const [withdrawLoading, setWithdrawLoading] = useState92(false);
|
|
@@ -50801,7 +50919,7 @@ function ResizableColumnTitle({
|
|
|
50801
50919
|
onResize: onResize2,
|
|
50802
50920
|
onResizeEnd
|
|
50803
50921
|
}) {
|
|
50804
|
-
const dragRef =
|
|
50922
|
+
const dragRef = useRef99({ startX: 0, startWidth: width, latestWidth: width });
|
|
50805
50923
|
const handleMouseDown = (event) => {
|
|
50806
50924
|
event.preventDefault();
|
|
50807
50925
|
event.stopPropagation();
|
|
@@ -50866,7 +50984,7 @@ var DataManagementList = ({
|
|
|
50866
50984
|
rowActions = [],
|
|
50867
50985
|
maxVisibleRowActions
|
|
50868
50986
|
}) => {
|
|
50869
|
-
const rootRef =
|
|
50987
|
+
const rootRef = useRef99(null);
|
|
50870
50988
|
const api = useMemo67(() => {
|
|
50871
50989
|
if (typeof requestOverride === "function") {
|
|
50872
50990
|
return createFormRuntimeApi({ request: requestOverride });
|
|
@@ -50880,7 +50998,7 @@ var DataManagementList = ({
|
|
|
50880
50998
|
const [showFields, setShowFields] = useState93([]);
|
|
50881
50999
|
const [lockFieldIds, setLockFieldIds] = useState93([]);
|
|
50882
51000
|
const [widths, setWidths] = useState93({});
|
|
50883
|
-
const widthsRef =
|
|
51001
|
+
const widthsRef = useRef99({});
|
|
50884
51002
|
const [sort, setSort] = useState93([]);
|
|
50885
51003
|
const [density, setDensity] = useState93("middle");
|
|
50886
51004
|
const [detailOpenMode, setDetailOpenMode] = useState93("drawer");
|
|
@@ -50915,7 +51033,7 @@ var DataManagementList = ({
|
|
|
50915
51033
|
const [activeRecord, setActiveRecord] = useState93(null);
|
|
50916
51034
|
const [detailOpen, setDetailOpen] = useState93(false);
|
|
50917
51035
|
const [submitOpen, setSubmitOpen] = useState93(false);
|
|
50918
|
-
const fetchStateRef =
|
|
51036
|
+
const fetchStateRef = useRef99({});
|
|
50919
51037
|
const isProcessForm = isProcessFormType(formType);
|
|
50920
51038
|
const request = api.request;
|
|
50921
51039
|
const getPopupContainer = useCallback39(
|