@open-mercato/core 0.6.7-develop.6788.1.c2a1520a30 → 0.6.7-develop.6814.1.0627c7e9f1
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/.turbo/turbo-build.log +1 -1
- package/dist/generated/entities/customer_deal_person_link/index.js +2 -0
- package/dist/generated/entities/customer_deal_person_link/index.js.map +2 -2
- package/dist/generated/entities/customer_user_invitation/index.js +2 -0
- package/dist/generated/entities/customer_user_invitation/index.js.map +2 -2
- package/dist/generated/entities.ids.generated.js +1 -0
- package/dist/generated/entities.ids.generated.js.map +2 -2
- package/dist/generated/entity-fields-registry.js +2 -0
- package/dist/generated/entity-fields-registry.js.map +2 -2
- package/dist/modules/business_rules/api/openmercato-call-options/route.js +85 -0
- package/dist/modules/business_rules/api/openmercato-call-options/route.js.map +7 -0
- package/dist/modules/business_rules/api/rules/route.js +71 -4
- package/dist/modules/business_rules/api/rules/route.js.map +2 -2
- package/dist/modules/business_rules/components/ActionBuilder.js +47 -4
- package/dist/modules/business_rules/components/ActionBuilder.js.map +3 -3
- package/dist/modules/business_rules/components/ActionRow.js +106 -16
- package/dist/modules/business_rules/components/ActionRow.js.map +2 -2
- package/dist/modules/business_rules/components/utils/actionValidation.js +6 -0
- package/dist/modules/business_rules/components/utils/actionValidation.js.map +2 -2
- package/dist/modules/business_rules/lib/action-executor.js +148 -0
- package/dist/modules/business_rules/lib/action-executor.js.map +2 -2
- package/dist/modules/business_rules/lib/openmercato-call-options-types.js +5 -0
- package/dist/modules/business_rules/lib/openmercato-call-options-types.js.map +7 -0
- package/dist/modules/business_rules/lib/openmercato-call-options.js +231 -0
- package/dist/modules/business_rules/lib/openmercato-call-options.js.map +7 -0
- package/dist/modules/business_rules/lib/rule-engine.js +5 -1
- package/dist/modules/business_rules/lib/rule-engine.js.map +2 -2
- package/dist/modules/communication_channels/api/post/webhook/[provider]/route.js +11 -1
- package/dist/modules/communication_channels/api/post/webhook/[provider]/route.js.map +2 -2
- package/dist/modules/communication_channels/api/post/webhooks/gmail/route.js +11 -6
- package/dist/modules/communication_channels/api/post/webhooks/gmail/route.js.map +2 -2
- package/dist/modules/configs/lib/upgrade-actions.js +12 -0
- package/dist/modules/configs/lib/upgrade-actions.js.map +2 -2
- package/dist/modules/customer_accounts/api/admin/users/[id].js +10 -1
- package/dist/modules/customer_accounts/api/admin/users/[id].js.map +2 -2
- package/dist/modules/customer_accounts/api/admin/users-invite.js +61 -4
- package/dist/modules/customer_accounts/api/admin/users-invite.js.map +2 -2
- package/dist/modules/customer_accounts/api/portal/users-invite.js +20 -2
- package/dist/modules/customer_accounts/api/portal/users-invite.js.map +2 -2
- package/dist/modules/customer_accounts/data/entities.js +3 -0
- package/dist/modules/customer_accounts/data/entities.js.map +2 -2
- package/dist/modules/customer_accounts/data/validators.js +1 -0
- package/dist/modules/customer_accounts/data/validators.js.map +2 -2
- package/dist/modules/customer_accounts/emails/CustomerInvitationEmail.js +26 -0
- package/dist/modules/customer_accounts/emails/CustomerInvitationEmail.js.map +7 -0
- package/dist/modules/customer_accounts/lib/customerEntityOwnership.js +29 -3
- package/dist/modules/customer_accounts/lib/customerEntityOwnership.js.map +2 -2
- package/dist/modules/customer_accounts/lib/customerUrl.js +19 -10
- package/dist/modules/customer_accounts/lib/customerUrl.js.map +2 -2
- package/dist/modules/customer_accounts/lib/invitationEmail.js +35 -0
- package/dist/modules/customer_accounts/lib/invitationEmail.js.map +7 -0
- package/dist/modules/customer_accounts/migrations/Migration20260723120000_customer_accounts.js +13 -0
- package/dist/modules/customer_accounts/migrations/Migration20260723120000_customer_accounts.js.map +7 -0
- package/dist/modules/customer_accounts/services/customerInvitationService.js +32 -2
- package/dist/modules/customer_accounts/services/customerInvitationService.js.map +2 -2
- package/dist/modules/customer_accounts/subscribers/autoLinkCrm.js +47 -7
- package/dist/modules/customer_accounts/subscribers/autoLinkCrm.js.map +2 -2
- package/dist/modules/customer_accounts/widgets/injection/account-status/widget.client.js +2 -2
- package/dist/modules/customer_accounts/widgets/injection/account-status/widget.client.js.map +2 -2
- package/dist/modules/customer_accounts/widgets/injection-table.js +1 -1
- package/dist/modules/customer_accounts/widgets/injection-table.js.map +2 -2
- package/dist/modules/customers/api/deals/[id]/people/route.js +4 -2
- package/dist/modules/customers/api/deals/[id]/people/route.js.map +2 -2
- package/dist/modules/customers/api/deals/[id]/route.js +7 -3
- package/dist/modules/customers/api/deals/[id]/route.js.map +2 -2
- package/dist/modules/customers/backend/customers/companies-v2/[id]/page.js +11 -1
- package/dist/modules/customers/backend/customers/companies-v2/[id]/page.js.map +2 -2
- package/dist/modules/customers/backend/customers/deals/[id]/page.js +14 -8
- package/dist/modules/customers/backend/customers/deals/[id]/page.js.map +2 -2
- package/dist/modules/customers/backend/customers/people-v2/[id]/page.js +21 -6
- package/dist/modules/customers/backend/customers/people-v2/[id]/page.js.map +2 -2
- package/dist/modules/customers/cli.js +17 -7
- package/dist/modules/customers/cli.js.map +2 -2
- package/dist/modules/customers/commands/deals.js +48 -10
- package/dist/modules/customers/commands/deals.js.map +2 -2
- package/dist/modules/customers/commands/people.js +2 -0
- package/dist/modules/customers/commands/people.js.map +2 -2
- package/dist/modules/customers/components/detail/CompanyDetailTabs.js +26 -6
- package/dist/modules/customers/components/detail/CompanyDetailTabs.js.map +2 -2
- package/dist/modules/customers/components/detail/DealDetailTabs.js +30 -8
- package/dist/modules/customers/components/detail/DealDetailTabs.js.map +2 -2
- package/dist/modules/customers/components/detail/PersonDetailTabs.js +30 -8
- package/dist/modules/customers/components/detail/PersonDetailTabs.js.map +2 -2
- package/dist/modules/customers/data/entities.js +8 -0
- package/dist/modules/customers/data/entities.js.map +2 -2
- package/dist/modules/customers/data/validators.js +2 -1
- package/dist/modules/customers/data/validators.js.map +2 -2
- package/dist/modules/customers/migrations/Migration20260723210000_customers.js +15 -0
- package/dist/modules/customers/migrations/Migration20260723210000_customers.js.map +7 -0
- package/dist/modules/customers/search.js +50 -29
- package/dist/modules/customers/search.js.map +2 -2
- package/dist/modules/data_sync/api/mappings/[id]/route.js +22 -9
- package/dist/modules/data_sync/api/mappings/[id]/route.js.map +2 -2
- package/dist/modules/data_sync/api/mappings/route.js +13 -4
- package/dist/modules/data_sync/api/mappings/route.js.map +2 -2
- package/dist/modules/data_sync/api/options.js +7 -2
- package/dist/modules/data_sync/api/options.js.map +2 -2
- package/dist/modules/data_sync/api/run.js +7 -2
- package/dist/modules/data_sync/api/run.js.map +2 -2
- package/dist/modules/data_sync/api/runs/[id]/cancel.js +8 -3
- package/dist/modules/data_sync/api/runs/[id]/cancel.js.map +2 -2
- package/dist/modules/data_sync/api/runs/[id]/retry.js +7 -2
- package/dist/modules/data_sync/api/runs/[id]/retry.js.map +2 -2
- package/dist/modules/data_sync/api/runs/[id]/route.js +8 -3
- package/dist/modules/data_sync/api/runs/[id]/route.js.map +2 -2
- package/dist/modules/data_sync/api/runs.js +7 -2
- package/dist/modules/data_sync/api/runs.js.map +2 -2
- package/dist/modules/data_sync/api/schedules/[id]/route.js +19 -6
- package/dist/modules/data_sync/api/schedules/[id]/route.js.map +2 -2
- package/dist/modules/data_sync/api/schedules/route.js +13 -4
- package/dist/modules/data_sync/api/schedules/route.js.map +2 -2
- package/dist/modules/data_sync/api/validate.js +9 -4
- package/dist/modules/data_sync/api/validate.js.map +2 -2
- package/dist/modules/design_system/acl.js +9 -0
- package/dist/modules/design_system/acl.js.map +7 -0
- package/dist/modules/design_system/backend/design-system/page.js +11 -0
- package/dist/modules/design_system/backend/design-system/page.js.map +7 -0
- package/dist/modules/design_system/backend/design-system/page.meta.js +15 -0
- package/dist/modules/design_system/backend/design-system/page.meta.js.map +7 -0
- package/dist/modules/design_system/gallery/components/CodeSnippet.js +52 -0
- package/dist/modules/design_system/gallery/components/CodeSnippet.js.map +7 -0
- package/dist/modules/design_system/gallery/components/EntryCard.js +63 -0
- package/dist/modules/design_system/gallery/components/EntryCard.js.map +7 -0
- package/dist/modules/design_system/gallery/components/GalleryShell.js +163 -0
- package/dist/modules/design_system/gallery/components/GalleryShell.js.map +7 -0
- package/dist/modules/design_system/gallery/components/VariantPreview.js +9 -0
- package/dist/modules/design_system/gallery/components/VariantPreview.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/banners.js +186 -0
- package/dist/modules/design_system/gallery/entries/banners.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/buttons.js +361 -0
- package/dist/modules/design_system/gallery/entries/buttons.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/charts.js +457 -0
- package/dist/modules/design_system/gallery/entries/charts.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/dates.js +306 -0
- package/dist/modules/design_system/gallery/entries/dates.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/detail.js +358 -0
- package/dist/modules/design_system/gallery/entries/detail.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/display.js +785 -0
- package/dist/modules/design_system/gallery/entries/display.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/feedback.js +658 -0
- package/dist/modules/design_system/gallery/entries/feedback.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/filters.js +505 -0
- package/dist/modules/design_system/gallery/entries/filters.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/foundations.js +453 -0
- package/dist/modules/design_system/gallery/entries/foundations.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/icons.js +140 -0
- package/dist/modules/design_system/gallery/entries/icons.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/inputs.js +1217 -0
- package/dist/modules/design_system/gallery/entries/inputs.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/messages.js +334 -0
- package/dist/modules/design_system/gallery/entries/messages.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/navigation.js +475 -0
- package/dist/modules/design_system/gallery/entries/navigation.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/notifications.js +257 -0
- package/dist/modules/design_system/gallery/entries/notifications.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/overlays.js +576 -0
- package/dist/modules/design_system/gallery/entries/overlays.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/scaffolding.js +378 -0
- package/dist/modules/design_system/gallery/entries/scaffolding.js.map +7 -0
- package/dist/modules/design_system/gallery/entries/schedule.js +297 -0
- package/dist/modules/design_system/gallery/entries/schedule.js.map +7 -0
- package/dist/modules/design_system/gallery/registry.js +139 -0
- package/dist/modules/design_system/gallery/registry.js.map +7 -0
- package/dist/modules/design_system/gallery/types.js +1 -0
- package/dist/modules/design_system/gallery/types.js.map +7 -0
- package/dist/modules/design_system/index.js +9 -0
- package/dist/modules/design_system/index.js.map +7 -0
- package/dist/modules/design_system/setup.js +14 -0
- package/dist/modules/design_system/setup.js.map +7 -0
- package/dist/modules/entities/api/entity-settings.js +59 -9
- package/dist/modules/entities/api/entity-settings.js.map +2 -2
- package/dist/modules/entities/backend/config/settings/page.js +10 -0
- package/dist/modules/entities/backend/config/settings/page.js.map +7 -0
- package/dist/modules/entities/backend/config/settings/page.meta.js +36 -0
- package/dist/modules/entities/backend/config/settings/page.meta.js.map +7 -0
- package/dist/modules/entities/backend/entities/user/create/page.js +16 -7
- package/dist/modules/entities/backend/entities/user/create/page.js.map +2 -2
- package/dist/modules/entities/components/EntitySettingsManager.js +136 -0
- package/dist/modules/entities/components/EntitySettingsManager.js.map +7 -0
- package/dist/modules/inbox_ops/api/webhook/inbound.js +14 -10
- package/dist/modules/inbox_ops/api/webhook/inbound.js.map +2 -2
- package/dist/modules/inbox_ops/search.js +15 -4
- package/dist/modules/inbox_ops/search.js.map +2 -2
- package/dist/modules/integrations/api/[id]/credentials/route.js +11 -5
- package/dist/modules/integrations/api/[id]/credentials/route.js.map +2 -2
- package/dist/modules/integrations/api/[id]/health/route.js +6 -3
- package/dist/modules/integrations/api/[id]/health/route.js.map +2 -2
- package/dist/modules/integrations/api/[id]/route.js +6 -3
- package/dist/modules/integrations/api/[id]/route.js.map +2 -2
- package/dist/modules/integrations/api/[id]/state/route.js +6 -3
- package/dist/modules/integrations/api/[id]/state/route.js.map +2 -2
- package/dist/modules/integrations/api/[id]/version/route.js +6 -3
- package/dist/modules/integrations/api/[id]/version/route.js.map +2 -2
- package/dist/modules/integrations/api/logs/route.js +6 -3
- package/dist/modules/integrations/api/logs/route.js.map +2 -2
- package/dist/modules/integrations/api/route.js +6 -3
- package/dist/modules/integrations/api/route.js.map +2 -2
- package/dist/modules/integrations/api/umes-read.js +2 -2
- package/dist/modules/integrations/api/umes-read.js.map +2 -2
- package/dist/modules/integrations/lib/organization-scope.js +2 -9
- package/dist/modules/integrations/lib/organization-scope.js.map +2 -2
- package/dist/modules/messages/search.js +10 -5
- package/dist/modules/messages/search.js.map +2 -2
- package/dist/modules/payment_gateways/api/webhook/[provider]/route.js +11 -1
- package/dist/modules/payment_gateways/api/webhook/[provider]/route.js.map +2 -2
- package/dist/modules/payment_gateways/data/entities.js +4 -0
- package/dist/modules/payment_gateways/data/entities.js.map +2 -2
- package/dist/modules/payment_gateways/lib/gateway-service.js +12 -2
- package/dist/modules/payment_gateways/lib/gateway-service.js.map +2 -2
- package/dist/modules/payment_gateways/lib/session-idempotency.js +33 -0
- package/dist/modules/payment_gateways/lib/session-idempotency.js.map +2 -2
- package/dist/modules/payment_gateways/migrations/Migration20260803103035_payment_gateways.js +18 -0
- package/dist/modules/payment_gateways/migrations/Migration20260803103035_payment_gateways.js.map +7 -0
- package/dist/modules/payment_gateways/setup.js +47 -0
- package/dist/modules/payment_gateways/setup.js.map +2 -2
- package/dist/modules/payment_gateways/workers/session-initialization-prune.js +50 -0
- package/dist/modules/payment_gateways/workers/session-initialization-prune.js.map +7 -0
- package/dist/modules/portal/frontend/[orgSlug]/portal/invite/page.js +134 -0
- package/dist/modules/portal/frontend/[orgSlug]/portal/invite/page.js.map +7 -0
- package/dist/modules/portal/frontend/[orgSlug]/portal/invite/page.meta.js +11 -0
- package/dist/modules/portal/frontend/[orgSlug]/portal/invite/page.meta.js.map +7 -0
- package/dist/modules/portal/lib/navigation.js +7 -0
- package/dist/modules/portal/lib/navigation.js.map +7 -0
- package/dist/modules/query_index/data/entities.js +2 -1
- package/dist/modules/query_index/data/entities.js.map +2 -2
- package/dist/modules/query_index/lib/engine.js +75 -50
- package/dist/modules/query_index/lib/engine.js.map +2 -2
- package/dist/modules/query_index/lib/search-tokens.js +15 -5
- package/dist/modules/query_index/lib/search-tokens.js.map +2 -2
- package/dist/modules/query_index/migrations/Migration20260731105052_query_index.js +17 -0
- package/dist/modules/query_index/migrations/Migration20260731105052_query_index.js.map +7 -0
- package/dist/modules/shipping_carriers/api/webhook/[provider]/route.js +11 -1
- package/dist/modules/shipping_carriers/api/webhook/[provider]/route.js.map +2 -2
- package/generated/entities/customer_deal_person_link/index.ts +1 -0
- package/generated/entities/customer_user_invitation/index.ts +1 -0
- package/generated/entities.ids.generated.ts +1 -0
- package/generated/entity-fields-registry.ts +2 -0
- package/package.json +16 -16
- package/src/modules/business_rules/api/openmercato-call-options/route.ts +94 -0
- package/src/modules/business_rules/api/rules/route.ts +92 -4
- package/src/modules/business_rules/components/ActionBuilder.tsx +54 -5
- package/src/modules/business_rules/components/ActionRow.tsx +156 -18
- package/src/modules/business_rules/components/utils/actionValidation.ts +6 -0
- package/src/modules/business_rules/i18n/de.json +12 -0
- package/src/modules/business_rules/i18n/en.json +12 -0
- package/src/modules/business_rules/i18n/es.json +12 -0
- package/src/modules/business_rules/i18n/pl.json +12 -0
- package/src/modules/business_rules/lib/action-executor.ts +198 -0
- package/src/modules/business_rules/lib/openmercato-call-options-types.ts +31 -0
- package/src/modules/business_rules/lib/openmercato-call-options.ts +297 -0
- package/src/modules/business_rules/lib/rule-engine.ts +4 -0
- package/src/modules/communication_channels/api/post/webhook/[provider]/route.ts +11 -1
- package/src/modules/communication_channels/api/post/webhooks/gmail/route.ts +17 -11
- package/src/modules/configs/lib/upgrade-actions.ts +14 -0
- package/src/modules/customer_accounts/api/admin/users/[id].ts +16 -1
- package/src/modules/customer_accounts/api/admin/users-invite.ts +78 -3
- package/src/modules/customer_accounts/api/portal/users-invite.ts +22 -1
- package/src/modules/customer_accounts/data/entities.ts +3 -0
- package/src/modules/customer_accounts/data/validators.ts +1 -0
- package/src/modules/customer_accounts/emails/CustomerInvitationEmail.tsx +45 -0
- package/src/modules/customer_accounts/i18n/de.json +6 -0
- package/src/modules/customer_accounts/i18n/en.json +6 -0
- package/src/modules/customer_accounts/i18n/es.json +6 -0
- package/src/modules/customer_accounts/i18n/pl.json +6 -0
- package/src/modules/customer_accounts/lib/customerEntityOwnership.ts +68 -2
- package/src/modules/customer_accounts/lib/customerUrl.ts +27 -11
- package/src/modules/customer_accounts/lib/invitationEmail.ts +42 -0
- package/src/modules/customer_accounts/migrations/.snapshot-open-mercato.json +16 -0
- package/src/modules/customer_accounts/migrations/Migration20260723120000_customer_accounts.ts +13 -0
- package/src/modules/customer_accounts/services/customerInvitationService.ts +56 -3
- package/src/modules/customer_accounts/subscribers/autoLinkCrm.ts +75 -8
- package/src/modules/customer_accounts/widgets/injection/account-status/widget.client.tsx +2 -2
- package/src/modules/customer_accounts/widgets/injection-table.ts +4 -1
- package/src/modules/customers/api/deals/[id]/people/route.ts +3 -0
- package/src/modules/customers/api/deals/[id]/route.ts +10 -2
- package/src/modules/customers/backend/customers/companies-v2/[id]/page.tsx +12 -1
- package/src/modules/customers/backend/customers/deals/[id]/hooks/types.ts +1 -0
- package/src/modules/customers/backend/customers/deals/[id]/page.tsx +15 -9
- package/src/modules/customers/backend/customers/people-v2/[id]/page.tsx +24 -6
- package/src/modules/customers/cli.ts +17 -7
- package/src/modules/customers/commands/deals.ts +50 -9
- package/src/modules/customers/commands/people.ts +3 -0
- package/src/modules/customers/components/detail/CompanyDetailTabs.tsx +30 -7
- package/src/modules/customers/components/detail/DealDetailTabs.tsx +34 -9
- package/src/modules/customers/components/detail/PersonDetailTabs.tsx +34 -9
- package/src/modules/customers/data/entities.ts +9 -1
- package/src/modules/customers/data/validators.ts +1 -0
- package/src/modules/customers/i18n/de.json +18 -0
- package/src/modules/customers/i18n/en.json +18 -0
- package/src/modules/customers/i18n/es.json +18 -0
- package/src/modules/customers/i18n/pl.json +18 -0
- package/src/modules/customers/migrations/.snapshot-open-mercato.json +27 -1
- package/src/modules/customers/migrations/Migration20260723210000_customers.ts +15 -0
- package/src/modules/customers/search.ts +59 -27
- package/src/modules/data_sync/AGENTS.md +1 -0
- package/src/modules/data_sync/api/mappings/[id]/route.ts +22 -9
- package/src/modules/data_sync/api/mappings/route.ts +13 -4
- package/src/modules/data_sync/api/options.ts +7 -2
- package/src/modules/data_sync/api/run.ts +7 -2
- package/src/modules/data_sync/api/runs/[id]/cancel.ts +8 -3
- package/src/modules/data_sync/api/runs/[id]/retry.ts +7 -2
- package/src/modules/data_sync/api/runs/[id]/route.ts +8 -3
- package/src/modules/data_sync/api/runs.ts +7 -2
- package/src/modules/data_sync/api/schedules/[id]/route.ts +19 -6
- package/src/modules/data_sync/api/schedules/route.ts +13 -4
- package/src/modules/data_sync/api/validate.ts +9 -4
- package/src/modules/design_system/AGENTS.md +34 -0
- package/src/modules/design_system/acl.ts +5 -0
- package/src/modules/design_system/backend/design-system/page.meta.ts +11 -0
- package/src/modules/design_system/backend/design-system/page.tsx +14 -0
- package/src/modules/design_system/gallery/components/CodeSnippet.tsx +55 -0
- package/src/modules/design_system/gallery/components/EntryCard.tsx +95 -0
- package/src/modules/design_system/gallery/components/GalleryShell.tsx +206 -0
- package/src/modules/design_system/gallery/components/VariantPreview.tsx +15 -0
- package/src/modules/design_system/gallery/entries/banners.tsx +226 -0
- package/src/modules/design_system/gallery/entries/buttons.tsx +422 -0
- package/src/modules/design_system/gallery/entries/charts.tsx +518 -0
- package/src/modules/design_system/gallery/entries/dates.tsx +325 -0
- package/src/modules/design_system/gallery/entries/detail.tsx +403 -0
- package/src/modules/design_system/gallery/entries/display.tsx +893 -0
- package/src/modules/design_system/gallery/entries/feedback.tsx +746 -0
- package/src/modules/design_system/gallery/entries/filters.tsx +570 -0
- package/src/modules/design_system/gallery/entries/foundations.tsx +529 -0
- package/src/modules/design_system/gallery/entries/icons.tsx +168 -0
- package/src/modules/design_system/gallery/entries/inputs.tsx +1516 -0
- package/src/modules/design_system/gallery/entries/messages.tsx +339 -0
- package/src/modules/design_system/gallery/entries/navigation.tsx +573 -0
- package/src/modules/design_system/gallery/entries/notifications.tsx +285 -0
- package/src/modules/design_system/gallery/entries/overlays.tsx +677 -0
- package/src/modules/design_system/gallery/entries/scaffolding.tsx +430 -0
- package/src/modules/design_system/gallery/entries/schedule.tsx +307 -0
- package/src/modules/design_system/gallery/registry.ts +152 -0
- package/src/modules/design_system/gallery/types.ts +32 -0
- package/src/modules/design_system/i18n/.hardcoded-allowlist.json +71 -0
- package/src/modules/design_system/i18n/de.json +46 -0
- package/src/modules/design_system/i18n/en.json +46 -0
- package/src/modules/design_system/i18n/es.json +46 -0
- package/src/modules/design_system/i18n/pl.json +46 -0
- package/src/modules/design_system/index.ts +7 -0
- package/src/modules/design_system/setup.ts +12 -0
- package/src/modules/entities/api/entity-settings.ts +66 -22
- package/src/modules/entities/backend/config/settings/page.meta.ts +34 -0
- package/src/modules/entities/backend/config/settings/page.tsx +12 -0
- package/src/modules/entities/backend/entities/user/create/page.tsx +16 -7
- package/src/modules/entities/components/EntitySettingsManager.tsx +160 -0
- package/src/modules/entities/i18n/de.json +9 -0
- package/src/modules/entities/i18n/en.json +9 -0
- package/src/modules/entities/i18n/es.json +9 -0
- package/src/modules/entities/i18n/pl.json +9 -0
- package/src/modules/inbox_ops/api/webhook/inbound.ts +14 -12
- package/src/modules/inbox_ops/i18n/de.json +3 -0
- package/src/modules/inbox_ops/i18n/en.json +3 -0
- package/src/modules/inbox_ops/i18n/es.json +3 -0
- package/src/modules/inbox_ops/i18n/pl.json +3 -0
- package/src/modules/inbox_ops/search.ts +20 -4
- package/src/modules/integrations/api/[id]/credentials/route.ts +11 -5
- package/src/modules/integrations/api/[id]/health/route.ts +6 -3
- package/src/modules/integrations/api/[id]/route.ts +6 -3
- package/src/modules/integrations/api/[id]/state/route.ts +6 -3
- package/src/modules/integrations/api/[id]/version/route.ts +6 -3
- package/src/modules/integrations/api/logs/route.ts +6 -3
- package/src/modules/integrations/api/route.ts +6 -3
- package/src/modules/integrations/api/umes-read.ts +2 -2
- package/src/modules/integrations/lib/organization-scope.ts +5 -25
- package/src/modules/messages/i18n/de.json +2 -0
- package/src/modules/messages/i18n/en.json +2 -0
- package/src/modules/messages/i18n/es.json +2 -0
- package/src/modules/messages/i18n/pl.json +2 -0
- package/src/modules/messages/search.ts +11 -5
- package/src/modules/payment_gateways/api/webhook/[provider]/route.ts +13 -1
- package/src/modules/payment_gateways/data/entities.ts +5 -0
- package/src/modules/payment_gateways/i18n/de.json +5 -1
- package/src/modules/payment_gateways/i18n/en.json +5 -1
- package/src/modules/payment_gateways/i18n/es.json +5 -1
- package/src/modules/payment_gateways/i18n/pl.json +5 -1
- package/src/modules/payment_gateways/lib/gateway-service.ts +12 -2
- package/src/modules/payment_gateways/lib/session-idempotency.ts +36 -0
- package/src/modules/payment_gateways/migrations/.snapshot-open-mercato.json +10 -1
- package/src/modules/payment_gateways/migrations/Migration20260803103035_payment_gateways.ts +17 -0
- package/src/modules/payment_gateways/setup.ts +62 -0
- package/src/modules/payment_gateways/workers/session-initialization-prune.ts +63 -0
- package/src/modules/portal/frontend/[orgSlug]/portal/invite/page.meta.ts +9 -0
- package/src/modules/portal/frontend/[orgSlug]/portal/invite/page.tsx +164 -0
- package/src/modules/portal/i18n/de.json +18 -0
- package/src/modules/portal/i18n/en.json +18 -0
- package/src/modules/portal/i18n/es.json +18 -0
- package/src/modules/portal/i18n/pl.json +18 -0
- package/src/modules/portal/lib/navigation.ts +3 -0
- package/src/modules/query_index/data/entities.ts +7 -0
- package/src/modules/query_index/lib/engine.ts +92 -63
- package/src/modules/query_index/lib/search-tokens.ts +16 -4
- package/src/modules/query_index/migrations/.snapshot-open-mercato.json +12 -0
- package/src/modules/query_index/migrations/Migration20260731105052_query_index.ts +35 -0
- package/src/modules/shipping_carriers/api/webhook/[provider]/route.ts +11 -1
|
@@ -3,11 +3,13 @@
|
|
|
3
3
|
import * as React from 'react'
|
|
4
4
|
import { Button } from '@open-mercato/ui/primitives/button'
|
|
5
5
|
import { Plus, Code } from 'lucide-react'
|
|
6
|
-
import {
|
|
6
|
+
import { apiCall } from '@open-mercato/ui/backend/utils/apiCall'
|
|
7
|
+
import { ActionRow, type OpenMercatoCallOptionsState } from './ActionRow'
|
|
7
8
|
import type { Action } from './utils/actionValidation'
|
|
8
9
|
import { validateActions } from './utils/actionValidation'
|
|
9
10
|
import { useT } from '@open-mercato/shared/lib/i18n/context'
|
|
10
11
|
import { useConfirmDialog } from '@open-mercato/ui/backend/confirm-dialog'
|
|
12
|
+
import type { OpenMercatoCallOptionsResponse } from '../lib/openmercato-call-options-types'
|
|
11
13
|
|
|
12
14
|
export type ActionBuilderProps = {
|
|
13
15
|
value: Action[] | null | undefined
|
|
@@ -29,7 +31,52 @@ export function ActionBuilder({
|
|
|
29
31
|
const t = useT()
|
|
30
32
|
const { confirm: confirmDialog, ConfirmDialogElement } = useConfirmDialog()
|
|
31
33
|
const [showDebug, setShowDebug] = React.useState(false)
|
|
32
|
-
const
|
|
34
|
+
const [openMercatoOptions, setOpenMercatoOptions] = React.useState<OpenMercatoCallOptionsState>({
|
|
35
|
+
endpoints: [],
|
|
36
|
+
apiKeys: [],
|
|
37
|
+
loading: true,
|
|
38
|
+
error: null,
|
|
39
|
+
})
|
|
40
|
+
const actions = React.useMemo(() => value || [], [value])
|
|
41
|
+
|
|
42
|
+
React.useEffect(() => {
|
|
43
|
+
let cancelled = false
|
|
44
|
+
|
|
45
|
+
async function loadOpenMercatoOptions() {
|
|
46
|
+
setOpenMercatoOptions((current) => ({ ...current, loading: true, error: null }))
|
|
47
|
+
try {
|
|
48
|
+
const response = await apiCall<OpenMercatoCallOptionsResponse>('/api/business_rules/openmercato-call-options')
|
|
49
|
+
if (!response.ok || !response.result) {
|
|
50
|
+
const error = response.result && 'error' in response.result
|
|
51
|
+
? String((response.result as any).error)
|
|
52
|
+
: t('business_rules.components.actionRow.openMercato.options.fetchFailed', { status: response.status })
|
|
53
|
+
throw new Error(error)
|
|
54
|
+
}
|
|
55
|
+
if (!cancelled) {
|
|
56
|
+
setOpenMercatoOptions({
|
|
57
|
+
endpoints: Array.isArray(response.result.endpoints) ? response.result.endpoints : [],
|
|
58
|
+
apiKeys: Array.isArray(response.result.apiKeys) ? response.result.apiKeys : [],
|
|
59
|
+
loading: false,
|
|
60
|
+
error: null,
|
|
61
|
+
})
|
|
62
|
+
}
|
|
63
|
+
} catch (error) {
|
|
64
|
+
if (!cancelled) {
|
|
65
|
+
setOpenMercatoOptions({
|
|
66
|
+
endpoints: [],
|
|
67
|
+
apiKeys: [],
|
|
68
|
+
loading: false,
|
|
69
|
+
error: error instanceof Error ? error.message : String(error),
|
|
70
|
+
})
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
void loadOpenMercatoOptions()
|
|
76
|
+
return () => {
|
|
77
|
+
cancelled = true
|
|
78
|
+
}
|
|
79
|
+
}, [t])
|
|
33
80
|
|
|
34
81
|
const handleAddAction = () => {
|
|
35
82
|
const newAction: Action = {
|
|
@@ -101,10 +148,11 @@ export function ActionBuilder({
|
|
|
101
148
|
{/* Controls */}
|
|
102
149
|
<div className="flex items-center gap-2">
|
|
103
150
|
{showJsonPreview && actions.length > 0 && (
|
|
104
|
-
<
|
|
151
|
+
<Button
|
|
105
152
|
type="button"
|
|
106
153
|
onClick={() => setShowDebug(!showDebug)}
|
|
107
|
-
|
|
154
|
+
variant="muted"
|
|
155
|
+
size="2xs"
|
|
108
156
|
title={t('business_rules.components.actionBuilder.jsonPreview.toggle')}
|
|
109
157
|
>
|
|
110
158
|
<Code className="w-3 h-3" />
|
|
@@ -112,7 +160,7 @@ export function ActionBuilder({
|
|
|
112
160
|
? t('business_rules.components.actionBuilder.jsonPreview.hide')
|
|
113
161
|
: t('business_rules.components.actionBuilder.jsonPreview.show')
|
|
114
162
|
}
|
|
115
|
-
</
|
|
163
|
+
</Button>
|
|
116
164
|
)}
|
|
117
165
|
</div>
|
|
118
166
|
</div>
|
|
@@ -143,6 +191,7 @@ export function ActionBuilder({
|
|
|
143
191
|
onMoveDown={index < actions.length - 1 ? handleMoveDown : undefined}
|
|
144
192
|
canMoveUp={index > 0}
|
|
145
193
|
canMoveDown={index < actions.length - 1}
|
|
194
|
+
openMercatoOptions={openMercatoOptions}
|
|
146
195
|
/>
|
|
147
196
|
))}
|
|
148
197
|
</div>
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
import * as React from 'react'
|
|
4
4
|
import { X, ChevronUp, ChevronDown } from 'lucide-react'
|
|
5
5
|
import { Input } from '@open-mercato/ui/primitives/input'
|
|
6
|
+
import { Textarea } from '@open-mercato/ui/primitives/textarea'
|
|
7
|
+
import { IconButton } from '@open-mercato/ui/primitives/icon-button'
|
|
8
|
+
import { ComboboxInput, type ComboboxOption } from '@open-mercato/ui/backend/inputs'
|
|
6
9
|
import {
|
|
7
10
|
Select,
|
|
8
11
|
SelectContent,
|
|
@@ -13,6 +16,17 @@ import {
|
|
|
13
16
|
import type { Action } from './utils/actionValidation'
|
|
14
17
|
import { getActionTypeOptions, getRequiredConfigFields, getOptionalConfigFields } from './utils/actionValidation'
|
|
15
18
|
import { useT } from '@open-mercato/shared/lib/i18n/context'
|
|
19
|
+
import type {
|
|
20
|
+
OpenMercatoApiKeyOption,
|
|
21
|
+
OpenMercatoEndpointOption,
|
|
22
|
+
} from '../lib/openmercato-call-options-types'
|
|
23
|
+
|
|
24
|
+
export type OpenMercatoCallOptionsState = {
|
|
25
|
+
endpoints: OpenMercatoEndpointOption[]
|
|
26
|
+
apiKeys: OpenMercatoApiKeyOption[]
|
|
27
|
+
loading: boolean
|
|
28
|
+
error: string | null
|
|
29
|
+
}
|
|
16
30
|
|
|
17
31
|
export type ActionRowProps = {
|
|
18
32
|
action: Action
|
|
@@ -24,6 +38,7 @@ export type ActionRowProps = {
|
|
|
24
38
|
canMoveUp?: boolean
|
|
25
39
|
canMoveDown?: boolean
|
|
26
40
|
error?: string
|
|
41
|
+
openMercatoOptions?: OpenMercatoCallOptionsState
|
|
27
42
|
}
|
|
28
43
|
|
|
29
44
|
export function ActionRow({
|
|
@@ -36,6 +51,7 @@ export function ActionRow({
|
|
|
36
51
|
canMoveUp,
|
|
37
52
|
canMoveDown,
|
|
38
53
|
error,
|
|
54
|
+
openMercatoOptions,
|
|
39
55
|
}: ActionRowProps) {
|
|
40
56
|
const t = useT()
|
|
41
57
|
const actionTypes = getActionTypeOptions(t)
|
|
@@ -60,6 +76,115 @@ export function ActionRow({
|
|
|
60
76
|
})
|
|
61
77
|
}
|
|
62
78
|
|
|
79
|
+
const renderOpenMercatoConfig = () => {
|
|
80
|
+
const options = openMercatoOptions ?? { endpoints: [], apiKeys: [], loading: false, error: null }
|
|
81
|
+
const endpointValue = action.config?.endpoint && action.config?.method
|
|
82
|
+
? `${String(action.config.method).toUpperCase()} ${action.config.endpoint}`
|
|
83
|
+
: undefined
|
|
84
|
+
const apiKeyValue = action.config?.apiKeyId || undefined
|
|
85
|
+
const endpointOptions = options.endpoints.map<ComboboxOption>((option) => ({
|
|
86
|
+
value: option.id,
|
|
87
|
+
label: option.label,
|
|
88
|
+
description: option.summary || option.operationId || null,
|
|
89
|
+
}))
|
|
90
|
+
const bodyValue = action.config?.body == null
|
|
91
|
+
? ''
|
|
92
|
+
: typeof action.config.body === 'string'
|
|
93
|
+
? action.config.body
|
|
94
|
+
: JSON.stringify(action.config.body, null, 2)
|
|
95
|
+
|
|
96
|
+
const handleEndpointChange = (value: string) => {
|
|
97
|
+
const option = options.endpoints.find((candidate) => candidate.id === value)
|
|
98
|
+
if (!option) return
|
|
99
|
+
onChange(index, {
|
|
100
|
+
...action,
|
|
101
|
+
config: {
|
|
102
|
+
...(action.config || {}),
|
|
103
|
+
endpoint: option.path,
|
|
104
|
+
method: option.method,
|
|
105
|
+
},
|
|
106
|
+
})
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
return (
|
|
110
|
+
<div className="space-y-2">
|
|
111
|
+
{options.loading && (
|
|
112
|
+
<p className="text-xs text-muted-foreground col-start-2">
|
|
113
|
+
{t('business_rules.components.actionRow.openMercato.options.loading')}
|
|
114
|
+
</p>
|
|
115
|
+
)}
|
|
116
|
+
{options.error && (
|
|
117
|
+
<p className="text-xs text-status-error-text col-start-2">
|
|
118
|
+
{t('business_rules.components.actionRow.openMercato.options.error', { error: options.error })}
|
|
119
|
+
</p>
|
|
120
|
+
)}
|
|
121
|
+
{!options.loading && !options.error && options.endpoints.length === 0 && (
|
|
122
|
+
<p className="text-xs text-muted-foreground col-start-2">
|
|
123
|
+
{t('business_rules.components.actionRow.openMercato.options.noEndpoints')}
|
|
124
|
+
</p>
|
|
125
|
+
)}
|
|
126
|
+
{!options.loading && !options.error && options.apiKeys.length === 0 && (
|
|
127
|
+
<p className="text-xs text-muted-foreground col-start-2">
|
|
128
|
+
{t('business_rules.components.actionRow.openMercato.options.noApiKeys')}
|
|
129
|
+
</p>
|
|
130
|
+
)}
|
|
131
|
+
|
|
132
|
+
<div className="grid grid-cols-4 gap-2 items-center">
|
|
133
|
+
<label className="text-xs font-medium text-foreground col-span-1">
|
|
134
|
+
{t('business_rules.components.actionRow.config.endpoint')} <span className="text-status-error-text">{t('business_rules.components.actionRow.actionType.required')}</span>
|
|
135
|
+
</label>
|
|
136
|
+
<div className="col-span-3">
|
|
137
|
+
<ComboboxInput
|
|
138
|
+
value={endpointValue ?? ''}
|
|
139
|
+
onChange={handleEndpointChange}
|
|
140
|
+
suggestions={endpointOptions}
|
|
141
|
+
placeholder={t('business_rules.components.actionRow.config.endpoint.placeholder')}
|
|
142
|
+
disabled={options.loading || !!options.error || options.endpoints.length === 0}
|
|
143
|
+
allowCustomValues={false}
|
|
144
|
+
/>
|
|
145
|
+
</div>
|
|
146
|
+
</div>
|
|
147
|
+
|
|
148
|
+
<div className="grid grid-cols-4 gap-2 items-center">
|
|
149
|
+
<label className="text-xs font-medium text-foreground col-span-1">
|
|
150
|
+
{t('business_rules.components.actionRow.config.apiKey')} <span className="text-status-error-text">{t('business_rules.components.actionRow.actionType.required')}</span>
|
|
151
|
+
</label>
|
|
152
|
+
<Select
|
|
153
|
+
value={apiKeyValue}
|
|
154
|
+
onValueChange={(next) => handleConfigChange('apiKeyId', next)}
|
|
155
|
+
disabled={options.loading || !!options.error || options.apiKeys.length === 0}
|
|
156
|
+
>
|
|
157
|
+
<SelectTrigger size="sm" className="col-span-3">
|
|
158
|
+
<SelectValue placeholder={t('business_rules.components.actionRow.config.apiKey.placeholder')} />
|
|
159
|
+
</SelectTrigger>
|
|
160
|
+
<SelectContent>
|
|
161
|
+
{options.apiKeys.map((apiKey) => (
|
|
162
|
+
<SelectItem key={apiKey.id} value={apiKey.id}>
|
|
163
|
+
{apiKey.organizationName
|
|
164
|
+
? `${apiKey.name} (${apiKey.keyPrefix}, ${apiKey.organizationName})`
|
|
165
|
+
: `${apiKey.name} (${apiKey.keyPrefix})`}
|
|
166
|
+
</SelectItem>
|
|
167
|
+
))}
|
|
168
|
+
</SelectContent>
|
|
169
|
+
</Select>
|
|
170
|
+
</div>
|
|
171
|
+
|
|
172
|
+
<div className="grid grid-cols-4 gap-2 items-start">
|
|
173
|
+
<label className="text-xs font-medium text-foreground col-span-1">
|
|
174
|
+
{t('business_rules.components.actionRow.config.body')}
|
|
175
|
+
</label>
|
|
176
|
+
<Textarea
|
|
177
|
+
value={bodyValue}
|
|
178
|
+
onChange={(e) => handleConfigChange('body', e.target.value)}
|
|
179
|
+
placeholder={t('business_rules.components.actionRow.config.body.placeholder')}
|
|
180
|
+
rows={3}
|
|
181
|
+
className="col-span-3"
|
|
182
|
+
/>
|
|
183
|
+
</div>
|
|
184
|
+
</div>
|
|
185
|
+
)
|
|
186
|
+
}
|
|
187
|
+
|
|
63
188
|
const renderConfigField = (field: string, required: boolean) => {
|
|
64
189
|
const value = action.config?.[field] || ''
|
|
65
190
|
|
|
@@ -68,7 +193,7 @@ export function ActionRow({
|
|
|
68
193
|
return (
|
|
69
194
|
<div key={field} className="grid grid-cols-4 gap-2 items-start">
|
|
70
195
|
<label className="text-xs font-medium text-foreground col-span-1">
|
|
71
|
-
{t('business_rules.components.actionRow.config.recipients')} {required && <span className="text-
|
|
196
|
+
{t('business_rules.components.actionRow.config.recipients')} {required && <span className="text-status-error-text">{t('business_rules.components.actionRow.actionType.required')}</span>}
|
|
72
197
|
</label>
|
|
73
198
|
<Input
|
|
74
199
|
type="text"
|
|
@@ -133,14 +258,14 @@ export function ActionRow({
|
|
|
133
258
|
return (
|
|
134
259
|
<div key={field} className="grid grid-cols-4 gap-2 items-start">
|
|
135
260
|
<label className="text-xs font-medium text-foreground col-span-1">
|
|
136
|
-
{t('business_rules.components.actionRow.config.message')} {required && <span className="text-
|
|
261
|
+
{t('business_rules.components.actionRow.config.message')} {required && <span className="text-status-error-text">{t('business_rules.components.actionRow.actionType.required')}</span>}
|
|
137
262
|
</label>
|
|
138
|
-
<
|
|
263
|
+
<Textarea
|
|
139
264
|
value={value}
|
|
140
265
|
onChange={(e) => handleConfigChange(field, e.target.value)}
|
|
141
266
|
placeholder={t('business_rules.components.actionRow.config.message.placeholder')}
|
|
142
267
|
rows={2}
|
|
143
|
-
className="col-span-3
|
|
268
|
+
className="col-span-3"
|
|
144
269
|
/>
|
|
145
270
|
<div className="col-span-4 col-start-2">
|
|
146
271
|
<p className="text-xs text-muted-foreground">{t('business_rules.components.actionRow.config.message.help')}</p>
|
|
@@ -153,7 +278,7 @@ export function ActionRow({
|
|
|
153
278
|
return (
|
|
154
279
|
<div key={field} className="grid grid-cols-4 gap-2 items-center">
|
|
155
280
|
<label className="text-xs font-medium text-foreground col-span-1">
|
|
156
|
-
{field} {required && <span className="text-
|
|
281
|
+
{field} {required && <span className="text-status-error-text">{t('business_rules.components.actionRow.actionType.required')}</span>}
|
|
157
282
|
</label>
|
|
158
283
|
<Input
|
|
159
284
|
type="text"
|
|
@@ -172,7 +297,7 @@ export function ActionRow({
|
|
|
172
297
|
{/* Action Type */}
|
|
173
298
|
<div className="grid grid-cols-4 gap-2 items-center">
|
|
174
299
|
<label className="text-xs font-medium text-foreground col-span-1">
|
|
175
|
-
{t('business_rules.components.actionRow.actionType')} <span className="text-
|
|
300
|
+
{t('business_rules.components.actionRow.actionType')} <span className="text-status-error-text">{t('business_rules.components.actionRow.actionType.required')}</span>
|
|
176
301
|
</label>
|
|
177
302
|
<Select
|
|
178
303
|
value={action.type || undefined}
|
|
@@ -194,15 +319,21 @@ export function ActionRow({
|
|
|
194
319
|
{/* Config Fields */}
|
|
195
320
|
{action.type && (
|
|
196
321
|
<>
|
|
197
|
-
{
|
|
198
|
-
|
|
322
|
+
{action.type === 'CALL_OPEN_MERCATO'
|
|
323
|
+
? renderOpenMercatoConfig()
|
|
324
|
+
: (
|
|
325
|
+
<>
|
|
326
|
+
{requiredFields.map((field) => renderConfigField(field, true))}
|
|
327
|
+
{optionalFields.map((field) => renderConfigField(field, false))}
|
|
328
|
+
</>
|
|
329
|
+
)}
|
|
199
330
|
</>
|
|
200
331
|
)}
|
|
201
332
|
|
|
202
333
|
{/* Error Display */}
|
|
203
334
|
{error && (
|
|
204
335
|
<div className="mt-2">
|
|
205
|
-
<p className="text-xs text-
|
|
336
|
+
<p className="text-xs text-status-error-text">{error}</p>
|
|
206
337
|
</div>
|
|
207
338
|
)}
|
|
208
339
|
</div>
|
|
@@ -210,35 +341,42 @@ export function ActionRow({
|
|
|
210
341
|
{/* Control Buttons */}
|
|
211
342
|
<div className="flex flex-col gap-1">
|
|
212
343
|
{onMoveUp && (
|
|
213
|
-
<
|
|
344
|
+
<IconButton
|
|
214
345
|
type="button"
|
|
215
346
|
onClick={() => onMoveUp(index)}
|
|
216
347
|
disabled={!canMoveUp}
|
|
217
|
-
|
|
348
|
+
variant="ghost"
|
|
349
|
+
size="xs"
|
|
218
350
|
title={t('business_rules.components.actionRow.moveUp')}
|
|
351
|
+
aria-label={t('business_rules.components.actionRow.moveUp')}
|
|
219
352
|
>
|
|
220
353
|
<ChevronUp className="w-4 h-4" />
|
|
221
|
-
</
|
|
354
|
+
</IconButton>
|
|
222
355
|
)}
|
|
223
356
|
{onMoveDown && (
|
|
224
|
-
<
|
|
357
|
+
<IconButton
|
|
225
358
|
type="button"
|
|
226
359
|
onClick={() => onMoveDown(index)}
|
|
227
360
|
disabled={!canMoveDown}
|
|
228
|
-
|
|
361
|
+
variant="ghost"
|
|
362
|
+
size="xs"
|
|
229
363
|
title={t('business_rules.components.actionRow.moveDown')}
|
|
364
|
+
aria-label={t('business_rules.components.actionRow.moveDown')}
|
|
230
365
|
>
|
|
231
366
|
<ChevronDown className="w-4 h-4" />
|
|
232
|
-
</
|
|
367
|
+
</IconButton>
|
|
233
368
|
)}
|
|
234
|
-
<
|
|
369
|
+
<IconButton
|
|
235
370
|
type="button"
|
|
236
371
|
onClick={() => onDelete(index)}
|
|
237
|
-
|
|
372
|
+
variant="ghost"
|
|
373
|
+
size="xs"
|
|
374
|
+
className="hover:text-status-error-text"
|
|
238
375
|
title={t('business_rules.components.actionRow.delete')}
|
|
376
|
+
aria-label={t('business_rules.components.actionRow.delete')}
|
|
239
377
|
>
|
|
240
378
|
<X className="w-4 h-4" />
|
|
241
|
-
</
|
|
379
|
+
</IconButton>
|
|
242
380
|
</div>
|
|
243
381
|
</div>
|
|
244
382
|
)
|
|
@@ -23,6 +23,7 @@ export const ACTION_TYPES = [
|
|
|
23
23
|
'NOTIFY',
|
|
24
24
|
'SET_FIELD',
|
|
25
25
|
'CALL_WEBHOOK',
|
|
26
|
+
'CALL_OPEN_MERCATO',
|
|
26
27
|
'EMIT_EVENT',
|
|
27
28
|
] as const
|
|
28
29
|
|
|
@@ -42,6 +43,7 @@ export function getActionTypeOptions(t: TranslatorFn): { value: string; label: s
|
|
|
42
43
|
{ value: 'NOTIFY', label: t('business_rules.validation.actionTypes.NOTIFY') },
|
|
43
44
|
{ value: 'SET_FIELD', label: t('business_rules.validation.actionTypes.SET_FIELD') },
|
|
44
45
|
{ value: 'CALL_WEBHOOK', label: t('business_rules.validation.actionTypes.CALL_WEBHOOK') },
|
|
46
|
+
{ value: 'CALL_OPEN_MERCATO', label: t('business_rules.validation.actionTypes.CALL_OPEN_MERCATO') },
|
|
45
47
|
{ value: 'EMIT_EVENT', label: t('business_rules.validation.actionTypes.EMIT_EVENT') },
|
|
46
48
|
]
|
|
47
49
|
}
|
|
@@ -62,6 +64,8 @@ export function getRequiredConfigFields(actionType: string): string[] {
|
|
|
62
64
|
return ['field', 'value']
|
|
63
65
|
case 'CALL_WEBHOOK':
|
|
64
66
|
return ['url']
|
|
67
|
+
case 'CALL_OPEN_MERCATO':
|
|
68
|
+
return ['endpoint', 'method', 'apiKeyId']
|
|
65
69
|
case 'EMIT_EVENT':
|
|
66
70
|
return ['eventName']
|
|
67
71
|
case 'ALLOW_TRANSITION':
|
|
@@ -82,6 +86,8 @@ export function getOptionalConfigFields(actionType: string): string[] {
|
|
|
82
86
|
return ['template']
|
|
83
87
|
case 'CALL_WEBHOOK':
|
|
84
88
|
return ['method', 'headers', 'body']
|
|
89
|
+
case 'CALL_OPEN_MERCATO':
|
|
90
|
+
return ['body']
|
|
85
91
|
case 'EMIT_EVENT':
|
|
86
92
|
return ['payload']
|
|
87
93
|
default:
|
|
@@ -29,6 +29,12 @@
|
|
|
29
29
|
"business_rules.components.actionRow.actionType": "Aktionstyp",
|
|
30
30
|
"business_rules.components.actionRow.actionType.placeholder": "Aktionstyp auswählen...",
|
|
31
31
|
"business_rules.components.actionRow.actionType.required": "*",
|
|
32
|
+
"business_rules.components.actionRow.config.apiKey": "API-Schlüssel",
|
|
33
|
+
"business_rules.components.actionRow.config.apiKey.placeholder": "API-Schlüssel auswählen",
|
|
34
|
+
"business_rules.components.actionRow.config.body": "Body",
|
|
35
|
+
"business_rules.components.actionRow.config.body.placeholder": "JSON-Body eingeben. Verwenden Sie {{field}} für Interpolation.",
|
|
36
|
+
"business_rules.components.actionRow.config.endpoint": "Endpunkt",
|
|
37
|
+
"business_rules.components.actionRow.config.endpoint.placeholder": "Endpunkt auswählen",
|
|
32
38
|
"business_rules.components.actionRow.config.field.placeholder": "{{field}} eingeben",
|
|
33
39
|
"business_rules.components.actionRow.config.level": "Stufe",
|
|
34
40
|
"business_rules.components.actionRow.config.level.debug": "Debug",
|
|
@@ -45,6 +51,11 @@
|
|
|
45
51
|
"business_rules.components.actionRow.delete": "Aktion löschen",
|
|
46
52
|
"business_rules.components.actionRow.moveDown": "Nach unten",
|
|
47
53
|
"business_rules.components.actionRow.moveUp": "Nach oben",
|
|
54
|
+
"business_rules.components.actionRow.openMercato.options.error": "OpenMercato-Optionen nicht verfügbar: {{error}}",
|
|
55
|
+
"business_rules.components.actionRow.openMercato.options.fetchFailed": "OpenMercato-Optionen konnten nicht geladen werden ({{status}})",
|
|
56
|
+
"business_rules.components.actionRow.openMercato.options.loading": "OpenMercato-Optionen werden geladen...",
|
|
57
|
+
"business_rules.components.actionRow.openMercato.options.noApiKeys": "Keine API-Schlüsselprofile verfügbar.",
|
|
58
|
+
"business_rules.components.actionRow.openMercato.options.noEndpoints": "Keine ausführbaren OpenMercato-Endpunkte verfügbar.",
|
|
48
59
|
"business_rules.components.conditionBuilder.addFirstCondition": "Erste Bedingung hinzufügen",
|
|
49
60
|
"business_rules.components.conditionBuilder.clearAll": "Alle löschen",
|
|
50
61
|
"business_rules.components.conditionBuilder.confirm.clearAll": "Sind Sie sicher, dass Sie alle Bedingungen löschen möchten?",
|
|
@@ -324,6 +335,7 @@
|
|
|
324
335
|
"business_rules.validation.action.unknownType": "Unbekannter Aktionstyp \"{{type}}\". Gültige Typen sind: {{validTypes}}",
|
|
325
336
|
"business_rules.validation.actionTypes.ALLOW_TRANSITION": "Übergang erlauben",
|
|
326
337
|
"business_rules.validation.actionTypes.BLOCK_TRANSITION": "Übergang blockieren",
|
|
338
|
+
"business_rules.validation.actionTypes.CALL_OPEN_MERCATO": "OpenMercato aufrufen",
|
|
327
339
|
"business_rules.validation.actionTypes.CALL_WEBHOOK": "Webhook aufrufen",
|
|
328
340
|
"business_rules.validation.actionTypes.EMIT_EVENT": "Ereignis auslösen",
|
|
329
341
|
"business_rules.validation.actionTypes.LOG": "Nachricht protokollieren",
|
|
@@ -29,6 +29,12 @@
|
|
|
29
29
|
"business_rules.components.actionRow.actionType": "Action Type",
|
|
30
30
|
"business_rules.components.actionRow.actionType.placeholder": "Select action type...",
|
|
31
31
|
"business_rules.components.actionRow.actionType.required": "*",
|
|
32
|
+
"business_rules.components.actionRow.config.apiKey": "API key",
|
|
33
|
+
"business_rules.components.actionRow.config.apiKey.placeholder": "Select API key",
|
|
34
|
+
"business_rules.components.actionRow.config.body": "body",
|
|
35
|
+
"business_rules.components.actionRow.config.body.placeholder": "Enter JSON body. Use {{field}} for interpolation.",
|
|
36
|
+
"business_rules.components.actionRow.config.endpoint": "endpoint",
|
|
37
|
+
"business_rules.components.actionRow.config.endpoint.placeholder": "Select endpoint",
|
|
32
38
|
"business_rules.components.actionRow.config.field.placeholder": "Enter {{field}}",
|
|
33
39
|
"business_rules.components.actionRow.config.level": "level",
|
|
34
40
|
"business_rules.components.actionRow.config.level.debug": "Debug",
|
|
@@ -45,6 +51,11 @@
|
|
|
45
51
|
"business_rules.components.actionRow.delete": "Delete action",
|
|
46
52
|
"business_rules.components.actionRow.moveDown": "Move down",
|
|
47
53
|
"business_rules.components.actionRow.moveUp": "Move up",
|
|
54
|
+
"business_rules.components.actionRow.openMercato.options.error": "OpenMercato options unavailable: {{error}}",
|
|
55
|
+
"business_rules.components.actionRow.openMercato.options.fetchFailed": "Failed to load OpenMercato options ({{status}})",
|
|
56
|
+
"business_rules.components.actionRow.openMercato.options.loading": "Loading OpenMercato options...",
|
|
57
|
+
"business_rules.components.actionRow.openMercato.options.noApiKeys": "No API key profiles are available.",
|
|
58
|
+
"business_rules.components.actionRow.openMercato.options.noEndpoints": "No executable OpenMercato endpoints are available.",
|
|
48
59
|
"business_rules.components.conditionBuilder.addFirstCondition": "Add First Condition",
|
|
49
60
|
"business_rules.components.conditionBuilder.clearAll": "Clear All",
|
|
50
61
|
"business_rules.components.conditionBuilder.confirm.clearAll": "Are you sure you want to clear all conditions?",
|
|
@@ -324,6 +335,7 @@
|
|
|
324
335
|
"business_rules.validation.action.unknownType": "Unknown action type \"{{type}}\". Valid types are: {{validTypes}}",
|
|
325
336
|
"business_rules.validation.actionTypes.ALLOW_TRANSITION": "Allow Transition",
|
|
326
337
|
"business_rules.validation.actionTypes.BLOCK_TRANSITION": "Block Transition",
|
|
338
|
+
"business_rules.validation.actionTypes.CALL_OPEN_MERCATO": "Call OpenMercato",
|
|
327
339
|
"business_rules.validation.actionTypes.CALL_WEBHOOK": "Call Webhook",
|
|
328
340
|
"business_rules.validation.actionTypes.EMIT_EVENT": "Emit Event",
|
|
329
341
|
"business_rules.validation.actionTypes.LOG": "Log Message",
|
|
@@ -29,6 +29,12 @@
|
|
|
29
29
|
"business_rules.components.actionRow.actionType": "Tipo de Acción",
|
|
30
30
|
"business_rules.components.actionRow.actionType.placeholder": "Seleccionar tipo de acción...",
|
|
31
31
|
"business_rules.components.actionRow.actionType.required": "*",
|
|
32
|
+
"business_rules.components.actionRow.config.apiKey": "clave API",
|
|
33
|
+
"business_rules.components.actionRow.config.apiKey.placeholder": "Seleccione clave API",
|
|
34
|
+
"business_rules.components.actionRow.config.body": "body",
|
|
35
|
+
"business_rules.components.actionRow.config.body.placeholder": "Ingrese body JSON. Use {{field}} para interpolación.",
|
|
36
|
+
"business_rules.components.actionRow.config.endpoint": "endpoint",
|
|
37
|
+
"business_rules.components.actionRow.config.endpoint.placeholder": "Seleccione endpoint",
|
|
32
38
|
"business_rules.components.actionRow.config.field.placeholder": "Ingrese {{field}}",
|
|
33
39
|
"business_rules.components.actionRow.config.level": "nivel",
|
|
34
40
|
"business_rules.components.actionRow.config.level.debug": "Debug",
|
|
@@ -45,6 +51,11 @@
|
|
|
45
51
|
"business_rules.components.actionRow.delete": "Eliminar acción",
|
|
46
52
|
"business_rules.components.actionRow.moveDown": "Mover abajo",
|
|
47
53
|
"business_rules.components.actionRow.moveUp": "Mover arriba",
|
|
54
|
+
"business_rules.components.actionRow.openMercato.options.error": "Opciones de OpenMercato no disponibles: {{error}}",
|
|
55
|
+
"business_rules.components.actionRow.openMercato.options.fetchFailed": "No se pudieron cargar las opciones de OpenMercato ({{status}})",
|
|
56
|
+
"business_rules.components.actionRow.openMercato.options.loading": "Cargando opciones de OpenMercato...",
|
|
57
|
+
"business_rules.components.actionRow.openMercato.options.noApiKeys": "No hay perfiles de claves API disponibles.",
|
|
58
|
+
"business_rules.components.actionRow.openMercato.options.noEndpoints": "No hay endpoints ejecutables de OpenMercato disponibles.",
|
|
48
59
|
"business_rules.components.conditionBuilder.addFirstCondition": "Añadir Primera Condición",
|
|
49
60
|
"business_rules.components.conditionBuilder.clearAll": "Limpiar Todo",
|
|
50
61
|
"business_rules.components.conditionBuilder.confirm.clearAll": "¿Está seguro de que desea eliminar todas las condiciones?",
|
|
@@ -324,6 +335,7 @@
|
|
|
324
335
|
"business_rules.validation.action.unknownType": "Tipo de acción desconocido \"{{type}}\". Los tipos válidos son: {{validTypes}}",
|
|
325
336
|
"business_rules.validation.actionTypes.ALLOW_TRANSITION": "Permitir transición",
|
|
326
337
|
"business_rules.validation.actionTypes.BLOCK_TRANSITION": "Bloquear transición",
|
|
338
|
+
"business_rules.validation.actionTypes.CALL_OPEN_MERCATO": "Llamar OpenMercato",
|
|
327
339
|
"business_rules.validation.actionTypes.CALL_WEBHOOK": "Llamar webhook",
|
|
328
340
|
"business_rules.validation.actionTypes.EMIT_EVENT": "Emitir evento",
|
|
329
341
|
"business_rules.validation.actionTypes.LOG": "Registrar mensaje",
|
|
@@ -29,6 +29,12 @@
|
|
|
29
29
|
"business_rules.components.actionRow.actionType": "Typ Akcji",
|
|
30
30
|
"business_rules.components.actionRow.actionType.placeholder": "Wybierz typ akcji...",
|
|
31
31
|
"business_rules.components.actionRow.actionType.required": "*",
|
|
32
|
+
"business_rules.components.actionRow.config.apiKey": "klucz API",
|
|
33
|
+
"business_rules.components.actionRow.config.apiKey.placeholder": "Wybierz klucz API",
|
|
34
|
+
"business_rules.components.actionRow.config.body": "body",
|
|
35
|
+
"business_rules.components.actionRow.config.body.placeholder": "Wprowadź body JSON. Użyj {{field}} dla interpolacji.",
|
|
36
|
+
"business_rules.components.actionRow.config.endpoint": "endpoint",
|
|
37
|
+
"business_rules.components.actionRow.config.endpoint.placeholder": "Wybierz endpoint",
|
|
32
38
|
"business_rules.components.actionRow.config.field.placeholder": "Wprowadź {{field}}",
|
|
33
39
|
"business_rules.components.actionRow.config.level": "poziom",
|
|
34
40
|
"business_rules.components.actionRow.config.level.debug": "Debug",
|
|
@@ -45,6 +51,11 @@
|
|
|
45
51
|
"business_rules.components.actionRow.delete": "Usuń akcję",
|
|
46
52
|
"business_rules.components.actionRow.moveDown": "Przesuń w dół",
|
|
47
53
|
"business_rules.components.actionRow.moveUp": "Przesuń w górę",
|
|
54
|
+
"business_rules.components.actionRow.openMercato.options.error": "Opcje OpenMercato niedostępne: {{error}}",
|
|
55
|
+
"business_rules.components.actionRow.openMercato.options.fetchFailed": "Nie udało się załadować opcji OpenMercato ({{status}})",
|
|
56
|
+
"business_rules.components.actionRow.openMercato.options.loading": "Ładowanie opcji OpenMercato...",
|
|
57
|
+
"business_rules.components.actionRow.openMercato.options.noApiKeys": "Brak dostępnych profili kluczy API.",
|
|
58
|
+
"business_rules.components.actionRow.openMercato.options.noEndpoints": "Brak dostępnych wykonywalnych endpointów OpenMercato.",
|
|
48
59
|
"business_rules.components.conditionBuilder.addFirstCondition": "Dodaj Pierwszy Warunek",
|
|
49
60
|
"business_rules.components.conditionBuilder.clearAll": "Wyczyść Wszystko",
|
|
50
61
|
"business_rules.components.conditionBuilder.confirm.clearAll": "Czy na pewno chcesz wyczyścić wszystkie warunki?",
|
|
@@ -324,6 +335,7 @@
|
|
|
324
335
|
"business_rules.validation.action.unknownType": "Nieznany typ akcji \"{{type}}\". Prawidłowe typy to: {{validTypes}}",
|
|
325
336
|
"business_rules.validation.actionTypes.ALLOW_TRANSITION": "Zezwól na przejście",
|
|
326
337
|
"business_rules.validation.actionTypes.BLOCK_TRANSITION": "Zablokuj przejście",
|
|
338
|
+
"business_rules.validation.actionTypes.CALL_OPEN_MERCATO": "Wywołaj OpenMercato",
|
|
327
339
|
"business_rules.validation.actionTypes.CALL_WEBHOOK": "Wywołaj webhook",
|
|
328
340
|
"business_rules.validation.actionTypes.EMIT_EVENT": "Emituj zdarzenie",
|
|
329
341
|
"business_rules.validation.actionTypes.LOG": "Zapisz komunikat",
|