openxiangda 1.0.21 → 1.0.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +28 -10
- package/lib/cli.js +723 -11
- package/lib/workspace-init.js +13 -0
- package/openxiangda-skills/SKILL.md +26 -10
- package/openxiangda-skills/references/architecture-patterns.md +44 -22
- package/openxiangda-skills/references/automation-v3.md +2 -0
- package/openxiangda-skills/references/best-practices.md +163 -0
- package/openxiangda-skills/references/connector-resources.md +3 -0
- package/openxiangda-skills/references/notifications.md +80 -0
- package/openxiangda-skills/references/openxiangda-api.md +45 -0
- package/openxiangda-skills/references/pages/page-sdk.md +1 -0
- package/openxiangda-skills/references/pages/workspace-structure.md +5 -3
- package/openxiangda-skills/references/workspace-state.md +6 -0
- package/openxiangda-skills/skills/openxiangda-app/SKILL.md +11 -7
- package/openxiangda-skills/skills/openxiangda-core/SKILL.md +22 -4
- package/openxiangda-skills/skills/openxiangda-form/SKILL.md +6 -1
- package/openxiangda-skills/skills/openxiangda-page/SKILL.md +9 -1
- package/openxiangda-skills/skills/openxiangda-permission-settings/SKILL.md +3 -0
- package/openxiangda-skills/skills/openxiangda-workflow-automation/SKILL.md +9 -0
- package/package.json +1 -1
- package/packages/sdk/dist/runtime/index.cjs +34 -2
- package/packages/sdk/dist/runtime/index.cjs.map +1 -1
- package/packages/sdk/dist/runtime/index.d.mts +66 -1
- package/packages/sdk/dist/runtime/index.d.ts +66 -1
- package/packages/sdk/dist/runtime/index.mjs +34 -2
- package/packages/sdk/dist/runtime/index.mjs.map +1 -1
- package/templates/sy-lowcode-app-workspace/examples/best-practices/README.md +32 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/catalog.json +61 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/decision-guide.md +44 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/design-style.md +30 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/module-structure.md +48 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/role-governance/index.ts +2 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/role-governance/permissions.test.ts +35 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/role-governance/permissions.ts +24 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/role-governance/types.ts +17 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/index.ts +4 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/permissions.test.ts +42 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/permissions.ts +23 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/state-machine.test.ts +63 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/state-machine.ts +73 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/ticket-query.test.ts +34 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/ticket-query.ts +73 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/domain/service-ticket/types.ts +64 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/app-role/page.tsx +1 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/app-role/schema.ts +57 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/customer-profile/page.tsx +1 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/customer-profile/schema.ts +83 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/service-ticket/page.tsx +1 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/service-ticket/schema.ts +97 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/ticket-action-log/page.tsx +1 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/forms/ticket-action-log/schema.ts +65 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/js-code-nodes/daily_ticket_digest/index.ts +44 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/js-code-nodes/sync_roles_to_platform/index.ts +33 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/App.tsx +7 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/WorkbenchPage.tsx +36 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/components/ConfigPanel.tsx +34 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/components/PreviewPanel.tsx +17 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/index.tsx +10 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/page.config.ts +9 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/reducer.ts +29 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/interactive-workbench/styles.css +24 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/App.tsx +7 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/MobilePortalShell.tsx +31 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/index.tsx +10 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/modules/MobileHome.tsx +13 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/page.config.ts +14 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/routes.ts +13 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/mobile-portal-shell/styles.css +11 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/App.tsx +7 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/PcPortalShell.tsx +35 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/components/PortalMetric.tsx +11 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/index.tsx +10 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/modules/HomeModule.tsx +25 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/modules/TicketsModule.tsx +14 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/page.config.ts +14 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/routes.ts +19 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/pc-portal-shell/styles.css +35 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/App.tsx +7 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/TicketOpsPage.tsx +105 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/components/TicketActionTimeline.tsx +22 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/components/TicketDetailDrawer.tsx +41 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/components/TicketTableActions.tsx +55 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/index.tsx +10 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/page.config.ts +9 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/pages/service-ticket-ops/styles.css +35 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/resources/automations/daily-ticket-digest/automation.json +25 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/resources/automations/daily-ticket-digest/trigger.json +9 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/resources/notifications/daily-ticket-digest.json +24 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/resources/permissions/form-groups/service-ticket-college.json +21 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/resources/permissions/roles.json +17 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/resources/workflows/expense-approval-workflow.json +48 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/shared/components/ConfirmAction.tsx +22 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/shared/components/QueryState.tsx +37 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/shared/components/StatusTag.tsx +20 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/shared/hooks/useTicketOps.ts +96 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/shared/services/role-governance.ts +48 -0
- package/templates/sy-lowcode-app-workspace/examples/best-practices/src/shared/services/service-ticket.ts +113 -0
- package/templates/sy-lowcode-app-workspace/package.json +1 -0
- package/templates/sy-lowcode-app-workspace/src/dev/App.tsx +11 -1
- package/templates/sy-lowcode-app-workspace/tsconfig.examples.json +24 -0
|
@@ -608,6 +608,69 @@ interface BatchSendNotificationByTypeParams {
|
|
|
608
608
|
channels?: NotificationChannel[];
|
|
609
609
|
}>;
|
|
610
610
|
}
|
|
611
|
+
interface NotificationChannelConfig {
|
|
612
|
+
enabled?: boolean;
|
|
613
|
+
title?: string;
|
|
614
|
+
content?: string;
|
|
615
|
+
config?: Record<string, unknown>;
|
|
616
|
+
[key: string]: unknown;
|
|
617
|
+
}
|
|
618
|
+
interface NotificationChannelsConfig {
|
|
619
|
+
inapp?: NotificationChannelConfig;
|
|
620
|
+
email?: NotificationChannelConfig;
|
|
621
|
+
dingding?: NotificationChannelConfig;
|
|
622
|
+
wechat?: NotificationChannelConfig;
|
|
623
|
+
thirdparty_todo?: NotificationChannelConfig;
|
|
624
|
+
[key: string]: NotificationChannelConfig | undefined;
|
|
625
|
+
}
|
|
626
|
+
type NotificationConfigLevel = "platform" | "app" | "form";
|
|
627
|
+
interface NotificationTemplate {
|
|
628
|
+
id?: string;
|
|
629
|
+
code: string;
|
|
630
|
+
name: string;
|
|
631
|
+
content?: string;
|
|
632
|
+
description?: string;
|
|
633
|
+
level?: NotificationConfigLevel;
|
|
634
|
+
appType?: string;
|
|
635
|
+
formUuid?: string;
|
|
636
|
+
priority?: number;
|
|
637
|
+
enabled?: boolean;
|
|
638
|
+
variables?: string[];
|
|
639
|
+
channelsConfig?: NotificationChannelsConfig;
|
|
640
|
+
[key: string]: unknown;
|
|
641
|
+
}
|
|
642
|
+
interface NotificationTypeConfig {
|
|
643
|
+
id?: string;
|
|
644
|
+
notificationType: string;
|
|
645
|
+
level?: NotificationConfigLevel;
|
|
646
|
+
appType?: string;
|
|
647
|
+
formUuid?: string;
|
|
648
|
+
templateId?: string;
|
|
649
|
+
template?: NotificationTemplate;
|
|
650
|
+
enabled?: boolean;
|
|
651
|
+
priority?: number;
|
|
652
|
+
description?: string;
|
|
653
|
+
[key: string]: unknown;
|
|
654
|
+
}
|
|
655
|
+
interface PreviewNotificationTemplateParams {
|
|
656
|
+
appType?: string;
|
|
657
|
+
templateId?: string;
|
|
658
|
+
templateCode?: string;
|
|
659
|
+
code?: string;
|
|
660
|
+
level?: "app" | "form";
|
|
661
|
+
formUuid?: string;
|
|
662
|
+
payload?: Record<string, unknown>;
|
|
663
|
+
}
|
|
664
|
+
interface NotificationTemplatePreview {
|
|
665
|
+
defaultContent?: string;
|
|
666
|
+
channelPreviews?: Record<string, string>;
|
|
667
|
+
enabledChannels?: Array<NotificationChannel | string>;
|
|
668
|
+
[key: string]: unknown;
|
|
669
|
+
}
|
|
670
|
+
interface FindNotificationConfigParams {
|
|
671
|
+
appType?: string;
|
|
672
|
+
formUuid?: string;
|
|
673
|
+
}
|
|
611
674
|
interface NotificationMessageRecord {
|
|
612
675
|
id?: string;
|
|
613
676
|
messageId?: string;
|
|
@@ -787,6 +850,8 @@ interface PageSdk {
|
|
|
787
850
|
notification: {
|
|
788
851
|
sendByType<T = SendNotificationResult>(params: SendNotificationByTypeParams): Promise<PageApiResponse<T>>;
|
|
789
852
|
batchSendByType<T = SendNotificationResult>(params: BatchSendNotificationByTypeParams): Promise<PageApiResponse<T>>;
|
|
853
|
+
findConfig<T = NotificationTypeConfig | null>(notificationType: string, params?: FindNotificationConfigParams): Promise<PageApiResponse<T>>;
|
|
854
|
+
previewTemplate<T = NotificationTemplatePreview>(params: PreviewNotificationTemplateParams): Promise<PageApiResponse<T>>;
|
|
790
855
|
};
|
|
791
856
|
navigation: PageNavigationApi;
|
|
792
857
|
ui: PageContext["ui"];
|
|
@@ -866,4 +931,4 @@ declare const usePageRoute: () => PageRouteInfo;
|
|
|
866
931
|
|
|
867
932
|
declare const usePageSdk: () => PageSdk;
|
|
868
933
|
|
|
869
|
-
export { type ApiPermissionListParams, type ApproveTaskParams, type AssignPermissionsParams, type AssignRolesParams, type BatchAddUsersToRoleParams, type BatchSendNotificationByTypeParams, type ChangeUserRoleParams, type ConnectorCallParams, type ConnectorInvokeParams, type ConnectorInvokeResult, type ConnectorRequestBodyType, type ConnectorResponseType, type CreateApiPermissionParams, type CreateFormPermissionGroupDto, type CreatePagePermissionGroupDto, type CreateRoleParams, type CreateUiPermissionParams, type CreateUserParams, type CurrentUserDepartmentParents, type CustomPageEntryConfig, type CustomPageEntryMode, type DataManagementConfigParams, type DataManagementFilterState, type DataPermissionConditionDto, type DataPermissionDto, type DataPermissionRuleDto, type FieldPermissionDto, type FormAdvancedSearchParams, type FormChangeRecordParams, type FormCreateParams, type FormExportParams, type FormGetDetailParams, type FormImportParams, type FormPermissionGroup, type FormRemoveParams, type FormSearchParams, type FormUpdateParams, type GetParentDepartmentsOptions, type GetProcessInstanceParams, type GetUserRolesParams, type ImportExportRecordDownloadParams, type ImportExportRecordQuery, type InstanceStatus, type NotificationChannel, type NotificationMessageRecord, type PageApiPermissionRecord, type PageApiResponse, type PageAppInfo, type PageBinaryResponse, type PageBridgeApi, type PageContext, type PageDataManagementConfig, type PageDataSourceDescriptor, type PageDepartmentInfo, type PageDepartmentRecord, type PageHttpMethod, type PageInfo, type PageListResult, type PageMessageApi, type PageModalApi, type PageNavigationApi, type PageOffsetListResult, type PagePermissionGroup, type PagePermissionInfo, PageProvider, type PageQueryValue, type PageRequestOptions, type PageRoleRecord, type PageRouteInfo, type PageScope, type PageSdk, type PageSdkError, type PageSdkMeta, type PageTransportDownloadPayload, type PageTransportRequestPayload, type PageUiPermissionRecord, type PageUiPermissionType, type PageUserInfo, type PageUserRecord, type PageUserType, type ProcessApproveAction, type QueryFormPermissionGroupDto, type QueryPagePermissionGroupDto, type RoleListParams, type RoleUsersParams, type SaveDataManagementConfigParams, type SearchComponentName, type SearchExpression, type SearchFieldKey, type SearchGroup, type SearchLogic, type SearchOperator, type SearchRule, type SearchSortItem, type SearchSystemField, type SendNotificationByTypeParams, type SendNotificationResult, type SubFormRule, type SwitchAppRoleParams, type SwitchPlatformRoleParams, type TerminateProcessInstanceParams, type TriggerCallbackTaskParams, type UiPermissionListParams, type UpdateApiPermissionParams, type UpdateFormPermissionGroupDto, type UpdatePagePermissionGroupDto, type UpdateRoleParams, type UpdateUiPermissionParams, type UpdateUserParams, type UserListParams, type UserMenuPermissionsResponse, type ValidateUserParams, type ViewFieldPermissionValue, type ViewOperationPermission, type ViewPermissionSummary, createPageSdk, createReactPage, useCurrentUser, useDataSource, useFormViewPermissions, useMessage, useModal, useNavigation, usePageContext, usePageProps, usePageRoute, usePageSdk };
|
|
934
|
+
export { type ApiPermissionListParams, type ApproveTaskParams, type AssignPermissionsParams, type AssignRolesParams, type BatchAddUsersToRoleParams, type BatchSendNotificationByTypeParams, type ChangeUserRoleParams, type ConnectorCallParams, type ConnectorInvokeParams, type ConnectorInvokeResult, type ConnectorRequestBodyType, type ConnectorResponseType, type CreateApiPermissionParams, type CreateFormPermissionGroupDto, type CreatePagePermissionGroupDto, type CreateRoleParams, type CreateUiPermissionParams, type CreateUserParams, type CurrentUserDepartmentParents, type CustomPageEntryConfig, type CustomPageEntryMode, type DataManagementConfigParams, type DataManagementFilterState, type DataPermissionConditionDto, type DataPermissionDto, type DataPermissionRuleDto, type FieldPermissionDto, type FindNotificationConfigParams, type FormAdvancedSearchParams, type FormChangeRecordParams, type FormCreateParams, type FormExportParams, type FormGetDetailParams, type FormImportParams, type FormPermissionGroup, type FormRemoveParams, type FormSearchParams, type FormUpdateParams, type GetParentDepartmentsOptions, type GetProcessInstanceParams, type GetUserRolesParams, type ImportExportRecordDownloadParams, type ImportExportRecordQuery, type InstanceStatus, type NotificationChannel, type NotificationChannelConfig, type NotificationChannelsConfig, type NotificationConfigLevel, type NotificationMessageRecord, type NotificationTemplate, type NotificationTemplatePreview, type NotificationTypeConfig, type PageApiPermissionRecord, type PageApiResponse, type PageAppInfo, type PageBinaryResponse, type PageBridgeApi, type PageContext, type PageDataManagementConfig, type PageDataSourceDescriptor, type PageDepartmentInfo, type PageDepartmentRecord, type PageHttpMethod, type PageInfo, type PageListResult, type PageMessageApi, type PageModalApi, type PageNavigationApi, type PageOffsetListResult, type PagePermissionGroup, type PagePermissionInfo, PageProvider, type PageQueryValue, type PageRequestOptions, type PageRoleRecord, type PageRouteInfo, type PageScope, type PageSdk, type PageSdkError, type PageSdkMeta, type PageTransportDownloadPayload, type PageTransportRequestPayload, type PageUiPermissionRecord, type PageUiPermissionType, type PageUserInfo, type PageUserRecord, type PageUserType, type PreviewNotificationTemplateParams, type ProcessApproveAction, type QueryFormPermissionGroupDto, type QueryPagePermissionGroupDto, type RoleListParams, type RoleUsersParams, type SaveDataManagementConfigParams, type SearchComponentName, type SearchExpression, type SearchFieldKey, type SearchGroup, type SearchLogic, type SearchOperator, type SearchRule, type SearchSortItem, type SearchSystemField, type SendNotificationByTypeParams, type SendNotificationResult, type SubFormRule, type SwitchAppRoleParams, type SwitchPlatformRoleParams, type TerminateProcessInstanceParams, type TriggerCallbackTaskParams, type UiPermissionListParams, type UpdateApiPermissionParams, type UpdateFormPermissionGroupDto, type UpdatePagePermissionGroupDto, type UpdateRoleParams, type UpdateUiPermissionParams, type UpdateUserParams, type UserListParams, type UserMenuPermissionsResponse, type ValidateUserParams, type ViewFieldPermissionValue, type ViewOperationPermission, type ViewPermissionSummary, createPageSdk, createReactPage, useCurrentUser, useDataSource, useFormViewPermissions, useMessage, useModal, useNavigation, usePageContext, usePageProps, usePageRoute, usePageSdk };
|
|
@@ -17,6 +17,9 @@ var resolveAppType = (context, explicitAppType) => {
|
|
|
17
17
|
return appType;
|
|
18
18
|
};
|
|
19
19
|
var buildAppPath = (context, explicitAppType, suffix) => `/${resolveAppType(context, explicitAppType)}${suffix}`;
|
|
20
|
+
var buildOpenXiangdaAppPath = (context, explicitAppType, suffix) => `/openxiangda-api/v1/apps/${encodePathSegment(
|
|
21
|
+
resolveAppType(context, explicitAppType)
|
|
22
|
+
)}${suffix}`;
|
|
20
23
|
var encodePathSegment = (value) => encodeURIComponent(String(value));
|
|
21
24
|
var getHeaderValue = (headers, name) => {
|
|
22
25
|
if (!headers) {
|
|
@@ -1029,7 +1032,11 @@ var createPageSdk = (context) => {
|
|
|
1029
1032
|
};
|
|
1030
1033
|
const notification = {
|
|
1031
1034
|
sendByType: (params) => request({
|
|
1032
|
-
path:
|
|
1035
|
+
path: buildOpenXiangdaAppPath(
|
|
1036
|
+
context,
|
|
1037
|
+
params.appType,
|
|
1038
|
+
"/notifications/send-by-type"
|
|
1039
|
+
),
|
|
1033
1040
|
method: "post",
|
|
1034
1041
|
body: {
|
|
1035
1042
|
...params,
|
|
@@ -1037,7 +1044,32 @@ var createPageSdk = (context) => {
|
|
|
1037
1044
|
}
|
|
1038
1045
|
}),
|
|
1039
1046
|
batchSendByType: (params) => request({
|
|
1040
|
-
path:
|
|
1047
|
+
path: buildOpenXiangdaAppPath(
|
|
1048
|
+
context,
|
|
1049
|
+
params.appType,
|
|
1050
|
+
"/notifications/batch-send-by-type"
|
|
1051
|
+
),
|
|
1052
|
+
method: "post",
|
|
1053
|
+
body: {
|
|
1054
|
+
...params,
|
|
1055
|
+
appType: resolveAppType(context, params.appType)
|
|
1056
|
+
}
|
|
1057
|
+
}),
|
|
1058
|
+
findConfig: (notificationType, params = {}) => request({
|
|
1059
|
+
path: buildOpenXiangdaAppPath(
|
|
1060
|
+
context,
|
|
1061
|
+
params.appType,
|
|
1062
|
+
`/notifications/type-configs/${encodePathSegment(notificationType)}`
|
|
1063
|
+
),
|
|
1064
|
+
method: "get",
|
|
1065
|
+
query: params.formUuid ? { formUuid: params.formUuid } : void 0
|
|
1066
|
+
}),
|
|
1067
|
+
previewTemplate: (params) => request({
|
|
1068
|
+
path: buildOpenXiangdaAppPath(
|
|
1069
|
+
context,
|
|
1070
|
+
params.appType,
|
|
1071
|
+
"/notifications/templates/preview"
|
|
1072
|
+
),
|
|
1041
1073
|
method: "post",
|
|
1042
1074
|
body: {
|
|
1043
1075
|
...params,
|