@open-mercato/core 0.4.2-canary-d0a025141f → 0.4.2-canary-3efa759f5c

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.
Files changed (158) hide show
  1. package/dist/generated/entities.ids.generated.js +0 -1
  2. package/dist/generated/entities.ids.generated.js.map +2 -2
  3. package/dist/generated/entity-fields-registry.js +0 -2
  4. package/dist/generated/entity-fields-registry.js.map +2 -2
  5. package/dist/modules/business_rules/data/validators.js +0 -34
  6. package/dist/modules/business_rules/data/validators.js.map +2 -2
  7. package/dist/modules/business_rules/index.js +1 -21
  8. package/dist/modules/business_rules/index.js.map +2 -2
  9. package/dist/modules/business_rules/lib/rule-engine.js +1 -182
  10. package/dist/modules/business_rules/lib/rule-engine.js.map +2 -2
  11. package/dist/modules/sales/acl.js +0 -1
  12. package/dist/modules/sales/acl.js.map +2 -2
  13. package/dist/modules/sales/backend/sales/documents/[id]/page.js +0 -12
  14. package/dist/modules/sales/backend/sales/documents/[id]/page.js.map +2 -2
  15. package/dist/modules/sales/commands/documents.js +0 -62
  16. package/dist/modules/sales/commands/documents.js.map +2 -2
  17. package/dist/modules/sales/lib/dictionaries.js +0 -3
  18. package/dist/modules/sales/lib/dictionaries.js.map +2 -2
  19. package/dist/modules/workflows/acl.js +0 -2
  20. package/dist/modules/workflows/acl.js.map +2 -2
  21. package/dist/modules/workflows/api/instances/route.js +6 -18
  22. package/dist/modules/workflows/api/instances/route.js.map +2 -2
  23. package/dist/modules/workflows/api/tasks/route.js +1 -6
  24. package/dist/modules/workflows/api/tasks/route.js.map +2 -2
  25. package/dist/modules/workflows/backend/definitions/[id]/page.js +1 -9
  26. package/dist/modules/workflows/backend/definitions/[id]/page.js.map +2 -2
  27. package/dist/modules/workflows/backend/definitions/[id]/page.meta.js +1 -1
  28. package/dist/modules/workflows/backend/definitions/[id]/page.meta.js.map +2 -2
  29. package/dist/modules/workflows/backend/definitions/create/page.js +15 -24
  30. package/dist/modules/workflows/backend/definitions/create/page.js.map +2 -2
  31. package/dist/modules/workflows/backend/definitions/create/page.meta.js +1 -1
  32. package/dist/modules/workflows/backend/definitions/create/page.meta.js.map +2 -2
  33. package/dist/modules/workflows/backend/definitions/visual-editor/page.js +132 -150
  34. package/dist/modules/workflows/backend/definitions/visual-editor/page.js.map +2 -2
  35. package/dist/modules/workflows/backend/definitions/visual-editor/page.meta.js +1 -1
  36. package/dist/modules/workflows/backend/definitions/visual-editor/page.meta.js.map +2 -2
  37. package/dist/modules/workflows/backend/events/[id]/page.js +1 -1
  38. package/dist/modules/workflows/backend/events/[id]/page.js.map +2 -2
  39. package/dist/modules/workflows/backend/events/[id]/page.meta.js +2 -2
  40. package/dist/modules/workflows/backend/events/[id]/page.meta.js.map +2 -2
  41. package/dist/modules/workflows/backend/instances/[id]/page.meta.js +2 -2
  42. package/dist/modules/workflows/backend/instances/[id]/page.meta.js.map +2 -2
  43. package/dist/modules/workflows/backend/tasks/[id]/page.js +1 -1
  44. package/dist/modules/workflows/backend/tasks/[id]/page.js.map +2 -2
  45. package/dist/modules/workflows/backend/tasks/[id]/page.meta.js +2 -2
  46. package/dist/modules/workflows/backend/tasks/[id]/page.meta.js.map +2 -2
  47. package/dist/modules/workflows/backend/tasks/page.js +6 -5
  48. package/dist/modules/workflows/backend/tasks/page.js.map +2 -2
  49. package/dist/modules/workflows/cli.js +3 -81
  50. package/dist/modules/workflows/cli.js.map +3 -3
  51. package/dist/modules/workflows/data/entities.js +1 -64
  52. package/dist/modules/workflows/data/entities.js.map +2 -2
  53. package/dist/modules/workflows/data/validators.js +0 -115
  54. package/dist/modules/workflows/data/validators.js.map +2 -2
  55. package/dist/modules/workflows/examples/checkout-demo-definition.json +5 -1
  56. package/dist/modules/workflows/lib/activity-executor.js +13 -75
  57. package/dist/modules/workflows/lib/activity-executor.js.map +2 -2
  58. package/dist/modules/workflows/lib/graph-utils.js +2 -71
  59. package/dist/modules/workflows/lib/graph-utils.js.map +2 -2
  60. package/dist/modules/workflows/lib/seeds.js +5 -22
  61. package/dist/modules/workflows/lib/seeds.js.map +2 -2
  62. package/dist/modules/workflows/lib/start-validator.js +23 -33
  63. package/dist/modules/workflows/lib/start-validator.js.map +2 -2
  64. package/dist/modules/workflows/lib/transition-handler.js +45 -157
  65. package/dist/modules/workflows/lib/transition-handler.js.map +3 -3
  66. package/generated/entities.ids.generated.ts +0 -1
  67. package/generated/entity-fields-registry.ts +0 -2
  68. package/package.json +2 -2
  69. package/src/modules/business_rules/data/validators.ts +0 -40
  70. package/src/modules/business_rules/index.ts +0 -25
  71. package/src/modules/business_rules/lib/rule-engine.ts +1 -281
  72. package/src/modules/sales/acl.ts +0 -1
  73. package/src/modules/sales/backend/sales/documents/[id]/page.tsx +0 -16
  74. package/src/modules/sales/commands/documents.ts +1 -74
  75. package/src/modules/sales/lib/dictionaries.ts +0 -3
  76. package/src/modules/workflows/acl.ts +0 -2
  77. package/src/modules/workflows/api/__tests__/instances.route.test.ts +2 -5
  78. package/src/modules/workflows/api/instances/route.ts +7 -21
  79. package/src/modules/workflows/api/tasks/route.ts +1 -7
  80. package/src/modules/workflows/backend/definitions/[id]/page.meta.ts +1 -1
  81. package/src/modules/workflows/backend/definitions/[id]/page.tsx +0 -9
  82. package/src/modules/workflows/backend/definitions/create/page.meta.ts +1 -1
  83. package/src/modules/workflows/backend/definitions/create/page.tsx +0 -9
  84. package/src/modules/workflows/backend/definitions/visual-editor/page.meta.ts +1 -1
  85. package/src/modules/workflows/backend/definitions/visual-editor/page.tsx +3 -21
  86. package/src/modules/workflows/backend/events/[id]/page.meta.ts +2 -2
  87. package/src/modules/workflows/backend/events/[id]/page.tsx +1 -1
  88. package/src/modules/workflows/backend/instances/[id]/page.meta.ts +2 -2
  89. package/src/modules/workflows/backend/tasks/[id]/page.meta.ts +2 -2
  90. package/src/modules/workflows/backend/tasks/[id]/page.tsx +1 -1
  91. package/src/modules/workflows/backend/tasks/page.tsx +6 -5
  92. package/src/modules/workflows/cli.ts +0 -111
  93. package/src/modules/workflows/data/entities.ts +0 -124
  94. package/src/modules/workflows/data/validators.ts +0 -138
  95. package/src/modules/workflows/examples/checkout-demo-definition.json +5 -1
  96. package/src/modules/workflows/i18n/en.json +0 -71
  97. package/src/modules/workflows/lib/__tests__/activity-executor.test.ts +36 -43
  98. package/src/modules/workflows/lib/__tests__/transition-handler.test.ts +90 -170
  99. package/src/modules/workflows/lib/activity-executor.ts +16 -129
  100. package/src/modules/workflows/lib/graph-utils.ts +2 -117
  101. package/src/modules/workflows/lib/seeds.ts +8 -34
  102. package/src/modules/workflows/lib/start-validator.ts +28 -38
  103. package/src/modules/workflows/lib/transition-handler.ts +55 -208
  104. package/dist/generated/entities/workflow_event_trigger/index.js +0 -33
  105. package/dist/generated/entities/workflow_event_trigger/index.js.map +0 -7
  106. package/dist/modules/auth/events.js +0 -30
  107. package/dist/modules/auth/events.js.map +0 -7
  108. package/dist/modules/business_rules/api/execute/[ruleId]/route.js +0 -145
  109. package/dist/modules/business_rules/api/execute/[ruleId]/route.js.map +0 -7
  110. package/dist/modules/catalog/events.js +0 -34
  111. package/dist/modules/catalog/events.js.map +0 -7
  112. package/dist/modules/customers/events.js +0 -49
  113. package/dist/modules/customers/events.js.map +0 -7
  114. package/dist/modules/directory/events.js +0 -23
  115. package/dist/modules/directory/events.js.map +0 -7
  116. package/dist/modules/sales/events.js +0 -63
  117. package/dist/modules/sales/events.js.map +0 -7
  118. package/dist/modules/sales/lib/frontend/documentDataEvents.js +0 -25
  119. package/dist/modules/sales/lib/frontend/documentDataEvents.js.map +0 -7
  120. package/dist/modules/workflows/components/DefinitionTriggersEditor.js +0 -481
  121. package/dist/modules/workflows/components/DefinitionTriggersEditor.js.map +0 -7
  122. package/dist/modules/workflows/components/EventTriggersEditor.js +0 -553
  123. package/dist/modules/workflows/components/EventTriggersEditor.js.map +0 -7
  124. package/dist/modules/workflows/events.js +0 -38
  125. package/dist/modules/workflows/events.js.map +0 -7
  126. package/dist/modules/workflows/examples/order-approval-definition.json +0 -257
  127. package/dist/modules/workflows/examples/order-approval-guard-rules.json +0 -32
  128. package/dist/modules/workflows/lib/event-trigger-service.js +0 -308
  129. package/dist/modules/workflows/lib/event-trigger-service.js.map +0 -7
  130. package/dist/modules/workflows/migrations/Migration20260123143500.js +0 -36
  131. package/dist/modules/workflows/migrations/Migration20260123143500.js.map +0 -7
  132. package/dist/modules/workflows/subscribers/event-trigger.js +0 -78
  133. package/dist/modules/workflows/subscribers/event-trigger.js.map +0 -7
  134. package/dist/modules/workflows/widgets/injection/order-approval/widget.client.js +0 -323
  135. package/dist/modules/workflows/widgets/injection/order-approval/widget.client.js.map +0 -7
  136. package/dist/modules/workflows/widgets/injection/order-approval/widget.js +0 -17
  137. package/dist/modules/workflows/widgets/injection/order-approval/widget.js.map +0 -7
  138. package/dist/modules/workflows/widgets/injection-table.js +0 -19
  139. package/dist/modules/workflows/widgets/injection-table.js.map +0 -7
  140. package/generated/entities/workflow_event_trigger/index.ts +0 -15
  141. package/src/modules/auth/events.ts +0 -39
  142. package/src/modules/business_rules/api/execute/[ruleId]/route.ts +0 -163
  143. package/src/modules/catalog/events.ts +0 -45
  144. package/src/modules/customers/events.ts +0 -63
  145. package/src/modules/directory/events.ts +0 -31
  146. package/src/modules/sales/events.ts +0 -82
  147. package/src/modules/sales/lib/frontend/documentDataEvents.ts +0 -28
  148. package/src/modules/workflows/components/DefinitionTriggersEditor.tsx +0 -581
  149. package/src/modules/workflows/components/EventTriggersEditor.tsx +0 -664
  150. package/src/modules/workflows/events.ts +0 -49
  151. package/src/modules/workflows/examples/order-approval-definition.json +0 -257
  152. package/src/modules/workflows/examples/order-approval-guard-rules.json +0 -32
  153. package/src/modules/workflows/lib/event-trigger-service.ts +0 -557
  154. package/src/modules/workflows/migrations/Migration20260123143500.ts +0 -38
  155. package/src/modules/workflows/subscribers/event-trigger.ts +0 -109
  156. package/src/modules/workflows/widgets/injection/order-approval/widget.client.tsx +0 -446
  157. package/src/modules/workflows/widgets/injection/order-approval/widget.ts +0 -16
  158. package/src/modules/workflows/widgets/injection-table.ts +0 -21
@@ -153,7 +153,6 @@ const E = {
153
153
  "user_task": "workflows:user_task",
154
154
  "workflow_definition": "workflows:workflow_definition",
155
155
  "workflow_event": "workflows:workflow_event",
156
- "workflow_event_trigger": "workflows:workflow_event_trigger",
157
156
  "workflow_instance": "workflows:workflow_instance"
158
157
  },
