@voyantjs/distribution 0.6.7 → 0.6.8

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.
@@ -1 +1 @@
1
- {"version":3,"file":"schema-automation.d.ts","sourceRoot":"","sources":["../src/schema-automation.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BrC,CAAA;AAED,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BzC,CAAA;AAED,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAqBnC,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG,OAAO,yBAAyB,CAAC,YAAY,CAAA;AACnF,MAAM,MAAM,0BAA0B,GAAG,OAAO,yBAAy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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsBnC,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG,OAAO,yBAAyB,CAAC,YAAY,CAAA;AACnF,MAAM,MAAM,0BAA0B,GAAG,OAAO,yBAAyB,CAAC,YAAY,CAAA;AACtF,MAAM,MAAM,2BAA2B,GAAG,OAAO,6BAA6B,CAAC,YAAY,CAAA;AAC3F,MAAM,MAAM,8BAA8B,GAAG,OAAO,6BAA6B,CAAC,YAAY,CAAA;AAC9F,MAAM,MAAM,sBAAsB,GAAG,OAAO,uBAAuB,CAAC,YAAY,CAAA;AAChF,MAAM,MAAM,yBAAyB,GAAG,OAAO,uBAAuB,CAAC,YAAY,CAAA"}
@@ -23,10 +23,11 @@ export const channelSettlementPolicies = pgTable("channel_settlement_policies",
23
23
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
24
24
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
25
25
  }, (table) => [
26
- index("idx_channel_settlement_policies_channel").on(table.channelId),
27
- index("idx_channel_settlement_policies_contract").on(table.contractId),
28
- index("idx_channel_settlement_policies_frequency").on(table.frequency),
29
- index("idx_channel_settlement_policies_active").on(table.active),
26
+ index("idx_channel_settlement_policies_updated").on(table.updatedAt),
27
+ index("idx_channel_settlement_policies_channel_updated").on(table.channelId, table.updatedAt),
28
+ index("idx_channel_settlement_policies_contract_updated").on(table.contractId, table.updatedAt),
29
+ index("idx_channel_settlement_policies_frequency_updated").on(table.frequency, table.updatedAt),
30
+ index("idx_channel_settlement_policies_active_updated").on(table.active, table.updatedAt),
30
31
  ]);