159
158
  "currencies": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../generated/entities.ids.generated.ts"],
4
- "sourcesContent": ["// AUTO-GENERATED by mercato generate entity-ids\nexport const M = {\n \"dashboards\": \"dashboards\",\n \"auth\": \"auth\",\n \"directory\": \"directory\",\n \"customers\": \"customers\",\n \"perspectives\": \"perspectives\",\n \"entities\": \"entities\",\n \"configs\": \"configs\",\n \"query_index\": \"query_index\",\n \"audit_logs\": \"audit_logs\",\n \"attachments\": \"attachments\",\n \"catalog\": \"catalog\",\n \"sales\": \"sales\",\n \"api_keys\": \"api_keys\",\n \"dictionaries\": \"dictionaries\",\n \"api_docs\": \"api_docs\",\n \"business_rules\": \"business_rules\",\n \"feature_toggles\": \"feature_toggles\",\n \"workflows\": \"workflows\",\n \"currencies\": \"currencies\",\n \"planner\": \"planner\",\n \"resources\": \"resources\",\n \"staff\": \"staff\"\n} as const\nexport const E = {\n \"dashboards\": {\n \"dashboard_layout\": \"dashboards:dashboard_layout\",\n \"dashboard_role_widgets\": \"dashboards:dashboard_role_widgets\",\n \"dashboard_user_widgets\": \"dashboards:dashboard_user_widgets\"\n },\n \"auth\": {\n \"password_reset\": \"auth:password_reset\",\n \"role\": \"auth:role\",\n \"role_acl\": \"auth:role_acl\",\n \"role_sidebar_preference\": \"auth:role_sidebar_preference\",\n \"session\": \"auth:session\",\n \"user\": \"auth:user\",\n \"user_acl\": \"auth:user_acl\",\n \"user_role\": \"auth:user_role\",\n \"user_sidebar_preference\": \"auth:user_sidebar_preference\"\n },\n \"directory\": {\n \"organization\": \"directory:organization\",\n \"tenant\": \"directory:tenant\"\n },\n \"customers\": {\n \"customer_activity\": \"customers:customer_activity\",\n \"customer_address\": \"customers:customer_address\",\n \"customer_comment\": \"customers:customer_comment\",\n \"customer_company_profile\": \"customers:customer_company_profile\",\n \"customer_deal\": \"customers:customer_deal\",\n \"customer_deal_company_link\": \"customers:customer_deal_company_link\",\n \"customer_deal_person_link\": \"customers:customer_deal_person_link\",\n \"customer_dictionary_entry\": \"customers:customer_dictionary_entry\",\n \"customer_entity\": \"customers:customer_entity\",\n \"customer_person_profile\": \"customers:customer_person_profile\",\n \"customer_settings\": \"customers:customer_settings\",\n \"customer_tag\": \"customers:customer_tag\",\n \"customer_tag_assignment\": \"customers:customer_tag_assignment\",\n \"customer_todo_link\": \"customers:customer_todo_link\"\n },\n \"perspectives\": {\n \"perspective\": \"perspectives:perspective\",\n \"role_perspective\": \"perspectives:role_perspective\"\n },\n \"entities\": {\n \"custom_entity\": \"entities:custom_entity\",\n \"custom_entity_storage\": \"entities:custom_entity_storage\",\n \"custom_field_def\": \"entities:custom_field_def\",\n \"custom_field_entity_config\": \"entities:custom_field_entity_config\",\n \"custom_field_value\": \"entities:custom_field_value\",\n \"encryption_map\": \"entities:encryption_map\"\n },\n \"configs\": {\n \"module_config\": \"configs:module_config\",\n \"upgrade_action_run\": \"configs:upgrade_action_run\"\n },\n \"query_index\": {\n \"entity_index_coverage\": \"query_index:entity_index_coverage\",\n \"entity_index_job\": \"query_index:entity_index_job\",\n \"entity_index_row\": \"query_index:entity_index_row\",\n \"indexer_error_log\": \"query_index:indexer_error_log\",\n \"indexer_status_log\": \"query_index:indexer_status_log\",\n \"search_token\": \"query_index:search_token\"\n },\n \"audit_logs\": {\n \"access_log\": \"audit_logs:access_log\",\n \"action_log\": \"audit_logs:action_log\"\n },\n \"attachments\": {\n \"attachment\": \"attachments:attachment\",\n \"attachment_partition\": \"attachments:attachment_partition\"\n },\n \"catalog\": {\n \"catalog_offer\": \"catalog:catalog_offer\",\n \"catalog_option_schema_template\": \"catalog:catalog_option_schema_template\",\n \"catalog_price_kind\": \"catalog:catalog_price_kind\",\n \"catalog_product\": \"catalog:catalog_product\",\n \"catalog_product_category\": \"catalog:catalog_product_category\",\n \"catalog_product_category_assignment\": \"catalog:catalog_product_category_assignment\",\n \"catalog_product_price\": \"catalog:catalog_product_price\",\n \"catalog_product_tag\": \"catalog:catalog_product_tag\",\n \"catalog_product_tag_assignment\": \"catalog:catalog_product_tag_assignment\",\n \"catalog_product_variant\": \"catalog:catalog_product_variant\",\n \"catalog_product_variant_relation\": \"catalog:catalog_product_variant_relation\"\n },\n \"sales\": {\n \"sales_channel\": \"sales:sales_channel\",\n \"sales_credit_memo\": \"sales:sales_credit_memo\",\n \"sales_credit_memo_line\": \"sales:sales_credit_memo_line\",\n \"sales_delivery_window\": \"sales:sales_delivery_window\",\n \"sales_document_address\": \"sales:sales_document_address\",\n \"sales_document_sequence\": \"sales:sales_document_sequence\",\n \"sales_document_tag\": \"sales:sales_document_tag\",\n \"sales_document_tag_assignment\": \"sales:sales_document_tag_assignment\",\n \"sales_invoice\": \"sales:sales_invoice\",\n \"sales_invoice_line\": \"sales:sales_invoice_line\",\n \"sales_note\": \"sales:sales_note\",\n \"sales_order\": \"sales:sales_order\",\n \"sales_order_adjustment\": \"sales:sales_order_adjustment\",\n \"sales_order_line\": \"sales:sales_order_line\",\n \"sales_payment\": \"sales:sales_payment\",\n \"sales_payment_allocation\": \"sales:sales_payment_allocation\",\n \"sales_payment_method\": \"sales:sales_payment_method\",\n \"sales_quote\": \"sales:sales_quote\",\n \"sales_quote_adjustment\": \"sales:sales_quote_adjustment\",\n \"sales_quote_line\": \"sales:sales_quote_line\",\n \"sales_settings\": \"sales:sales_settings\",\n \"sales_shipment\": \"sales:sales_shipment\",\n \"sales_shipment_item\": \"sales:sales_shipment_item\",\n \"sales_shipping_method\": \"sales:sales_shipping_method\",\n \"sales_tax_rate\": \"sales:sales_tax_rate\"\n },\n \"api_keys\": {\n \"api_key\": \"api_keys:api_key\"\n },\n \"dictionaries\": {\n \"dictionary\": \"dictionaries:dictionary\",\n \"dictionary_entry\": \"dictionaries:dictionary_entry\"\n },\n \"business_rules\": {\n \"business_rule\": \"business_rules:business_rule\",\n \"rule_execution_log\": \"business_rules:rule_execution_log\",\n \"rule_set\": \"business_rules:rule_set\",\n \"rule_set_member\": \"business_rules:rule_set_member\"\n },\n \"feature_toggles\": {\n \"feature_toggle\": \"feature_toggles:feature_toggle\",\n \"feature_toggle_override\": \"feature_toggles:feature_toggle_override\"\n },\n \"workflows\": {\n \"step_instance\": \"workflows:step_instance\",\n \"user_task\": \"workflows:user_task\",\n \"workflow_definition\": \"workflows:workflow_definition\",\n \"workflow_event\": \"workflows:workflow_event\",\n \"workflow_event_trigger\": \"workflows:workflow_event_trigger\",\n \"workflow_instance\": \"workflows:workflow_instance\"\n },\n \"currencies\": {\n \"currency\": \"currencies:currency\",\n \"currency_fetch_config\": \"currencies:currency_fetch_config\",\n \"exchange_rate\": \"currencies:exchange_rate\"\n },\n \"planner\": {\n \"planner_availability_rule\": \"planner:planner_availability_rule\",\n \"planner_availability_rule_set\": \"planner:planner_availability_rule_set\"\n },\n \"resources\": {\n \"resources_resource\": \"resources:resources_resource\",\n \"resources_resource_activity\": \"resources:resources_resource_activity\",\n \"resources_resource_comment\": \"resources:resources_resource_comment\",\n \"resources_resource_tag\": \"resources:resources_resource_tag\",\n \"resources_resource_tag_assignment\": \"resources:resources_resource_tag_assignment\",\n \"resources_resource_type\": \"resources:resources_resource_type\"\n },\n \"staff\": {\n \"staff_leave_request\": \"staff:staff_leave_request\",\n \"staff_team\": \"staff:staff_team\",\n \"staff_team_member\": \"staff:staff_team_member\",\n \"staff_team_member_activity\": \"staff:staff_team_member_activity\",\n \"staff_team_member_address\": \"staff:staff_team_member_address\",\n \"staff_team_member_comment\": \"staff:staff_team_member_comment\",\n \"staff_team_member_job_history\": \"staff:staff_team_member_job_history\",\n \"staff_team_role\": \"staff:staff_team_role\"\n }\n} as const\nex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AuB;AAAA,IACvB,yBAAyB;AAAA,IACzB,kBAAkB;AAAA,EACpB;AAAA,EACA,YAAY;AAAA,IACV,WAAW;AAAA,EACb;AAAA,EACA,gBAAgB;AAAA,IACd,cAAc;AAAA,IACd,oBAAoB;AAAA,EACtB;AAAA,EACA,kBAAkB;AAAA,IAChB,iBAAiB;AAAA,IACjB,sBAAsB;AAAA,IACtB,YAAY;AAAA,IACZ,mBAAmB;AAAA,EACrB;AAAA,EACA,mBAAmB;AAAA,IACjB,kBAAkB;AAAA,IAClB,2BAA2B;AAAA,EAC7B;AAAA,EACA,aAAa;AAAA,IACX,iBAAiB;AAAA,IACjB,aAAa;AAAA,IACb,uBAAuB;AAAA,IACvB,kBAAkB;AAAA,IAClB,0BAA0B;AAAA,IAC1B,qBAAqB;AAAA,EACvB;AAAA,EACA,cAAc;AAAA,IACZ,YAAY;AAAA,IACZ,yBAAyB;AAAA,IACzB,iBAAiB;AAAA,EACnB;AAAA,EACA,WAAW;AAAA,IACT,6BAA6B;AAAA,IAC7B,iCAAiC;AAAA,EACnC;AAAA,EACA,aAAa;AAAA,IACX,sBAAsB;AAAA,IACtB,+BAA+B;AAAA,IAC/B,8BAA8B;AAAA,IAC9B,0BAA0B;AAAA,IAC1B,qCAAqC;AAAA,IACrC,2BAA2B;AAAA,EAC7B;AAAA,EACA,SAAS;AAAA,IACP,uBAAuB;AAAA,IACvB,cAAc;AAAA,IACd,qBAAqB;AAAA,IACrB,8BAA8B;AAAA,IAC9B,6BAA6B;AAAA,IAC7B,6BAA6B;AAAA,IAC7B,iCAAiC;AAAA,IACjC,mBAAmB;AAAA,EACrB;AACF;",
4
+ "sourcesContent": ["// AUTO-GENERATED by mercato generate entity-ids\nexport const M = {\n \"dashboards\": \"dashboards\",\n \"auth\": \"auth\",\n \"directory\": \"directory\",\n \"customers\": \"customers\",\n \"perspectives\": \"perspectives\",\n \"entities\": \"entities\",\n \"configs\": \"configs\",\n \"query_index\": \"query_index\",\n \"audit_logs\": \"audit_logs\",\n \"attachments\": \"attachments\",\n \"catalog\": \"catalog\",\n \"sales\": \"sales\",\n \"api_keys\": \"api_keys\",\n \"dictionaries\": \"dictionaries\",\n \"api_docs\": \"api_docs\",\n \"business_rules\": \"business_rules\",\n \"feature_toggles\": \"feature_toggles\",\n \"workflows\": \"workflows\",\n \"currencies\": \"currencies\",\n \"planner\": \"planner\",\n \"resources\": \"resources\",\n \"staff\": \"staff\"\n} as const\nexport const E = {\n \"dashboards\": {\n \"dashboard_layout\": \"dashboards:dashboard_layout\",\n \"dashboard_role_widgets\": \"dashboards:dashboard_role_widgets\",\n \"dashboard_user_widgets\": \"dashboards:dashboard_user_widgets\"\n },\n \"auth\": {\n \"password_reset\": \"auth:password_reset\",\n \"role\": \"auth:role\",\n \"role_acl\": \"auth:role_acl\",\n \"role_sidebar_preference\": \"auth:role_sidebar_preference\",\n \"session\": \"auth:session\",\n \"user\": \"auth:user\",\n \"user_acl\": \"auth:user_acl\",\n \"user_role\": \"auth:user_role\",\n \"user_sidebar_preference\": \"auth:user_sidebar_preference\"\n },\n \"directory\": {\n \"organization\": \"directory:organization\",\n \"tenant\": \"directory:tenant\"\n },\n \"customers\": {\n \"customer_activity\": \"customers:customer_activity\",\n \"customer_address\": \"customers:customer_address\",\n \"customer_comment\": \"customers:customer_comment\",\n \"customer_company_profile\": \"customers:customer_company_profile\",\n \"customer_deal\": \"customers:customer_deal\",\n \"customer_deal_company_link\": \"customers:customer_deal_company_link\",\n \"customer_deal_person_link\": \"customers:customer_deal_person_link\",\n \"customer_dictionary_entry\": \"customers:customer_dictionary_entry\",\n \"customer_entity\": \"customers:customer_entity\",\n \"customer_person_profile\": \"customers:customer_person_profile\",\n \"customer_settings\": \"customers:customer_settings\",\n \"customer_tag\": \"customers:customer_tag\",\n \"customer_tag_assignment\": \"customers:customer_tag_assignment\",\n \"customer_todo_link\": \"customers:customer_todo_link\"\n },\n \"perspectives\": {\n \"perspective\": \"perspectives:perspective\",\n \"role_perspective\": \"perspectives:role_perspective\"\n },\n \"entities\": {\n \"custom_entity\": \"entities:custom_entity\",\n \"custom_entity_storage\": \"entities:custom_entity_storage\",\n \"custom_field_def\": \"entities:custom_field_def\",\n \"custom_field_entity_config\": \"entities:custom_field_entity_config\",\n \"custom_field_value\": \"entities:custom_field_value\",\n \"encryption_map\": \"entities:encryption_map\"\n },\n \"configs\": {\n \"module_config\": \"configs:module_config\",\n \"upgrade_action_run\": \"configs:upgrade_action_run\"\n },\n \"query_index\": {\n \"entity_index_coverage\": \"query_index:entity_index_coverage\",\n \"entity_index_job\": \"query_index:entity_index_job\",\n \"entity_index_row\": \"query_index:entity_index_row\",\n \"indexer_error_log\": \"query_index:indexer_error_log\",\n \"indexer_status_log\": \"query_index:indexer_status_log\",\n \"search_token\": \"query_index:search_token\"\n },\n \"audit_logs\": {\n \"access_log\": \"audit_logs:access_log\",\n \"action_log\": \"audit_logs:action_log\"\n },\n \"attachments\": {\n \"attachment\": \"attachments:attachment\",\n \"attachment_partition\": \"attachments:attachment_partition\"\n },\n \"catalog\": {\n \"catalog_offer\": \"catalog:catalog_offer\",\n \"catalog_option_schema_template\": \"catalog:catalog_option_schema_template\",\n \"catalog_price_kind\": \"catalog:catalog_price_kind\",\n \"catalog_product\": \"catalog:catalog_product\",\n \"catalog_product_category\": \"catalog:catalog_product_category\",\n \"catalog_product_category_assignment\": \"catalog:catalog_product_category_assignment\",\n \"catalog_product_price\": \"catalog:catalog_product_price\",\n \"catalog_product_tag\": \"catalog:catalog_product_tag\",\n \"catalog_product_tag_assignment\": \"catalog:catalog_product_tag_assignment\",\n \"catalog_product_variant\": \"catalog:catalog_product_variant\",\n \"catalog_product_variant_relation\": \"catalog:catalog_product_variant_relation\"\n },\n \"sales\": {\n \"sales_channel\": \"sales:sales_channel\",\n \"sales_credit_memo\": \"sales:sales_credit_memo\",\n \"sales_credit_memo_line\": \"sales:sales_credit_memo_line\",\n \"sales_delivery_window\": \"sales:sales_delivery_window\",\n \"sales_document_address\": \"sales:sales_document_address\",\n \"sales_document_sequence\": \"sales:sales_document_sequence\",\n \"sales_document_tag\": \"sales:sales_document_tag\",\n \"sales_document_tag_assignment\": \"sales:sales_document_tag_assignment\",\n \"sales_invoice\": \"sales:sales_invoice\",\n \"sales_invoice_line\": \"sales:sales_invoice_line\",\n \"sales_note\": \"sales:sales_note\",\n \"sales_order\": \"sales:sales_order\",\n \"sales_order_adjustment\": \"sales:sales_order_adjustment\",\n \"sales_order_line\": \"sales:sales_order_line\",\n \"sales_payment\": \"sales:sales_payment\",\n \"sales_payment_allocation\": \"sales:sales_payment_allocation\",\n \"sales_payment_method\": \"sales:sales_payment_method\",\n \"sales_quote\": \"sales:sales_quote\",\n \"sales_quote_adjustment\": \"sales:sales_quote_adjustment\",\n \"sales_quote_line\": \"sales:sales_quote_line\",\n \"sales_settings\": \"sales:sales_settings\",\n \"sales_shipment\": \"sales:sales_shipment\",\n \"sales_shipment_item\": \"sales:sales_shipment_item\",\n \"sales_shipping_method\": \"sales:sales_shipping_method\",\n \"sales_tax_rate\": \"sales:sales_tax_rate\"\n },\n \"api_keys\": {\n \"api_key\": \"api_keys:api_key\"\n },\n \"dictionaries\": {\n \"dictionary\": \"dictionaries:dictionary\",\n \"dictionary_entry\": \"dictionaries:dictionary_entry\"\n },\n \"business_rules\": {\n \"business_rule\": \"business_rules:business_rule\",\n \"rule_execution_log\": \"business_rules:rule_execution_log\",\n \"rule_set\": \"business_rules:rule_set\",\n \"rule_set_member\": \"business_rules:rule_set_member\"\n },\n \"feature_toggles\": {\n \"feature_toggle\": \"feature_toggles:feature_toggle\",\n \"feature_toggle_override\": \"feature_toggles:feature_toggle_override\"\n },\n \"workflows\": {\n \"step_instance\": \"workflows:step_instance\",\n \"user_task\": \"workflows:user_task\",\n \"workflow_definition\": \"workflows:workflow_definition\",\n \"workflow_event\": \"workflows:workflow_event\",\n \"workflow_instance\": \"workflows:workflow_instance\"\n },\n \"currencies\": {\n \"currency\": \"currencies:currency\",\n \"currency_fetch_config\": \"currencies:currency_fetch_config\",\n \"exchange_rate\": \"currencies:exchange_rate\"\n },\n \"planner\": {\n \"planner_availability_rule\": \"planner:planner_availability_rule\",\n \"planner_availability_rule_set\": \"planner:planner_availability_rule_set\"\n },\n \"resources\": {\n \"resources_resource\": \"resources:resources_resource\",\n \"resources_resource_activity\": \"resources:resources_resource_activity\",\n \"resources_resource_comment\": \"resources:resources_resource_comment\",\n \"resources_resource_tag\": \"resources:resources_resource_tag\",\n \"resources_resource_tag_assignment\": \"resources:resources_resource_tag_assignment\",\n \"resources_resource_type\": \"resources:resources_resource_type\"\n },\n \"staff\": {\n \"staff_leave_request\": \"staff:staff_leave_request\",\n \"staff_team\": \"staff:staff_team\",\n \"staff_team_member\": \"staff:staff_team_member\",\n \"staff_team_member_activity\": \"staff:staff_team_member_activity\",\n \"staff_team_member_address\": \"staff:staff_team_member_address\",\n \"staff_team_member_comment\": \"staff:staff_team_member_comment\",\n \"staff_team_member_job_history\": \"staff:staff_team_member_job_history\",\n \"staff_team_role\": \"staff:staff_team_role\"\n }\n} as const\nexport type KnownModuleId = keyof typeof M\nexport type KnownEntities = typeof E\n"],
5
+ "mappings": "AACO,MAAM,IAAI;AAAA,EACf,cAAc;AAAA,EACd,QAAQ;AAAA,EACR,aAAa;AAAA,EACb,aAAa;AAAA,EACb,gBAAgB;AAAA,EAChB,YAAY;AAAA,EACZ,WAAW;AAAA,EACX,eAAe;AAAA,EACf,cAAc;AAAA,EACd,eAAe;AAAA,EACf,WAAW;AAAA,EACX,SAAS;AAAA,EACT,YAAY;AAAA,EACZ,gBAAgB;AAAA,EAChB,YAAY;AAAA,EACZ,kBAAkB;AAAA,EAClB,mBAAmB;AAAA,EACnB,aAAa;AAAA,EACb,cAAc;AAAA,EACd,WAAW;AAAA,EACX,aAAa;AAAA,EACb,SAAS;AACX;AACO,MAAM,IAAI;AAAA,EACf,cAAc;AAAA,IACZ,oBAAoB;AAAA,IACpB,0BAA0B;AAAA,IAC1B,0BAA0B;AAAA,EAC5B;A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WAAW;AAAA,IACT,6BAA6B;AAAA,IAC7B,iCAAiC;AAAA,EACnC;AAAA,EACA,aAAa;AAAA,IACX,sBAAsB;AAAA,IACtB,+BAA+B;AAAA,IAC/B,8BAA8B;AAAA,IAC9B,0BAA0B;AAAA,IAC1B,qCAAqC;AAAA,IACrC,2BAA2B;AAAA,EAC7B;AAAA,EACA,SAAS;AAAA,IACP,uBAAuB;AAAA,IACvB,cAAc;AAAA,IACd,qBAAqB;AAAA,IACrB,8BAA8B;AAAA,IAC9B,6BAA6B;AAAA,IAC7B,6BAA6B;AAAA,IAC7B,iCAAiC;AAAA,IACjC,mBAAmB;AAAA,EACrB;AACF;",
6
6
  "names": []
7
7
  }
@@ -114,7 +114,6 @@ import * as user_sidebar_preference from "./entities/user_sidebar_preference/ind
114
114
  import * as user_task from "./entities/user_task/index.js";
115
115
  import * as workflow_definition from "./entities/workflow_definition/index.js";
116
116
  import * as workflow_event from "./entities/workflow_event/index.js";
117
- import * as workflow_event_trigger from "./entities/workflow_event_trigger/index.js";
118
117
  import * as workflow_instance from "./entities/workflow_instance/index.js";
119
118
  const entityFieldsRegistry = {
120
119
  access_log,
@@ -233,7 +232,6 @@ const entityFieldsRegistry = {
233
232
  user_task,
234
233
  workflow_definition,
235
234
  workflow_event,
236
- workflow_event_trigger,
237
235
  workflow_instance
238
236
  };
239
237
  function getEntityFields(slug) {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../generated/entity-fields-registry.ts"],
4
- "sourcesContent": ["// AUTO-GENERATED by mercato generate entity-ids\n// Static registry for entity fields - eliminates dynamic imports for Turbopack compatibility\nimport * as access_log from './entities/access_log/index'\nimport * as action_log from './entities/action_log/index'\nimport * as api_key from './entities/api_key/index'\nimport * as attachment from './entities/attachment/index'\nimport * as attachment_partition from './entities/attachment_partition/index'\nimport * as business_rule from './entities/business_rule/index'\nimport * as catalog_offer from './entities/catalog_offer/index'\nimport * as catalog_option_schema_template from './entities/catalog_option_schema_template/index'\nimport * as catalog_price_kind from './entities/catalog_price_kind/index'\nimport * as catalog_product from './entities/catalog_product/index'\nimport * as catalog_product_category from './entities/catalog_product_category/index'\nimport * as catalog_product_category_assignment from './entities/catalog_product_category_assignment/index'\nimport * as catalog_product_price from './entities/catalog_product_price/index'\nimport * as catalog_product_tag from './entities/catalog_product_tag/index'\nimport * as catalog_product_tag_assignment from './entities/catalog_product_tag_assignment/index'\nimport * as catalog_product_variant from './entities/catalog_product_variant/index'\nimport * as catalog_product_variant_relation from './entities/catalog_product_variant_relation/index'\nimport * as currency from './entities/currency/index'\nimport * as currency_fetch_config from './entities/currency_fetch_config/index'\nimport * as custom_entity from './entities/custom_entity/index'\nimport * as custom_entity_storage from './entities/custom_entity_storage/index'\nimport * as custom_field_def from './entities/custom_field_def/index'\nimport * as custom_field_entity_config from './entities/custom_field_entity_config/index'\nimport * as custom_field_value from './entities/custom_field_value/index'\nimport * as customer_activity from './entities/customer_activity/index'\nimport * as customer_address from './entities/customer_address/index'\nimport * as customer_comment from './entities/customer_comment/index'\nimport * as customer_company_profile from './entities/customer_company_profile/index'\nimport * as customer_deal from './entities/customer_deal/index'\nimport * as customer_deal_company_link from './entities/customer_deal_company_link/index'\nimport * as customer_deal_person_link from './entities/customer_deal_person_link/index'\nimport * as customer_dictionary_entry from './entities/customer_dictionary_entry/index'\nimport * as customer_entity from './entities/customer_entity/index'\nimport * as customer_person_profile from './entities/customer_person_profile/index'\nimport * as customer_settings from './entities/customer_settings/index'\nimport * as customer_tag from './entities/customer_tag/index'\nimport * as customer_tag_assignment from './entities/customer_tag_assignment/index'\nimport * as customer_todo_link from './entities/customer_todo_link/index'\nimport * as dashboard_layout from './entities/dashboard_layout/index'\nimport * as dashboard_role_widgets from './entities/dashboard_role_widgets/index'\nimport * as dashboard_user_widgets from './entities/dashboard_user_widgets/index'\nimport * as dictionary from './entities/dictionary/index'\nimport * as dictionary_entry from './entities/dictionary_entry/index'\nimport * as encryption_map from './entities/encryption_map/index'\nimport * as entity_index_coverage from './entities/entity_index_coverage/index'\nimport * as entity_index_job from './entities/entity_index_job/index'\nimport * as entity_index_row from './entities/entity_index_row/index'\nimport * as exchange_rate from './entities/exchange_rate/index'\nimport * as feature_toggle from './entities/feature_toggle/index'\nimport * as feature_toggle_override from './entities/feature_toggle_override/index'\nimport * as indexer_error_log from './entities/indexer_error_log/index'\nimport * as indexer_status_log from './entities/indexer_status_log/index'\nimport * as module_config from './entities/module_config/index'\nimport * as organization from './entities/organization/index'\nimport * as password_reset from './entities/password_reset/index'\nimport * as perspective from './entities/perspective/index'\nimport * as planner_availability_rule from './entities/planner_availability_rule/index'\nimport * as planner_availability_rule_set from './entities/planner_availability_rule_set/index'\nimport * as resources_resource from './entities/resources_resource/index'\nimport * as resources_resource_activity from './entities/resources_resource_activity/index'\nimport * as resources_resource_comment from './entities/resources_resource_comment/index'\nimport * as resources_resource_tag from './entities/resources_resource_tag/index'\nimport * as resources_resource_tag_assignment from './entities/resources_resource_tag_assignment/index'\nimport * as resources_resource_type from './entities/resources_resource_type/index'\nimport * as role from './entities/role/index'\nimport * as role_acl from './entities/role_acl/index'\nimport * as role_perspective from './entities/role_perspective/index'\nimport * as role_sidebar_preference from './entities/role_sidebar_preference/index'\nimport * as rule_execution_log from './entities/rule_execution_log/index'\nimport * as rule_set from './entities/rule_set/index'\nimport * as rule_set_member from './entities/rule_set_member/index'\nimport * as sales_channel from './entities/sales_channel/index'\nimport * as sales_credit_memo from './entities/sales_credit_memo/index'\nimport * as sales_credit_memo_line from './entities/sales_credit_memo_line/index'\nimport * as sales_delivery_window from './entities/sales_delivery_window/index'\nimport * as sales_document_address from './entities/sales_document_address/index'\nimport * as sales_document_sequence from './entities/sales_document_sequence/index'\nimport * as sales_document_tag from './entities/sales_document_tag/index'\nimport * as sales_document_tag_assignment from './entities/sales_document_tag_assignment/index'\nimport * as sales_invoice from './entities/sales_invoice/index'\nimport * as sales_invoice_line from './entities/sales_invoice_line/index'\nimport * as sales_note from './entities/sales_note/index'\nimport * as sales_order from './entities/sales_order/index'\nimport * as sales_order_adjustment from './entities/sales_order_adjustment/index'\nimport * as sales_order_line from './entities/sales_order_line/index'\nimport * as sales_payment from './entities/sales_payment/index'\nimport * as sales_payment_allocation from './entities/sales_payment_allocation/index'\nimport * as sales_payment_method from './entities/sales_payment_method/index'\nimport * as sales_quote from './entities/sales_quote/index'\nimport * as sales_quote_adjustment from './entities/sales_quote_adjustment/index'\nimport * as sales_quote_line from './entities/sales_quote_line/index'\nimport * as sales_settings from './entities/sales_settings/index'\nimport * as sales_shipment from './entities/sales_shipment/index'\nimport * as sales_shipment_item from './entities/sales_shipment_item/index'\nimport * as sales_shipping_method from './entities/sales_shipping_method/index'\nimport * as sales_tax_rate from './entities/sales_tax_rate/index'\nimport * as search_token from './entities/search_token/index'\nimport * as session from './entities/session/index'\nimport * as staff_leave_request from './entities/staff_leave_request/index'\nimport * as staff_team from './entities/staff_team/index'\nimport * as staff_team_member from './entities/staff_team_member/index'\nimport * as staff_team_member_activity from './entities/staff_team_member_activity/index'\nimport * as staff_team_member_address from './entities/staff_team_member_address/index'\nimport * as staff_team_member_comment from './entities/staff_team_member_comment/index'\nimport * as staff_team_member_job_history from './entities/staff_team_member_job_history/index'\nimport * as staff_team_role from './entities/staff_team_role/index'\nimport * as step_instance from './entities/step_instance/index'\nimport * as tenant from './entities/tenant/index'\nimport * as upgrade_action_run from './entities/upgrade_action_run/index'\nimport * as user from './entities/user/index'\nimport * as user_acl from './entities/user_acl/index'\nimport * as user_role from './entities/user_role/index'\nimport * as user_sidebar_preference from './entities/user_sidebar_preference/index'\nimport * as user_task from './entities/user_task/index'\nimport * as workflow_definition from './entities/workflow_definition/index'\nimport * as workflow_event from './entities/workflow_event/index'\nimport * as workflow_event_trigger from './entities/workflow_event_trigger/index'\nimport * as workflow_instance from './entities/workflow_instance/index'\n\nexport const entityFieldsRegistry: Record<string, Record<string, string>> = {\n access_log,\n action_log,\n api_key,\n attachment,\n attachment_partition,\n business_rule,\n catalog_offer,\n catalog_option_schema_template,\n catalog_price_kind,\n catalog_product,\n catalog_product_category,\n catalog_product_category_assignment,\n catalog_product_price,\n catalog_product_tag,\n catalog_product_tag_assignment,\n catalog_product_variant,\n catalog_product_variant_relation,\n currency,\n currency_fetch_config,\n custom_entity,\n custom_entity_storage,\n custom_field_def,\n custom_field_entity_config,\n custom_field_value,\n customer_activity,\n customer_address,\n customer_comment,\n customer_company_profile,\n customer_deal,\n customer_deal_company_link,\n customer_deal_person_link,\n customer_dictionary_entry,\n customer_entity,\n customer_person_profile,\n customer_settings,\n customer_tag,\n customer_tag_assignment,\n customer_todo_link,\n dashboard_layout,\n dashboard_role_widgets,\n dashboard_user_widgets,\n dictionary,\n dictionary_entry,\n encryption_map,\n entity_index_coverage,\n entity_index_job,\n entity_index_row,\n exchange_rate,\n feature_toggle,\n feature_toggle_override,\n indexer_error_log,\n indexer_status_log,\n module_config,\n organization,\n password_reset,\n perspective,\n planner_availability_rule,\n planner_availability_rule_set,\n resources_resource,\n resources_resource_activity,\n resources_resource_comment,\n resources_resource_tag,\n resources_resource_tag_assignment,\n resources_resource_type,\n role,\n role_acl,\n role_perspective,\n role_sidebar_preference,\n rule_execution_log,\n rule_set,\n rule_set_member,\n sales_channel,\n sales_credit_memo,\n sales_credit_memo_line,\n sales_delivery_window,\n sales_document_address,\n sales_document_sequence,\n sales_document_tag,\n sales_document_tag_assignment,\n sales_invoice,\n sales_invoice_line,\n sales_note,\n sales_order,\n sales_order_adjustment,\n sales_order_line,\n sales_payment,\n sales_payment_allocation,\n sales_payment_method,\n sales_quote,\n sales_quote_adjustment,\n sales_quote_line,\n sales_settings,\n sales_shipment,\n sales_shipment_item,\n sales_shipping_method,\n sales_tax_rate,\n search_token,\n session,\n staff_leave_request,\n staff_team,\n staff_team_member,\n staff_team_member_activity,\n staff_team_member_address,\n staff_team_member_comment,\n staff_team_member_job_history,\n staff_team_role,\n step_instance,\n tenant,\n upgrade_action_run,\n user,\n user_acl,\n user_role,\n user_sidebar_preference,\n user_task,\n workflow_definition,\n workflow_event,\n workflow_event_trigger,\n workflow_instance\n}\n\nexport function getEntityFields(slug: string): Record<string, string> | undefined {\n return entityFieldsRegistry[slug]\n}\n"],
5
- "mappings": "AAEA,YAAY,gBAAgB;AAC5B,YAAY,gBAAgB;AAC5B,YAAY,aAAa;AACzB,YAAY,gBAAgB;AAC5B,YAAY,0BAA0B;AACtC,YAAY,mBAAmB;AAC/B,YAAY,mBAAmB;AAC/B,YAAY,oCAAoC;AAChD,YAAY,wBAAwB;AACpC,YAAY,qBAAqB;AACjC,YAAY,8BAA8B;AAC1C,YAAY,yCAAyC;AACrD,YAAY,2BAA2B;AACvC,YAAY,yBAAyB;AACrC,YAAY,oCAAoC;AAChD,YAAY,6BAA6B;AACzC,YAAY,sCAAsC;AAClD,YAAY,cAAc;AAC1B,YAAY,2BAA2B;AACvC,YAAY,mBAAmB;AAC/B,YAAY,2BAA2B;AACvC,YAAY,sBAAsB;AAClC,YAAY,gCAAgC;AAC5C,YAAY,wBAAwB;AACpC,YAAY,uBAAuB;AACnC,YAAY,sBAAsB;AAClC,YAAY,sBAAsB;AAClC,YAAY,8BAA8B;AAC1C,YAAY,mBAAmB;AAC/B,YAAY,gCAAgC;AAC5C,YAAY,+BAA+B;AAC3C,YAAY,+BAA+B;AAC3C,YAAY,qBAAqB;AACjC,YAAY,6BAA6B;AACzC,YAAY,uBAAuB;AACnC,YAAY,kBAAkB;AAC9B,YAAY,6BAA6B;AACzC,YAAY,wBAAwB;AACpC,YAAY,sBAAsB;AAClC,YAAY,4BAA4B;AACxC,YAAY,4BAA4B;AACxC,YAAY,gBAAgB;AAC5B,YAAY,sBAAsB;AAClC,YAAY,oBAAoB;AAChC,YAAY,2BAA2B;AACvC,YAAY,sBAAsB;AAClC,YAAY,sBAAsB;AAClC,YAAY,mBAAmB;AAC/B,YAAY,oBAAoB;AAChC,YAAY,6BAA6B;AACzC,YAAY,uBAAuB;AACnC,YAAY,wBAAwB;AACpC,YAA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3B,YAAY,6BAA6B;AACzC,YAAY,eAAe;AAC3B,YAAY,yBAAyB;AACrC,YAAY,oBAAoB;AAChC,YAAY,4BAA4B;AACxC,YAAY,uBAAuB;AAE5B,MAAM,uBAA+D;AAAA,EAC1E;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,SAAS,gBAAgB,MAAkD;AAChF,SAAO,qBAAqB,IAAI;AAClC;",
4
+ "sourcesContent": ["// AUTO-GENERATED by mercato generate entity-ids\n// Static registry for entity fields - eliminates dynamic imports for Turbopack compatibility\nimport * as access_log from './entities/access_log/index'\nimport * as action_log from './entities/action_log/index'\nimport * as api_key from './entities/api_key/index'\nimport * as attachment from './entities/attachment/index'\nimport * as attachment_partition from './entities/attachment_partition/index'\nimport * as business_rule from './entities/business_rule/index'\nimport * as catalog_offer from './entities/catalog_offer/index'\nimport * as catalog_option_schema_template from './entities/catalog_option_schema_template/index'\nimport * as catalog_price_kind from './entities/catalog_price_kind/index'\nimport * as catalog_product from './entities/catalog_product/index'\nimport * as catalog_product_category from './entities/catalog_product_category/index'\nimport * as catalog_product_category_assignment from './entities/catalog_product_category_assignment/index'\nimport * as catalog_product_price from './entities/catalog_product_price/index'\nimport * as catalog_product_tag from './entities/catalog_product_tag/index'\nimport * as catalog_product_tag_assignment from './entities/catalog_product_tag_assignment/index'\nimport * as catalog_product_variant from './entities/catalog_product_variant/index'\nimport * as catalog_product_variant_relation from './entities/catalog_product_variant_relation/index'\nimport * as currency from './entities/currency/index'\nimport * as currency_fetch_config from './entities/currency_fetch_config/index'\nimport * as custom_entity from './entities/custom_entity/index'\nimport * as custom_entity_storage from './entities/custom_entity_storage/index'\nimport * as custom_field_def from './entities/custom_field_def/index'\nimport * as custom_field_entity_config from './entities/custom_field_entity_config/index'\nimport * as custom_field_value from './entities/custom_field_value/index'\nimport * as customer_activity from './entities/customer_activity/index'\nimport * as customer_address from './entities/customer_address/index'\nimport * as customer_comment from './entities/customer_comment/index'\nimport * as customer_company_profile from './entities/customer_company_profile/index'\nimport * as customer_deal from './entities/customer_deal/index'\nimport * as customer_deal_company_link from './entities/customer_deal_company_link/index'\nimport * as customer_deal_person_link from './entities/customer_deal_person_link/index'\nimport * as customer_dictionary_entry from './entities/customer_dictionary_entry/index'\nimport * as customer_entity from './entities/customer_entity/index'\nimport * as customer_person_profile from './entities/customer_person_profile/index'\nimport * as customer_settings from './entities/customer_settings/index'\nimport * as customer_tag from './entities/customer_tag/index'\nimport * as customer_tag_assignment from './entities/customer_tag_assignment/index'\nimport * as customer_todo_link from './entities/customer_todo_link/index'\nimport * as dashboard_layout from './entities/dashboard_layout/index'\nimport * as dashboard_role_widgets from './entities/dashboard_role_widgets/index'\nimport * as dashboard_user_widgets from './entities/dashboard_user_widgets/index'\nimport * as dictionary from './entities/dictionary/index'\nimport * as dictionary_entry from './entities/dictionary_entry/index'\nimport * as encryption_map from './entities/encryption_map/index'\nimport * as entity_index_coverage from './entities/entity_index_coverage/index'\nimport * as entity_index_job from './entities/entity_index_job/index'\nimport * as entity_index_row from './entities/entity_index_row/index'\nimport * as exchange_rate from './entities/exchange_rate/index'\nimport * as feature_toggle from './entities/feature_toggle/index'\nimport * as feature_toggle_override from './entities/feature_toggle_override/index'\nimport * as indexer_error_log from './entities/indexer_error_log/index'\nimport * as indexer_status_log from './entities/indexer_status_log/index'\nimport * as module_config from './entities/module_config/index'\nimport * as organization from './entities/organization/index'\nimport * as password_reset from './entities/password_reset/index'\nimport * as perspective from './entities/perspective/index'\nimport * as planner_availability_rule from './entities/planner_availability_rule/index'\nimport * as planner_availability_rule_set from './entities/planner_availability_rule_set/index'\nimport * as resources_resource from './entities/resources_resource/index'\nimport * as resources_resource_activity from './entities/resources_resource_activity/index'\nimport * as resources_resource_comment from './entities/resources_resource_comment/index'\nimport * as resources_resource_tag from './entities/resources_resource_tag/index'\nimport * as resources_resource_tag_assignment from './entities/resources_resource_tag_assignment/index'\nimport * as resources_resource_type from './entities/resources_resource_type/index'\nimport * as role from './entities/role/index'\nimport * as role_acl from './entities/role_acl/index'\nimport * as role_perspective from './entities/role_perspective/index'\nimport * as role_sidebar_preference from './entities/role_sidebar_preference/index'\nimport * as rule_execution_log from './entities/rule_execution_log/index'\nimport * as rule_set from './entities/rule_set/index'\nimport * as rule_set_member from './entities/rule_set_member/index'\nimport * as sales_channel from './entities/sales_channel/index'\nimport * as sales_credit_memo from './entities/sales_credit_memo/index'\nimport * as sales_credit_memo_line from './entities/sales_credit_memo_line/index'\nimport * as sales_delivery_window from './entities/sales_delivery_window/index'\nimport * as sales_document_address from './entities/sales_document_address/index'\nimport * as sales_document_sequence from './entities/sales_document_sequence/index'\nimport * as sales_document_tag from './entities/sales_document_tag/index'\nimport * as sales_document_tag_assignment from './entities/sales_document_tag_assignment/index'\nimport * as sales_invoice from './entities/sales_invoice/index'\nimport * as sales_invoice_line from './entities/sales_invoice_line/index'\nimport * as sales_note from './entities/sales_note/index'\nimport * as sales_order from './entities/sales_order/index'\nimport * as sales_order_adjustment from './entities/sales_order_adjustment/index'\nimport * as sales_order_line from './entities/sales_order_line/index'\nimport * as sales_payment from './entities/sales_payment/index'\nimport * as sales_payment_allocation from './entities/sales_payment_allocation/index'\nimport * as sales_payment_method from './entities/sales_payment_method/index'\nimport * as sales_quote from './entities/sales_quote/index'\nimport * as sales_quote_adjustment from './entities/sales_quote_adjustment/index'\nimport * as sales_quote_line from './entities/sales_quote_line/index'\nimport * as sales_settings from './entities/sales_settings/index'\nimport * as sales_shipment from './entities/sales_shipment/index'\nimport * as sales_shipment_item from './entities/sales_shipment_item/index'\nimport * as sales_shipping_method from './entities/sales_shipping_method/index'\nimport * as sales_tax_rate from './entities/sales_tax_rate/index'\nimport * as search_token from './entities/search_token/index'\nimport * as session from './entities/session/index'\nimport * as staff_leave_request from './entities/staff_leave_request/index'\nimport * as staff_team from './entities/staff_team/index'\nimport * as staff_team_member from './entities/staff_team_member/index'\nimport * as staff_team_member_activity from './entities/staff_team_member_activity/index'\nimport * as staff_team_member_address from './entities/staff_team_member_address/index'\nimport * as staff_team_member_comment from './entities/staff_team_member_comment/index'\nimport * as staff_team_member_job_history from './entities/staff_team_member_job_history/index'\nimport * as staff_team_role from './entities/staff_team_role/index'\nimport * as step_instance from './entities/step_instance/index'\nimport * as tenant from './entities/tenant/index'\nimport * as upgrade_action_run from './entities/upgrade_action_run/index'\nimport * as user from './entities/user/index'\nimport * as user_acl from './entities/user_acl/index'\nimport * as user_role from './entities/user_role/index'\nimport * as user_sidebar_preference from './entities/user_sidebar_preference/index'\nimport * as user_task from './entities/user_task/index'\nimport * as workflow_definition from './entities/workflow_definition/index'\nimport * as workflow_event from './entities/workflow_event/index'\nimport * as workflow_instance from './entities/workflow_instance/index'\n\nexport const entityFieldsRegistry: Record<string, Record<string, string>> = {\n access_log,\n action_log,\n api_key,\n attachment,\n attachment_partition,\n business_rule,\n catalog_offer,\n catalog_option_schema_template,\n catalog_price_kind,\n catalog_product,\n catalog_product_category,\n catalog_product_category_assignment,\n catalog_product_price,\n catalog_product_tag,\n catalog_product_tag_assignment,\n catalog_product_variant,\n catalog_product_variant_relation,\n currency,\n currency_fetch_config,\n custom_entity,\n custom_entity_storage,\n custom_field_def,\n custom_field_entity_config,\n custom_field_value,\n customer_activity,\n customer_address,\n customer_comment,\n customer_company_profile,\n customer_deal,\n customer_deal_company_link,\n customer_deal_person_link,\n customer_dictionary_entry,\n customer_entity,\n customer_person_profile,\n customer_settings,\n customer_tag,\n customer_tag_assignment,\n customer_todo_link,\n dashboard_layout,\n dashboard_role_widgets,\n dashboard_user_widgets,\n dictionary,\n dictionary_entry,\n encryption_map,\n entity_index_coverage,\n entity_index_job,\n entity_index_row,\n exchange_rate,\n feature_toggle,\n feature_toggle_override,\n indexer_error_log,\n indexer_status_log,\n module_config,\n organization,\n password_reset,\n perspective,\n planner_availability_rule,\n planner_availability_rule_set,\n resources_resource,\n resources_resource_activity,\n resources_resource_comment,\n resources_resource_tag,\n resources_resource_tag_assignment,\n resources_resource_type,\n role,\n role_acl,\n role_perspective,\n role_sidebar_preference,\n rule_execution_log,\n rule_set,\n rule_set_member,\n sales_channel,\n sales_credit_memo,\n sales_credit_memo_line,\n sales_delivery_window,\n sales_document_address,\n sales_document_sequence,\n sales_document_tag,\n sales_document_tag_assignment,\n sales_invoice,\n sales_invoice_line,\n sales_note,\n sales_order,\n sales_order_adjustment,\n sales_order_line,\n sales_payment,\n sales_payment_allocation,\n sales_payment_method,\n sales_quote,\n sales_quote_adjustment,\n sales_quote_line,\n sales_settings,\n sales_shipment,\n sales_shipment_item,\n sales_shipping_method,\n sales_tax_rate,\n search_token,\n session,\n staff_leave_request,\n staff_team,\n staff_team_member,\n staff_team_member_activity,\n staff_team_member_address,\n staff_team_member_comment,\n staff_team_member_job_history,\n staff_team_role,\n step_instance,\n tenant,\n upgrade_action_run,\n user,\n user_acl,\n user_role,\n user_sidebar_preference,\n user_task,\n workflow_definition,\n workflow_event,\n workflow_instance\n}\n\nexport function getEntityFields(slug: string): Record<string, string> | undefined {\n return entityFieldsRegistry[slug]\n}\n"],
5
+ "mappings": "AAEA,YAAY,gBAAgB;AAC5B,YAAY,gBAAgB;AAC5B,YAAY,aAAa;AACzB,YAAY,gBAAgB;AAC5B,YAAY,0BAA0B;AACtC,YAAY,mBAAmB;AAC/B,YAAY,mBAAmB;AAC/B,YAAY,oCAAoC;AAChD,YAAY,wBAAwB;AACpC,YAAY,qBAAqB;AACjC,YAAY,8BAA8B;AAC1C,YAAY,yCAAyC;AACrD,YAAY,2BAA2B;AACvC,YAAY,yBAAyB;AACrC,YAAY,oCAAoC;AAChD,YAAY,6BAA6B;AACzC,YAAY,sCAAsC;AAClD,YAAY,cAAc;AAC1B,YAAY,2BAA2B;AACvC,YAAY,mBAAmB;AAC/B,YAAY,2BAA2B;AACvC,YAAY,sBAAsB;AAClC,YAAY,gCAAgC;AAC5C,YAAY,wBAAwB;AACpC,YAAY,uBAAuB;AACnC,YAAY,sBAAsB;AAClC,YAAY,sBAAsB;AAClC,YAAY,8BAA8B;AA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EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEO,SAAS,gBAAgB,MAAkD;AAChF,SAAO,qBAAqB,IAAI;AAClC;",
6
6
  "names": []
7
7
  }
@@ -191,38 +191,6 @@ const ruleDiscoveryOptionsSchema = z.object({
191
191
  organizationId: z.uuid("organizationId must be a valid UUID"),
192
192
  ruleType: ruleTypeSchema.optional()
193
193
  });
194
- const directRuleExecutionContextSchema = z.object({
195
- ruleId: z.uuid("ruleId must be a valid UUID"),
196
- data: z.any(),
197
- user: z.looseObject({
198
- id: z.string().optional(),
199
- email: z.string().optional(),
200
- role: z.string().optional()
201
- }).optional(),
202
- tenantId: z.uuid("tenantId must be a valid UUID"),
203
- organizationId: z.uuid("organizationId must be a valid UUID"),
204
- executedBy: z.string().optional(),
205
- dryRun: z.boolean().optional(),
206
- entityType: z.string().optional(),
207
- entityId: z.string().optional(),
208
- eventType: z.string().optional()
209
- });
210
- const ruleIdExecutionContextSchema = z.object({
211
- ruleId: z.string().min(1, "ruleId must be a non-empty string").max(50),
212
- data: z.any(),
213
- user: z.looseObject({
214
- id: z.string().optional(),
215
- email: z.string().optional(),
216
- role: z.string().optional()
217
- }).optional(),
218
- tenantId: z.uuid("tenantId must be a valid UUID"),
219
- organizationId: z.uuid("organizationId must be a valid UUID"),
220
- executedBy: z.string().optional(),
221
- dryRun: z.boolean().optional(),
222
- entityType: z.string().optional(),
223
- entityId: z.string().optional(),
224
- eventType: z.string().optional()
225
- });
226
194
  export {
227
195
  actionSchema,
228
196
  actionTriggerSchema,
@@ -236,13 +204,11 @@ export {
236
204
  createRuleSetMemberSchema,
237
205
  createRuleSetSchema,
238
206
  dataTypeSchema,
239
- directRuleExecutionContextSchema,
240
207
  executionResultSchema,
241
208
  logicalOperatorSchema,
242
209
  ruleDiscoveryOptionsSchema,
243
210
  ruleEngineContextSchema,
244
211
  ruleExecutionLogFilterSchema,
245
- ruleIdExecutionContextSchema,
246
212
  ruleSetFilterSchema,
247
213
  ruleSetMemberFilterSchema,
248
214
  ruleTypeSchema,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/modules/business_rules/data/validators.ts"],
4
- "sourcesContent": ["import { z } from 'zod'\nimport {\n validateConditionExpressionForApi,\n validateActionsForApi,\n isSafeExpression,\n} from '../lib/payload-validation'\n\n/**\n * Business Rules Module - Zod Validators\n */\n\nconst uuid = z.uuid()\n\n// Rule Types\nexport const ruleTypeSchema = z.enum(['GUARD', 'VALIDATION', 'CALCULATION', 'ACTION', 'ASSIGNMENT'])\nexport type RuleType = z.infer<typeof ruleTypeSchema>\n\n// Condition Types\nexport const conditionTypeSchema = z.enum(['EXPRESSION', 'GROUP'])\nexport type ConditionType = z.infer<typeof conditionTypeSchema>\n\n// Logical Operators\nexport const logicalOperatorSchema = z.enum(['AND', 'OR', 'NOT'])\nexport type LogicalOperator = z.infer<typeof logicalOperatorSchema>\n\n// Comparison Operators\nexport const comparisonOperatorSchema = z.enum([\n '=',\n '==',\n '!=',\n '>',\n '>=',\n '<',\n '<=',\n 'IN',\n 'NOT_IN',\n 'CONTAINS',\n 'NOT_CONTAINS',\n 'STARTS_WITH',\n 'ENDS_WITH',\n 'MATCHES',\n 'IS_EMPTY',\n 'IS_NOT_EMPTY',\n])\nexport type ComparisonOperator = z.infer<typeof comparisonOperatorSchema>\n\n// Data Types\nexport const dataTypeSchema = z.enum(['STRING', 'NUMBER', 'BOOLEAN', 'DATE', 'ARRAY', 'OBJECT'])\nexport type DataType = z.infer<typeof dataTypeSchema>\n\n// Action Trigger\nexport const actionTriggerSchema = z.enum(['ON_SUCCESS', 'ON_FAILURE', 'ALWAYS'])\nexport type ActionTrigger = z.infer<typeof actionTriggerSchema>\n\n// Execution Result\nexport const executionResultSchema = z.enum(['SUCCESS', 'FAILURE', 'ERROR'])\nexport type ExecutionResult = z.infer<typeof executionResultSchema>\n\n// Condition Expression Schema with Validation\n// Uses runtime validation to check structure, nesting, and field paths\nexport const conditionExpressionSchema = z.any()\n .superRefine((val, ctx) => {\n // Null/undefined is allowed (optional field)\n if (val === null || val === undefined) return\n\n // Check for dangerous patterns first (DoS prevention)\n if (!isSafeExpression(val)) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n message: 'Condition expression exceeds safety limits (max depth: 10, max rules per group: 50, max field path length: 200)'\n })\n return\n }\n\n // Validate structure and content\n const result = validateConditionExpressionForApi(val)\n if (!result.valid) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n message: result.error || 'Invalid condition expression'\n })\n }\n })\n\n// Action Schema with Validation\n// Validates action type and required config fields\nexport const actionSchema = z.object({\n type: z.string().min(1),\n config: z.record(z.string(), z.any()).optional(),\n})\n\nexport const actionsArraySchema = z.array(actionSchema).optional().nullable()\n .superRefine((val, ctx) => {\n // Null/undefined/empty is allowed (optional field)\n if (!val || (Array.isArray(val) && val.length === 0)) return\n\n const result = validateActionsForApi(val, 'actions')\n if (!result.valid) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n message: result.error || 'Invalid actions'\n })\n }\n })\n\n// Date preprocessing helper\nconst dateOrNull = z.preprocess((value) => {\n if (value === undefined || value === null || value === '') return null\n const date = value instanceof Date ? value : new Date(String(value))\n return Number.isNaN(date.getTime()) ? null : date\n}, z.date().nullable())\n\n// BusinessRule Create Schema\nexport const createBusinessRuleSchema = z.object({\n ruleId: z.string().min(1).max(50),\n ruleName: z.string().min(1).max(200),\n description: z.string().max(5000).optional().nullable(),\n ruleType: ruleTypeSchema,\n ruleCategory: z.string().max(50).optional().nullable(),\n entityType: z.string().min(1).max(50),\n eventType: z.string().max(50).optional().nullable(),\n conditionExpression: conditionExpressionSchema,\n successActions: actionsArraySchema,\n failureActions: actionsArraySchema,\n enabled: z.boolean().optional().default(true),\n priority: z.number().int().min(0).max(9999).optional().default(100),\n version: z.number().int().min(1).optional().default(1),\n effectiveFrom: dateOrNull.optional(),\n effectiveTo: dateOrNull.optional(),\n tenantId: uuid,\n organizationId: uuid,\n createdBy: z.string().max(50).optional().nullable(),\n})\n\nexport type CreateBusinessRuleInput = z.infer<typeof createBusinessRuleSchema>\n\n// BusinessRule Update Schema\nexport const updateBusinessRuleSchema = createBusinessRuleSchema.partial().extend({\n id: uuid,\n})\n\nexport type UpdateBusinessRuleInput = z.infer<typeof updateBusinessRuleSchema>\n\n// Query/Filter Schema\nexport const businessRuleFilterSchema = z.object({\n ruleId: z.string().optional(),\n ruleName: z.string().optional(),\n ruleType: ruleTypeSchema.optional(),\n ruleCategory: z.string().optional(),\n entityType: z.string().optional(),\n eventType: z.string().optional(),\n enabled: z.boolean().optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n})\n\nexport type BusinessRuleFilter = z.infer<typeof businessRuleFilterSchema>\n\n// RuleExecutionLog Create Schema\nexport const createRuleExecutionLogSchema = z.object({\n ruleId: uuid,\n entityId: uuid,\n entityType: z.string().min(1).max(50),\n executionResult: executionResultSchema,\n inputContext: z.any().optional().nullable(),\n outputContext: z.any().optional().nullable(),\n errorMessage: z.string().optional().nullable(),\n executionTimeMs: z.number().int().min(0),\n executedAt: z.date().optional(),\n tenantId: uuid,\n organizationId: uuid.optional().nullable(),\n executedBy: z.string().max(50).optional().nullable(),\n})\n\nexport type CreateRuleExecutionLogInput = z.infer<typeof createRuleExecutionLogSchema>\n\n// RuleExecutionLog Query/Filter Schema\nexport const ruleExecutionLogFilterSchema = z.object({\n ruleId: uuid.optional(),\n entityId: uuid.optional(),\n entityType: z.string().optional(),\n executionResult: executionResultSchema.optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n executedBy: z.string().optional(),\n executedAtFrom: z.date().optional(),\n executedAtTo: z.date().optional(),\n})\n\nexport type RuleExecutionLogFilter = z.infer<typeof ruleExecutionLogFilterSchema>\n\n// RuleSet Create Schema\nexport const createRuleSetSchema = z.object({\n setId: z.string().min(1).max(50),\n setName: z.string().min(1).max(200),\n description: z.string().max(5000).optional().nullable(),\n enabled: z.boolean().optional().default(true),\n tenantId: uuid,\n organizationId: uuid,\n createdBy: z.string().max(50).optional().nullable(),\n})\n\nexport type CreateRuleSetInput = z.infer<typeof createRuleSetSchema>\n\n// RuleSet Update Schema\nexport const updateRuleSetSchema = createRuleSetSchema.partial().extend({\n id: uuid,\n})\n\nexport type UpdateRuleSetInput = z.infer<typeof updateRuleSetSchema>\n\n// RuleSet Query/Filter Schema\nexport const ruleSetFilterSchema = z.object({\n setId: z.string().optional(),\n setName: z.string().optional(),\n enabled: z.boolean().optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n})\n\nexport type RuleSetFilter = z.infer<typeof ruleSetFilterSchema>\n\n// RuleSetMember Create Schema\nexport const createRuleSetMemberSchema = z.object({\n ruleSetId: uuid,\n ruleId: uuid,\n sequence: z.number().int().min(0).optional().default(0),\n enabled: z.boolean().optional().default(true),\n tenantId: uuid,\n organizationId: uuid,\n})\n\nexport type CreateRuleSetMemberInput = z.infer<typeof createRuleSetMemberSchema>\n\n// RuleSetMember Update Schema\nexport const updateRuleSetMemberSchema = z.object({\n id: uuid,\n sequence: z.number().int().min(0).optional(),\n enabled: z.boolean().optional(),\n})\n\nexport type UpdateRuleSetMemberInput = z.infer<typeof updateRuleSetMemberSchema>\n\n// RuleSetMember Query/Filter Schema\nexport const ruleSetMemberFilterSchema = z.object({\n ruleSetId: uuid.optional(),\n ruleId: uuid.optional(),\n enabled: z.boolean().optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n})\n\nexport type RuleSetMemberFilter = z.infer<typeof ruleSetMemberFilterSchema>\n\n// Rule Engine Context Schema\nexport const ruleEngineContextSchema = z.looseObject({\n entityType: z.string().min(1, 'entityType is required'),\n entityId: z.string().optional(),\n eventType: z.string().optional(),\n data: z.any(),\n user: z.looseObject({\n id: z.string().optional(),\n email: z.string().optional(),\n role: z.string().optional(),\n }).optional(),\n tenant: z.looseObject({\n id: z.string().optional(),\n }).optional(),\n organization: z.looseObject({\n id: z.string().optional(),\n }).optional(),\n tenantId: z.uuid('tenantId must be a valid UUID'),\n organizationId: z.uuid('organizationId must be a valid UUID'),\n executedBy: z.string().optional(),\n dryRun: z.boolean().optional(),\n})\n\nexport type RuleEngineContextInput = z.infer<typeof ruleEngineContextSchema>\n\n// Rule Discovery Options Schema\nexport const ruleDiscoveryOptionsSchema = z.object({\n entityType: z.string().min(1, 'entityType is required'),\n eventType: z.string().optional(),\n tenantId: z.uuid('tenantId must be a valid UUID'),\n organizationId: z.uuid('organizationId must be a valid UUID'),\n ruleType: ruleTypeSchema.optional(),\n})\n\nexport type RuleDiscoveryOptionsInput = z.infer<typeof ruleDiscoveryOptionsSchema>\n\n// Direct Rule Execution Context Schema (for executing a specific rule by ID)\nexport const directRuleExecutionContextSchema = z.object({\n ruleId: z.uuid('ruleId must be a valid UUID'),\n data: z.any(),\n user: z.looseObject({\n id: z.string().optional(),\n email: z.string().optional(),\n role: z.string().optional(),\n }).optional(),\n tenantId: z.uuid('tenantId must be a valid UUID'),\n organizationId: z.uuid('organizationId must be a valid UUID'),\n executedBy: z.string().optional(),\n dryRun: z.boolean().optional(),\n entityType: z.string().optional(),\n entityId: z.string().optional(),\n eventType: z.string().optional(),\n})\n\nexport type DirectRuleExecutionContextInput = z.infer<typeof directRuleExecutionContextSchema>\n\n// Rule ID Execution Context Schema (for executing a specific rule by its string rule_id identifier)\nexport const ruleIdExecutionContextSchema = z.object({\n ruleId: z.string().min(1, 'ruleId must be a non-empty string').max(50),\n data: z.any(),\n user: z.looseObject({\n id: z.string().optional(),\n email: z.string().optional(),\n role: z.string().optional(),\n }).optional(),\n tenantId: z.uuid('tenantId must be a valid UUID'),\n organizationId: z.uuid('organizationId must be a valid UUID'),\n executedBy: z.string().optional(),\n dryRun: z.boolean().optional(),\n entityType: z.string().optional(),\n entityId: z.string().optional(),\n eventType: z.string().optional(),\n})\n\nexport type RuleIdExecutionContextInput = z.infer<typeof ruleIdExecutionContextSchema>\n"],
5
- "mappings": "AAAA,SAAS,SAAS;AAClB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAMP,MAAM,OAAO,EAAE,KAAK;AAGb,MAAM,iBAAiB,EAAE,KAAK,CAAC,SAAS,cAAc,eAAe,UAAU,YAAY,CAAC;AAI5F,MAAM,sBAAsB,EAAE,KAAK,CAAC,cAAc,OAAO,CAAC;AAI1D,MAAM,wBAAwB,EAAE,KAAK,CAAC,OAAO,MAAM,KAAK,CAAC;AAIzD,MAAM,2BAA2B,EAAE,KAAK;AAAA,EAC7C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAIM,MAAM,iBAAiB,EAAE,KAAK,CAAC,UAAU,UAAU,WAAW,QAAQ,SAAS,QAAQ,CAAC;AAIxF,MAAM,sBAAsB,EAAE,KAAK,CAAC,cAA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["import { z } from 'zod'\nimport {\n validateConditionExpressionForApi,\n validateActionsForApi,\n isSafeExpression,\n} from '../lib/payload-validation'\n\n/**\n * Business Rules Module - Zod Validators\n */\n\nconst uuid = z.uuid()\n\n// Rule Types\nexport const ruleTypeSchema = z.enum(['GUARD', 'VALIDATION', 'CALCULATION', 'ACTION', 'ASSIGNMENT'])\nexport type RuleType = z.infer<typeof ruleTypeSchema>\n\n// Condition Types\nexport const conditionTypeSchema = z.enum(['EXPRESSION', 'GROUP'])\nexport type ConditionType = z.infer<typeof conditionTypeSchema>\n\n// Logical Operators\nexport const logicalOperatorSchema = z.enum(['AND', 'OR', 'NOT'])\nexport type LogicalOperator = z.infer<typeof logicalOperatorSchema>\n\n// Comparison Operators\nexport const comparisonOperatorSchema = z.enum([\n '=',\n '==',\n '!=',\n '>',\n '>=',\n '<',\n '<=',\n 'IN',\n 'NOT_IN',\n 'CONTAINS',\n 'NOT_CONTAINS',\n 'STARTS_WITH',\n 'ENDS_WITH',\n 'MATCHES',\n 'IS_EMPTY',\n 'IS_NOT_EMPTY',\n])\nexport type ComparisonOperator = z.infer<typeof comparisonOperatorSchema>\n\n// Data Types\nexport const dataTypeSchema = z.enum(['STRING', 'NUMBER', 'BOOLEAN', 'DATE', 'ARRAY', 'OBJECT'])\nexport type DataType = z.infer<typeof dataTypeSchema>\n\n// Action Trigger\nexport const actionTriggerSchema = z.enum(['ON_SUCCESS', 'ON_FAILURE', 'ALWAYS'])\nexport type ActionTrigger = z.infer<typeof actionTriggerSchema>\n\n// Execution Result\nexport const executionResultSchema = z.enum(['SUCCESS', 'FAILURE', 'ERROR'])\nexport type ExecutionResult = z.infer<typeof executionResultSchema>\n\n// Condition Expression Schema with Validation\n// Uses runtime validation to check structure, nesting, and field paths\nexport const conditionExpressionSchema = z.any()\n .superRefine((val, ctx) => {\n // Null/undefined is allowed (optional field)\n if (val === null || val === undefined) return\n\n // Check for dangerous patterns first (DoS prevention)\n if (!isSafeExpression(val)) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n message: 'Condition expression exceeds safety limits (max depth: 10, max rules per group: 50, max field path length: 200)'\n })\n return\n }\n\n // Validate structure and content\n const result = validateConditionExpressionForApi(val)\n if (!result.valid) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n message: result.error || 'Invalid condition expression'\n })\n }\n })\n\n// Action Schema with Validation\n// Validates action type and required config fields\nexport const actionSchema = z.object({\n type: z.string().min(1),\n config: z.record(z.string(), z.any()).optional(),\n})\n\nexport const actionsArraySchema = z.array(actionSchema).optional().nullable()\n .superRefine((val, ctx) => {\n // Null/undefined/empty is allowed (optional field)\n if (!val || (Array.isArray(val) && val.length === 0)) return\n\n const result = validateActionsForApi(val, 'actions')\n if (!result.valid) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n message: result.error || 'Invalid actions'\n })\n }\n })\n\n// Date preprocessing helper\nconst dateOrNull = z.preprocess((value) => {\n if (value === undefined || value === null || value === '') return null\n const date = value instanceof Date ? value : new Date(String(value))\n return Number.isNaN(date.getTime()) ? null : date\n}, z.date().nullable())\n\n// BusinessRule Create Schema\nexport const createBusinessRuleSchema = z.object({\n ruleId: z.string().min(1).max(50),\n ruleName: z.string().min(1).max(200),\n description: z.string().max(5000).optional().nullable(),\n ruleType: ruleTypeSchema,\n ruleCategory: z.string().max(50).optional().nullable(),\n entityType: z.string().min(1).max(50),\n eventType: z.string().max(50).optional().nullable(),\n conditionExpression: conditionExpressionSchema,\n successActions: actionsArraySchema,\n failureActions: actionsArraySchema,\n enabled: z.boolean().optional().default(true),\n priority: z.number().int().min(0).max(9999).optional().default(100),\n version: z.number().int().min(1).optional().default(1),\n effectiveFrom: dateOrNull.optional(),\n effectiveTo: dateOrNull.optional(),\n tenantId: uuid,\n organizationId: uuid,\n createdBy: z.string().max(50).optional().nullable(),\n})\n\nexport type CreateBusinessRuleInput = z.infer<typeof createBusinessRuleSchema>\n\n// BusinessRule Update Schema\nexport const updateBusinessRuleSchema = createBusinessRuleSchema.partial().extend({\n id: uuid,\n})\n\nexport type UpdateBusinessRuleInput = z.infer<typeof updateBusinessRuleSchema>\n\n// Query/Filter Schema\nexport const businessRuleFilterSchema = z.object({\n ruleId: z.string().optional(),\n ruleName: z.string().optional(),\n ruleType: ruleTypeSchema.optional(),\n ruleCategory: z.string().optional(),\n entityType: z.string().optional(),\n eventType: z.string().optional(),\n enabled: z.boolean().optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n})\n\nexport type BusinessRuleFilter = z.infer<typeof businessRuleFilterSchema>\n\n// RuleExecutionLog Create Schema\nexport const createRuleExecutionLogSchema = z.object({\n ruleId: uuid,\n entityId: uuid,\n entityType: z.string().min(1).max(50),\n executionResult: executionResultSchema,\n inputContext: z.any().optional().nullable(),\n outputContext: z.any().optional().nullable(),\n errorMessage: z.string().optional().nullable(),\n executionTimeMs: z.number().int().min(0),\n executedAt: z.date().optional(),\n tenantId: uuid,\n organizationId: uuid.optional().nullable(),\n executedBy: z.string().max(50).optional().nullable(),\n})\n\nexport type CreateRuleExecutionLogInput = z.infer<typeof createRuleExecutionLogSchema>\n\n// RuleExecutionLog Query/Filter Schema\nexport const ruleExecutionLogFilterSchema = z.object({\n ruleId: uuid.optional(),\n entityId: uuid.optional(),\n entityType: z.string().optional(),\n executionResult: executionResultSchema.optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n executedBy: z.string().optional(),\n executedAtFrom: z.date().optional(),\n executedAtTo: z.date().optional(),\n})\n\nexport type RuleExecutionLogFilter = z.infer<typeof ruleExecutionLogFilterSchema>\n\n// RuleSet Create Schema\nexport const createRuleSetSchema = z.object({\n setId: z.string().min(1).max(50),\n setName: z.string().min(1).max(200),\n description: z.string().max(5000).optional().nullable(),\n enabled: z.boolean().optional().default(true),\n tenantId: uuid,\n organizationId: uuid,\n createdBy: z.string().max(50).optional().nullable(),\n})\n\nexport type CreateRuleSetInput = z.infer<typeof createRuleSetSchema>\n\n// RuleSet Update Schema\nexport const updateRuleSetSchema = createRuleSetSchema.partial().extend({\n id: uuid,\n})\n\nexport type UpdateRuleSetInput = z.infer<typeof updateRuleSetSchema>\n\n// RuleSet Query/Filter Schema\nexport const ruleSetFilterSchema = z.object({\n setId: z.string().optional(),\n setName: z.string().optional(),\n enabled: z.boolean().optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n})\n\nexport type RuleSetFilter = z.infer<typeof ruleSetFilterSchema>\n\n// RuleSetMember Create Schema\nexport const createRuleSetMemberSchema = z.object({\n ruleSetId: uuid,\n ruleId: uuid,\n sequence: z.number().int().min(0).optional().default(0),\n enabled: z.boolean().optional().default(true),\n tenantId: uuid,\n organizationId: uuid,\n})\n\nexport type CreateRuleSetMemberInput = z.infer<typeof createRuleSetMemberSchema>\n\n// RuleSetMember Update Schema\nexport const updateRuleSetMemberSchema = z.object({\n id: uuid,\n sequence: z.number().int().min(0).optional(),\n enabled: z.boolean().optional(),\n})\n\nexport type UpdateRuleSetMemberInput = z.infer<typeof updateRuleSetMemberSchema>\n\n// RuleSetMember Query/Filter Schema\nexport const ruleSetMemberFilterSchema = z.object({\n ruleSetId: uuid.optional(),\n ruleId: uuid.optional(),\n enabled: z.boolean().optional(),\n tenantId: uuid.optional(),\n organizationId: uuid.optional(),\n})\n\nexport type RuleSetMemberFilter = z.infer<typeof ruleSetMemberFilterSchema>\n\n// Rule Engine Context Schema\nexport const ruleEngineContextSchema = z.looseObject({\n entityType: z.string().min(1, 'entityType is required'),\n entityId: z.string().optional(),\n eventType: z.string().optional(),\n data: z.any(),\n user: z.looseObject({\n id: z.string().optional(),\n email: z.string().optional(),\n role: z.string().optional(),\n }).optional(),\n tenant: z.looseObject({\n id: z.string().optional(),\n }).optional(),\n organization: z.looseObject({\n id: z.string().optional(),\n }).optional(),\n tenantId: z.uuid('tenantId must be a valid UUID'),\n organizationId: z.uuid('organizationId must be a valid UUID'),\n executedBy: z.string().optional(),\n dryRun: z.boolean().optional(),\n})\n\nexport type RuleEngineContextInput = z.infer<typeof ruleEngineContextSchema>\n\n// Rule Discovery Options Schema\nexport const ruleDiscoveryOptionsSchema = z.object({\n entityType: z.string().min(1, 'entityType is required'),\n eventType: z.string().optional(),\n tenantId: z.uuid('tenantId must be a valid UUID'),\n organizationId: z.uuid('organizationId must be a valid UUID'),\n ruleType: ruleTypeSchema.optional(),\n})\n\nexport type RuleDiscoveryOptionsInput = z.infer<typeof ruleDiscoveryOptionsSchema>\n"],
5
+ "mappings": "AAAA,SAAS,SAAS;AAClB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAMP,MAAM,OAAO,EAAE,KAAK;AAGb,MAAM,iBAAiB,EAAE,KAAK,CAAC,SAAS,cAAc,eAAe,UAAU,YAAY,CAAC;AAI5F,MAAM,sBAAsB,EAAE,KAAK,CAAC,cAAc,OAAO,CAAC;AAI1D,MAAM,wBAAwB,EAAE,KAAK,CAAC,OAAO,MAAM,KAAK,CAAC;AAIzD,MAAM,2BAA2B,EAAE,KAAK;AAAA,EAC7C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAIM,MAAM,iBAAiB,EAAE,KAAK,CAAC,UAAU,UAAU,WAAW,QAAQ,SAAS,QAAQ,CAAC;AAIxF,MAAM,sBAAsB,EAAE,KAAK,CAAC,cAAc,cAAc,QAAQ,CAAC;AAIzE,MAAM,wBAAwB,EAAE,KAAK,CAAC,WAAW,WAAW,OAAO,CAAC;AAKpE,MAAM,4BAA4B,EAAE,IAAI,EAC5C,YAAY,CAAC,KAAK,QAAQ;AAEzB,MAAI,QAAQ,QAAQ,QAAQ,OAAW;AAGvC,MAAI,CAAC,iBAAiB,GAAG,GAAG;AAC1B,QAAI,SAAS;AAAA,MACX,MAAM,EAAE,aAAa;AAAA,MACrB,SAAS;AAAA,IACX,CAA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B,WAAW,EAAE,OAAO,EAAE,SAAS;AAAA,EAC/B,MAAM,EAAE,IAAI;AAAA,EACZ,MAAM,EAAE,YAAY;AAAA,IAClB,IAAI,EAAE,OAAO,EAAE,SAAS;AAAA,IACxB,OAAO,EAAE,OAAO,EAAE,SAAS;AAAA,IAC3B,MAAM,EAAE,OAAO,EAAE,SAAS;AAAA,EAC5B,CAAC,EAAE,SAAS;AAAA,EACZ,QAAQ,EAAE,YAAY;AAAA,IACpB,IAAI,EAAE,OAAO,EAAE,SAAS;AAAA,EAC1B,CAAC,EAAE,SAAS;AAAA,EACZ,cAAc,EAAE,YAAY;AAAA,IAC1B,IAAI,EAAE,OAAO,EAAE,SAAS;AAAA,EAC1B,CAAC,EAAE,SAAS;AAAA,EACZ,UAAU,EAAE,KAAK,+BAA+B;AAAA,EAChD,gBAAgB,EAAE,KAAK,qCAAqC;AAAA,EAC5D,YAAY,EAAE,OAAO,EAAE,SAAS;AAAA,EAChC,QAAQ,EAAE,QAAQ,EAAE,SAAS;AAC/B,CAAC;AAKM,MAAM,6BAA6B,EAAE,OAAO;AAAA,EACjD,YAAY,EAAE,OAAO,EAAE,IAAI,GAAG,wBAAwB;AAAA,EACtD,WAAW,EAAE,OAAO,EAAE,SAAS;AAAA,EAC/B,UAAU,EAAE,KAAK,+BAA+B;AAAA,EAChD,gBAAgB,EAAE,KAAK,qCAAqC;AAAA,EAC5D,UAAU,eAAe,SAAS;AACpC,CAAC;",
6
6
  "names": []
7
7
  }
@@ -6,27 +6,7 @@ const metadata = {
6
6
  author: "Patryk Lewczuk",
7
7
  license: "Proprietary"
8
8
  };
9
- import {
10
- executeRules,
11
- executeRuleById,
12
- executeRuleByRuleId,
13
- executeSingleRule,
14
- findApplicableRules,
15
- logRuleExecution
16
- } from "./lib/rule-engine.js";
17
- import {
18
- directRuleExecutionContextSchema,
19
- ruleIdExecutionContextSchema
20
- } from "./data/validators.js";
21
9
  export {
22
- directRuleExecutionContextSchema,
23
- executeRuleById,
24
- executeRuleByRuleId,
25
- executeRules,
26
- executeSingleRule,
27
- findApplicableRules,
28
- logRuleExecution,
29
- metadata,
30
- ruleIdExecutionContextSchema
10
+ metadata
31
11
  };
32
12
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/modules/business_rules/index.ts"],
4
- "sourcesContent": ["import type { ModuleInfo } from '@open-mercato/shared/modules/registry'\n\nexport const metadata: ModuleInfo = {\n name: 'business_rules',\n title: 'Business Rules',\n version: '0.1.0',\n description: 'Business Rules Engine for defining, managing, and executing business logic and automation rules.',\n author: 'Patryk Lewczuk',\n license: 'Proprietary',\n}\n\n// Export rule engine types and functions for programmatic usage\nexport {\n executeRules,\n executeRuleById,\n executeRuleByRuleId,\n executeSingleRule,\n findApplicableRules,\n logRuleExecution,\n type RuleEngineContext,\n type RuleEngineResult,\n type RuleExecutionResult,\n type RuleDiscoveryOptions,\n type DirectRuleExecutionContext,\n type DirectRuleExecutionResult,\n type RuleIdExecutionContext,\n} from './lib/rule-engine'\n\n// Export validator schemas\nexport {\n directRuleExecutionContextSchema,\n ruleIdExecutionContextSchema,\n type DirectRuleExecutionContextInput,\n type RuleIdExecutionContextInput,\n} from './data/validators'\n"],
5
- "mappings": "AAEO,MAAM,WAAuB;AAAA,EAClC,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,EACT,aAAa;AAAA,EACb,QAAQ;AAAA,EACR,SAAS;AACX;AAGA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAQK;AAGP;AAAA,EACE;AAAA,EACA;AAAA,OAGK;",
4
+ "sourcesContent": ["import type { ModuleInfo } from '@open-mercato/shared/modules/registry'\n\nexport const metadata: ModuleInfo = {\n name: 'business_rules',\n title: 'Business Rules',\n version: '0.1.0',\n description: 'Business Rules Engine for defining, managing, and executing business logic and automation rules.',\n author: 'Patryk Lewczuk',\n license: 'Proprietary',\n}\n"],
5
+ "mappings": "AAEO,MAAM,WAAuB;AAAA,EAClC,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,EACT,aAAa;AAAA,EACb,QAAQ;AAAA,EACR,SAAS;AACX;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,7 @@
1
1
  import { BusinessRule, RuleExecutionLog } from "../data/entities.js";
2
2
  import * as ruleEvaluator from "./rule-evaluator.js";
3
3
  import * as actionExecutor from "./action-executor.js";
4
- import { ruleEngineContextSchema, ruleDiscoveryOptionsSchema, directRuleExecutionContextSchema, ruleIdExecutionContextSchema } from "../data/validators.js";
4
+ import { ruleEngineContextSchema, ruleDiscoveryOptionsSchema } from "../data/validators.js";
5
5
  const DEFAULT_ENTITY_ID = "unknown";
6
6
  const RULE_TYPE_GUARD = "GUARD";
7
7
  const EXECUTION_RESULT_ERROR = "ERROR";
@@ -240,185 +240,6 @@ async function findApplicableRules(em, options) {
240
240
  return true;
241
241
  });
242
242
  }