31
32
  export const channelReconciliationPolicies = pgTable("channel_reconciliation_policies", {
32
33
  id: typeId("channel_reconciliation_policies"),
@@ -48,10 +49,11 @@ export const channelReconciliationPolicies = pgTable("channel_reconciliation_pol
48
49
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
49
50
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
50
51
  }, (table) => [
51
- index("idx_channel_reconciliation_policies_channel").on(table.channelId),
52
- index("idx_channel_reconciliation_policies_contract").on(table.contractId),
53
- index("idx_channel_reconciliation_policies_frequency").on(table.frequency),
54
- index("idx_channel_reconciliation_policies_active").on(table.active),
52
+ index("idx_channel_reconciliation_policies_updated").on(table.updatedAt),
53
+ index("idx_channel_reconciliation_policies_channel_updated").on(table.channelId, table.updatedAt),
54
+ index("idx_channel_reconciliation_policies_contract_updated").on(table.contractId, table.updatedAt),
55
+ index("idx_channel_reconciliation_policies_frequency_updated").on(table.frequency, table.updatedAt),
56
+ index("idx_channel_reconciliation_policies_active_updated").on(table.active, table.updatedAt),
55
57
  ]);
56
58
  export const channelReleaseSchedules = pgTable("channel_release_schedules", {
57
59
  id: typeId("channel_release_schedules"),
@@ -67,7 +69,8 @@ export const channelReleaseSchedules = pgTable("channel_release_schedules", {
67
69
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
68
70
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
69
71
  }, (table) => [
70
- index("idx_channel_release_schedules_rule").on(table.releaseRuleId),
71
- index("idx_channel_release_schedules_kind").on(table.scheduleKind),
72
- index("idx_channel_release_schedules_active").on(table.active),
72
+ index("idx_channel_release_schedules_updated").on(table.updatedAt),
73
+ index("idx_channel_release_schedules_rule_updated").on(table.releaseRuleId, table.updatedAt),
74
+ index("idx_channel_release_schedules_kind_updated").on(table.scheduleKind, table.updatedAt),
75
+ index("idx_channel_release_schedules_active_updated").on(table.active, table.updatedAt),
73
76
  ]);
@@ -1 +1 @@
1
- {"version":3,"file":"schema-core.d.ts","sourceRoot":"","sources":["../src/schema-core.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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,wBAAwB,GAAG,OAAO,sBAAsB,CAAC,YAAY,CAAA;AACjF,MAAM,MAAM,kBAAkB,GAAG,OAAO,mBAAmB,CAAC,YAAY,CAAA;AACxE,MAAM,MAAM,qBAAqB,GAAG,OAAO,mBAAmB,CAAC,YAAY,CAAA;AAC3E,MAAM,MAAM,mBAAmB,GAAG,OAAO,oBAAoB,CAAC,YAAY,CAAA;AAC1E,MAAM,MAAM,sBAAsB,GAAG,OAAO,oBAAoB,CAAC,YAAY,CAAA"}
@@ -13,6 +13,7 @@ export const channels = pgTable("channels", {
13
13
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
14
14
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
15
15
  }, (table) => [
16
+ index("idx_channels_created").on(table.createdAt),
16
17
  index("idx_channels_kind_created").on(table.kind, table.createdAt),
17
18
  index("idx_channels_status_created").on(table.status, table.createdAt),
18
19
  ]);
@@ -46,9 +47,9 @@ export const channelContracts = pgTable("channel_contracts", {
46
47
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
47
48
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
48
49
  }, (table) => [
49
- index("idx_channel_contracts_channel").on(table.channelId),
50
- index("idx_channel_contracts_supplier").on(table.supplierId),
51
- index("idx_channel_contracts_status").on(table.status),
50
+ index("idx_channel_contracts_channel_created").on(table.channelId, table.createdAt),
51
+ index("idx_channel_contracts_supplier_created").on(table.supplierId, table.createdAt),
52
+ index("idx_channel_contracts_status_created").on(table.status, table.createdAt),
52
53
  ]);
53
54
  export const channelCommissionRules = pgTable("channel_commission_rules", {
54
55
  id: typeId("channel_commission_rules"),
@@ -67,9 +68,9 @@ export const channelCommissionRules = pgTable("channel_commission_rules", {
67
68
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
68
69
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
69
70
  }, (table) => [
70
- index("idx_channel_commission_rules_contract").on(table.contractId),
71
- index("idx_channel_commission_rules_product").on(table.productId),
72
- index("idx_channel_commission_rules_scope").on(table.scope),
71
+ index("idx_channel_commission_rules_contract_created").on(table.contractId, table.createdAt),
72
+ index("idx_channel_commission_rules_product_created").on(table.productId, table.createdAt),
73
+ index("idx_channel_commission_rules_scope_created").on(table.scope, table.createdAt),
73
74
  ]);
74
75
  export const channelProductMappings = pgTable("channel_product_mappings", {
75
76
  id: typeId("channel_product_mappings"),
@@ -86,9 +87,9 @@ export const channelProductMappings = pgTable("channel_product_mappings", {
86
87
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
87
88
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
88
89
  }, (table) => [
89
- index("idx_channel_product_mappings_channel").on(table.channelId),
90
- index("idx_channel_product_mappings_product").on(table.productId),
91
- index("idx_channel_product_mappings_active").on(table.active),
90
+ index("idx_channel_product_mappings_channel_created").on(table.channelId, table.createdAt),
91
+ index("idx_channel_product_mappings_product_created").on(table.productId, table.createdAt),
92
+ index("idx_channel_product_mappings_active_created").on(table.active, table.createdAt),
92
93
  ]);
93
94
  export const channelBookingLinks = pgTable("channel_booking_links", {
94
95
  id: typeId("channel_booking_links"),
@@ -104,9 +105,9 @@ export const channelBookingLinks = pgTable("channel_booking_links", {
104
105
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
105
106
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
106
107
  }, (table) => [
107
- index("idx_channel_booking_links_channel").on(table.channelId),
108
- index("idx_channel_booking_links_booking").on(table.bookingId),
109
- index("idx_channel_booking_links_external_booking").on(table.externalBookingId),
108
+ index("idx_channel_booking_links_channel_created").on(table.channelId, table.createdAt),
109
+ index("idx_channel_booking_links_booking_created").on(table.bookingId, table.createdAt),
110
+ index("idx_channel_booking_links_external_booking_created").on(table.externalBookingId, table.createdAt),
110
111
  ]);
111
112
  export const channelWebhookEvents = pgTable("channel_webhook_events", {
112
113
  id: typeId("channel_webhook_events"),
@@ -122,7 +123,8 @@ export const channelWebhookEvents = pgTable("channel_webhook_events", {
122
123
  errorMessage: text("error_message"),
123
124
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
124
125
  }, (table) => [
125
- index("idx_channel_webhook_events_channel").on(table.channelId),
126
- index("idx_channel_webhook_events_status").on(table.status),
126
+ index("idx_channel_webhook_events_channel_received").on(table.channelId, table.receivedAt),
127
+ index("idx_channel_webhook_events_status_received").on(table.status, table.receivedAt),
128
+ index("idx_channel_webhook_events_event_type_received").on(table.eventType, table.receivedAt),
127
129
  index("idx_channel_webhook_events_external_event").on(table.externalEventId),
128
130
  ]);
@@ -1 +1 @@
1
- {"version":3,"file":"schema-finance.d.ts","sourceRoot":"","sources":["../src/schema-finance.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA6BjC,CAAA;AAED,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+BlC,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuBtC,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG,OAAO,qBAAqB,CAAC,YAAY,CAAA;AAC5E,MAAM,MAAM,uBAAuB,GAAG,OAAO,qBAAqB,CAAC,YAAY,CAAA;AAC/E,MAAM,MAAM,qBAAqB,GAAG,OAAO,sBAAsB,CAAC,YAAY,CAAA;AAC9E,MAAM,MAAM,wBAAwB,GAAG,OAAO,sBAAsB,CAAC,YAAY,CAAA;AACjF,MAAM,MAAM,wBAAwB,GAAG,OAAO,yBAAyB,CAAC,YAAY,CAAA;AACpF,MAAM,MAAM,2BAA2B,GAAG,OAAO,yBAAyB,CAAC,YAAY,CAAA;AACvF,MAAM,MAAM,yBAAyB,GAAG,OAAO,0BAA0B,CAAC,YAAY,CAAA;AACtF,MAAM,MAAM,4BAA4B,GAAG,OAAO,0BAA0B,CAAC,YAAY,CAAA;AACzF,MAAM,MAAM,0BAA0B,GAAG,OAAO,2BAA2B,CAAC,YAAY,CAAA;AACxF,MAAM,MAAM,6BAA6B,GAAG,OAAO,2BAA2B,CAAC,YAAY,CAAA;AAC3F,MAAM,MAAM,yBAAyB,GAAG,OAAO,0BAA0B,CAAC,YAAY,CAAA;AACtF,MAAM,MAAM,4BAA4B,GAAG,OAAO,0BAA0B,CAAC,YAAY,CAAA"}
@@ -23,9 +23,10 @@ export const channelSettlementRuns = pgTable("channel_settlement_runs", {
23
23
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
24
24
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
25
25
  }, (table) => [
26
- index("idx_channel_settlement_runs_channel").on(table.channelId),
27
- index("idx_channel_settlement_runs_contract").on(table.contractId),
28
- index("idx_channel_settlement_runs_status").on(table.status),
26
+ index("idx_channel_settlement_runs_updated").on(table.updatedAt),
27
+ index("idx_channel_settlement_runs_channel_updated").on(table.channelId, table.updatedAt),
28
+ index("idx_channel_settlement_runs_contract_updated").on(table.contractId, table.updatedAt),
29
+ index("idx_channel_settlement_runs_status_updated").on(table.status, table.updatedAt),
29
30
  index("idx_channel_settlement_runs_period").on(table.periodStart, table.periodEnd),
30
31
  ]);
31
32
  export const channelSettlementItems = pgTable("channel_settlement_items", {
@@ -51,10 +52,11 @@ export const channelSettlementItems = pgTable("channel_settlement_items", {
51
52
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
52
53
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
53
54
  }, (table) => [
54
- index("idx_channel_settlement_items_run").on(table.settlementRunId),
55
- index("idx_channel_settlement_items_booking_link").on(table.bookingLinkId),
56
- index("idx_channel_settlement_items_booking").on(table.bookingId),
57
- index("idx_channel_settlement_items_status").on(table.status),
55
+ index("idx_channel_settlement_items_updated").on(table.updatedAt),
56
+ index("idx_channel_settlement_items_run_updated").on(table.settlementRunId, table.updatedAt),
57
+ index("idx_channel_settlement_items_booking_link_updated").on(table.bookingLinkId, table.updatedAt),
58
+ index("idx_channel_settlement_items_booking_updated").on(table.bookingId, table.updatedAt),
59
+ index("idx_channel_settlement_items_status_updated").on(table.status, table.updatedAt),
58
60
  ]);
59
61
  export const channelReconciliationRuns = pgTable("channel_reconciliation_runs", {
60
62
  id: typeId("channel_reconciliation_runs"),
@@ -75,9 +77,10 @@ export const channelReconciliationRuns = pgTable("channel_reconciliation_runs",
75
77
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
76
78
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
77
79
  }, (table) => [
78
- index("idx_channel_reconciliation_runs_channel").on(table.channelId),
79
- index("idx_channel_reconciliation_runs_contract").on(table.contractId),
80
- index("idx_channel_reconciliation_runs_status").on(table.status),
80
+ index("idx_channel_reconciliation_runs_updated").on(table.updatedAt),
81
+ index("idx_channel_reconciliation_runs_channel_updated").on(table.channelId, table.updatedAt),
82
+ index("idx_channel_reconciliation_runs_contract_updated").on(table.contractId, table.updatedAt),
83
+ index("idx_channel_reconciliation_runs_status_updated").on(table.status, table.updatedAt),
81
84
  ]);
82
85
  export const channelReconciliationItems = pgTable("channel_reconciliation_items", {
83
86
  id: typeId("channel_reconciliation_items"),
@@ -99,11 +102,12 @@ export const channelReconciliationItems = pgTable("channel_reconciliation_items"
99
102
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
100
103
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
101
104
  }, (table) => [
102
- index("idx_channel_reconciliation_items_run").on(table.reconciliationRunId),
103
- index("idx_channel_reconciliation_items_booking_link").on(table.bookingLinkId),
104
- index("idx_channel_reconciliation_items_booking").on(table.bookingId),
105
- index("idx_channel_reconciliation_items_issue").on(table.issueType),
106
- index("idx_channel_reconciliation_items_resolution").on(table.resolutionStatus),
105
+ index("idx_channel_reconciliation_items_updated").on(table.updatedAt),
106
+ index("idx_channel_reconciliation_items_run_updated").on(table.reconciliationRunId, table.updatedAt),
107
+ index("idx_channel_reconciliation_items_booking_link_updated").on(table.bookingLinkId, table.updatedAt),
108
+ index("idx_channel_reconciliation_items_booking_updated").on(table.bookingId, table.updatedAt),
109
+ index("idx_channel_reconciliation_items_issue_updated").on(table.issueType, table.updatedAt),
110
+ index("idx_channel_reconciliation_items_resolution_updated").on(table.resolutionStatus, table.updatedAt),
107
111
  ]);
108
112
  export const channelRemittanceExceptions = pgTable("channel_remittance_exceptions", {
109
113
  id: typeId("channel_remittance_exceptions"),
@@ -124,10 +128,11 @@ export const channelRemittanceExceptions = pgTable("channel_remittance_exception
124
128
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
125
129
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
126
130
  }, (table) => [
127
- index("idx_channel_remittance_exceptions_channel").on(table.channelId),
128
- index("idx_channel_remittance_exceptions_settlement_item").on(table.settlementItemId),
129
- index("idx_channel_remittance_exceptions_reconciliation_item").on(table.reconciliationItemId),
130
- index("idx_channel_remittance_exceptions_status").on(table.status),
131
+ index("idx_channel_remittance_exceptions_updated").on(table.updatedAt),
132
+ index("idx_channel_remittance_exceptions_channel_updated").on(table.channelId, table.updatedAt),
133
+ index("idx_channel_remittance_exceptions_settlement_item_updated").on(table.settlementItemId, table.updatedAt),
134
+ index("idx_channel_remittance_exceptions_reconciliation_item_updated").on(table.reconciliationItemId, table.updatedAt),
135
+ index("idx_channel_remittance_exceptions_status_updated").on(table.status, table.updatedAt),
131
136
  ]);
132
137
  export const channelSettlementApprovals = pgTable("channel_settlement_approvals", {
133
138
  id: typeId("channel_settlement_approvals"),
@@ -142,6 +147,7 @@ export const channelSettlementApprovals = pgTable("channel_settlement_approvals"
142
147
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
143
148
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
144
149
  }, (table) => [
145
- index("idx_channel_settlement_approvals_run").on(table.settlementRunId),
146
- index("idx_channel_settlement_approvals_status").on(table.status),
150
+ index("idx_channel_settlement_approvals_updated").on(table.updatedAt),
151
+ index("idx_channel_settlement_approvals_run_updated").on(table.settlementRunId, table.updatedAt),
152
+ index("idx_channel_settlement_approvals_status_updated").on(table.status, table.updatedAt),
147
153
  ]);
@@ -1 +1 @@
1
- {"version":3,"file":"schema-inventory.d.ts","sourceRoot":"","sources":["../src/schema-inventory.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8C7C,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG,OAAO,0BAA0B,CAAC,YAAY,CAAA;AACtF,MAAM,MAAM,4BAA4B,GAAG,OAAO,0BAA0B,CAAC,YAAY,CAAA;AACzF,MAAM,MAAM,+BAA+B,GAAG,OAAO,gCAAgC,CAAC,YAAY,CAAA;AAClG,MAAM,MAAM,kCAAkC,GAC5C,OAAO,gCAAgC,CAAC,YAAY,CAAA;AACtD,MAAM,MAAM,2BAA2B,GAAG,OAAO,4BAA4B,CAAC,YAAY,CAAA;AAC1F,MAAM,MAAM,8BAA8B,GAAG,OAAO,4BAA4B,CAAC,YAAY,CAAA;AAC7F,MAAM,MAAM,gCAAgC,GAAG,OAAO,iCAAiC,CAAC,YAAY,CAAA;AACpG,MAAM,MAAM,mCAAmC,GAC7C,OAAO,iCAAiC,CAAC,YAAY,CAAA"}
@@ -28,12 +28,13 @@ export const channelInventoryAllotments = pgTable("channel_inventory_allotments"
28
28
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
29
29
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
30
30
  }, (table) => [
31
- index("idx_channel_inventory_allotments_channel").on(table.channelId),
32
- index("idx_channel_inventory_allotments_contract").on(table.contractId),
33
- index("idx_channel_inventory_allotments_product").on(table.productId),
34
- index("idx_channel_inventory_allotments_option").on(table.optionId),
35
- index("idx_channel_inventory_allotments_start_time").on(table.startTimeId),
36
- index("idx_channel_inventory_allotments_active").on(table.active),
31
+ index("idx_channel_inventory_allotments_updated").on(table.updatedAt),
32
+ index("idx_channel_inventory_allotments_channel_updated").on(table.channelId, table.updatedAt),
33
+ index("idx_channel_inventory_allotments_contract_updated").on(table.contractId, table.updatedAt),
34
+ index("idx_channel_inventory_allotments_product_updated").on(table.productId, table.updatedAt),
35
+ index("idx_channel_inventory_allotments_option_updated").on(table.optionId, table.updatedAt),
36
+ index("idx_channel_inventory_allotments_start_time_updated").on(table.startTimeId, table.updatedAt),
37
+ index("idx_channel_inventory_allotments_active_updated").on(table.active, table.updatedAt),
37
38
  ]);
38
39
  export const channelInventoryAllotmentTargets = pgTable("channel_inventory_allotment_targets", {
39
40
  id: typeId("channel_inventory_allotment_targets"),
@@ -53,11 +54,12 @@ export const channelInventoryAllotmentTargets = pgTable("channel_inventory_allot
53
54
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
54
55
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
55
56
  }, (table) => [
56
- index("idx_channel_inventory_allotment_targets_allotment").on(table.allotmentId),
57
- index("idx_channel_inventory_allotment_targets_slot").on(table.slotId),
58
- index("idx_channel_inventory_allotment_targets_start_time").on(table.startTimeId),
59
- index("idx_channel_inventory_allotment_targets_date").on(table.dateLocal),
60
- index("idx_channel_inventory_allotment_targets_active").on(table.active),
57
+ index("idx_channel_inventory_allotment_targets_updated").on(table.updatedAt),
58
+ index("idx_channel_inventory_allotment_targets_allotment_updated").on(table.allotmentId, table.updatedAt),
59
+ index("idx_channel_inventory_allotment_targets_slot_updated").on(table.slotId, table.updatedAt),
60
+ index("idx_channel_inventory_allotment_targets_start_time_updated").on(table.startTimeId, table.updatedAt),
61
+ index("idx_channel_inventory_allotment_targets_date_updated").on(table.dateLocal, table.updatedAt),
62
+ index("idx_channel_inventory_allotment_targets_active_updated").on(table.active, table.updatedAt),
61
63
  ]);
62
64
  export const channelInventoryReleaseRules = pgTable("channel_inventory_release_rules", {
63
65
  id: typeId("channel_inventory_release_rules"),
@@ -74,8 +76,9 @@ export const channelInventoryReleaseRules = pgTable("channel_inventory_release_r
74
76
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
75
77
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
76
78
  }, (table) => [
77
- index("idx_channel_inventory_release_rules_allotment").on(table.allotmentId),
78
- index("idx_channel_inventory_release_rules_mode").on(table.releaseMode),
79
+ index("idx_channel_inventory_release_rules_updated").on(table.updatedAt),
80
+ index("idx_channel_inventory_release_rules_allotment_updated").on(table.allotmentId, table.updatedAt),
81
+ index("idx_channel_inventory_release_rules_mode_updated").on(table.releaseMode, table.updatedAt),
79
82
  ]);
80
83
  export const channelInventoryReleaseExecutions = pgTable("channel_inventory_release_executions", {
81
84
  id: typeId("channel_inventory_release_executions"),
@@ -98,8 +101,10 @@ export const channelInventoryReleaseExecutions = pgTable("channel_inventory_rele
98
101
  createdAt: timestamp("created_at", { withTimezone: true }).notNull().defaultNow(),
99
102
  updatedAt: timestamp("updated_at", { withTimezone: true }).notNull().defaultNow(),
100
103
  }, (table) => [
101
- index("idx_channel_inventory_release_executions_allotment").on(table.allotmentId),
102
- index("idx_channel_inventory_release_executions_rule").on(table.releaseRuleId),
103
- index("idx_channel_inventory_release_executions_target").on(table.targetId),
104
- index("idx_channel_inventory_release_executions_status").on(table.status),
104
+ index("idx_channel_inventory_release_executions_updated").on(table.updatedAt),
105
+ index("idx_channel_inventory_release_executions_allotment_updated").on(table.allotmentId, table.updatedAt),
106
+ index("idx_channel_inventory_release_executions_rule_updated").on(table.releaseRuleId, table.updatedAt),
107
+ index("idx_channel_inventory_release_executions_target_updated").on(table.targetId, table.updatedAt),
108
+ index("idx_channel_inventory_release_executions_slot_updated").on(table.slotId, table.updatedAt),
109
+ index("idx_channel_inventory_release_executions_status_updated").on(table.status, table.updatedAt),
105
110
  ]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voyantjs/distribution",
3
- "version": "0.6.7",
3
+ "version": "0.6.8",
4
4
  "license": "FSL-1.1-Apache-2.0",
5
5
  "type": "module",
6
6
  "exports": {
@@ -29,13 +29,13 @@
29
29
  "drizzle-orm": "^0.45.2",
30
30
  "hono": "^4.12.10",
31
31
  "zod": "^4.3.6",
32
- "@voyantjs/availability": "0.6.7",
33
- "@voyantjs/core": "0.6.7",
34
- "@voyantjs/db": "0.6.7",
35
- "@voyantjs/hono": "0.6.7",
36
- "@voyantjs/identity": "0.6.7",
37
- "@voyantjs/products": "0.6.7",
38
- "@voyantjs/suppliers": "0.6.7"
32
+ "@voyantjs/availability": "0.6.8",
33
+ "@voyantjs/core": "0.6.8",
34
+ "@voyantjs/db": "0.6.8",
35
+ "@voyantjs/hono": "0.6.8",
36
+ "@voyantjs/identity": "0.6.8",
37
+ "@voyantjs/products": "0.6.8",
38
+ "@voyantjs/suppliers": "0.6.8"
39
39
  },
40
40
  "devDependencies": {
41
41
  "typescript": "^6.0.2",