243
- async function executeRuleById(em, context) {
244
- const startTime = Date.now();
245
- const validation = directRuleExecutionContextSchema.safeParse(context);
246
- if (!validation.success) {
247
- const validationErrors = validation.error.issues.map((e) => `${e.path.join(".")}: ${e.message}`);
248
- return {
249
- success: false,
250
- ruleId: context.ruleId,
251
- ruleName: "Unknown",
252
- conditionResult: false,
253
- actionsExecuted: null,
254
- executionTime: Date.now() - startTime,
255
- error: `Validation failed: ${validationErrors.join(", ")}`
256
- };
257
- }
258
- const rule = await em.findOne(BusinessRule, {
259
- id: context.ruleId,
260
- tenantId: context.tenantId,
261
- organizationId: context.organizationId,
262
- deletedAt: null
263
- });
264
- if (!rule) {
265
- return {
266
- success: false,
267
- ruleId: context.ruleId,
268
- ruleName: "Unknown",
269
- conditionResult: false,
270
- actionsExecuted: null,
271
- executionTime: Date.now() - startTime,
272
- error: "Rule not found"
273
- };
274
- }
275
- if (!rule.enabled) {
276
- return {
277
- success: false,
278
- ruleId: rule.ruleId,
279
- ruleName: rule.ruleName,
280
- conditionResult: false,
281
- actionsExecuted: null,
282
- executionTime: Date.now() - startTime,
283
- error: "Rule is disabled"
284
- };
285
- }
286
- const now = /* @__PURE__ */ new Date();
287
- if (rule.effectiveFrom && rule.effectiveFrom > now) {
288
- return {
289
- success: false,
290
- ruleId: rule.ruleId,
291
- ruleName: rule.ruleName,
292
- conditionResult: false,
293
- actionsExecuted: null,
294
- executionTime: Date.now() - startTime,
295
- error: `Rule is not yet effective (starts ${rule.effectiveFrom.toISOString()})`
296
- };
297
- }
298
- if (rule.effectiveTo && rule.effectiveTo < now) {
299
- return {
300
- success: false,
301
- ruleId: rule.ruleId,
302
- ruleName: rule.ruleName,
303
- conditionResult: false,
304
- actionsExecuted: null,
305
- executionTime: Date.now() - startTime,
306
- error: `Rule has expired (ended ${rule.effectiveTo.toISOString()})`
307
- };
308
- }
309
- const engineContext = {
310
- entityType: context.entityType || rule.entityType,
311
- entityId: context.entityId,
312
- eventType: context.eventType || rule.eventType || void 0,
313
- data: context.data,
314
- user: context.user,
315
- tenantId: context.tenantId,
316
- organizationId: context.organizationId,
317
- executedBy: context.executedBy,
318
- dryRun: context.dryRun
319
- };
320
- const result = await executeSingleRule(em, rule, engineContext);
321
- return {
322
- success: !result.error,
323
- ruleId: rule.ruleId,
324
- ruleName: rule.ruleName,
325
- conditionResult: result.conditionResult,
326
- actionsExecuted: result.actionsExecuted,
327
- executionTime: result.executionTime,
328
- error: result.error,
329
- logId: result.logId
330
- };
331
- }
332
- async function executeRuleByRuleId(em, context) {
333
- const startTime = Date.now();
334
- const validation = ruleIdExecutionContextSchema.safeParse(context);
335
- if (!validation.success) {
336
- const validationErrors = validation.error.issues.map((e) => `${e.path.join(".")}: ${e.message}`);
337
- return {
338
- success: false,
339
- ruleId: context.ruleId || "unknown",
340
- ruleName: "Unknown",
341
- conditionResult: false,
342
- actionsExecuted: null,
343
- executionTime: Date.now() - startTime,
344
- error: `Validation failed: ${validationErrors.join(", ")}`
345
- };
346
- }
347
- const rule = await em.findOne(BusinessRule, {
348
- ruleId: context.ruleId,
349
- // String identifier column
350
- tenantId: context.tenantId,
351
- organizationId: context.organizationId,
352
- deletedAt: null
353
- });
354
- if (!rule) {
355
- return {
356
- success: false,
357
- ruleId: context.ruleId,
358
- ruleName: "Unknown",
359
- conditionResult: false,
360
- actionsExecuted: null,
361
- executionTime: Date.now() - startTime,
362
- error: "Rule not found"
363
- };
364
- }
365
- if (!rule.enabled) {
366
- return {
367
- success: false,
368
- ruleId: rule.ruleId,
369
- ruleName: rule.ruleName,
370
- conditionResult: false,
371
- actionsExecuted: null,
372
- executionTime: Date.now() - startTime,
373
- error: "Rule is disabled"
374
- };
375
- }
376
- const now = /* @__PURE__ */ new Date();
377
- if (rule.effectiveFrom && rule.effectiveFrom > now) {
378
- return {
379
- success: false,
380
- ruleId: rule.ruleId,
381
- ruleName: rule.ruleName,
382
- conditionResult: false,
383
- actionsExecuted: null,
384
- executionTime: Date.now() - startTime,
385
- error: `Rule is not yet effective (starts ${rule.effectiveFrom.toISOString()})`
386
- };
387
- }
388
- if (rule.effectiveTo && rule.effectiveTo < now) {
389
- return {
390
- success: false,
391
- ruleId: rule.ruleId,
392
- ruleName: rule.ruleName,
393
- conditionResult: false,
394
- actionsExecuted: null,
395
- executionTime: Date.now() - startTime,
396
- error: `Rule has expired (ended ${rule.effectiveTo.toISOString()})`
397
- };
398
- }
399
- const engineContext = {
400
- entityType: context.entityType || rule.entityType,
401
- entityId: context.entityId,
402
- eventType: context.eventType || rule.eventType || void 0,
403
- data: context.data,
404
- user: context.user,
405
- tenantId: context.tenantId,
406
- organizationId: context.organizationId,
407
- executedBy: context.executedBy,
408
- dryRun: context.dryRun
409
- };
410
- const result = await executeSingleRule(em, rule, engineContext);
411
- return {
412
- success: !result.error,
413
- ruleId: rule.ruleId,
414
- ruleName: rule.ruleName,
415
- conditionResult: result.conditionResult,
416
- actionsExecuted: result.actionsExecuted,
417
- executionTime: result.executionTime,
418
- error: result.error,
419
- logId: result.logId
420
- };
421
- }
422
243
  const SENSITIVE_FIELD_PATTERNS = [
423
244
  /password/i,
424
245
  /passwd/i,
@@ -504,8 +325,6 @@ async function logRuleExecution(em, options) {
504
325
  return log.id;
505
326
  }
506
327
  export {
507
- executeRuleById,
508
- executeRuleByRuleId,
509
328
  executeRules,
510
329
  executeSingleRule,
511
330
  findApplicableRules,