@flowselections/floriday-afhandeling-module 1.0.15 → 1.0.17

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 (91) hide show
  1. package/dist-lib/components/afhandeling/LeveringenPage.d.ts.map +1 -1
  2. package/dist-lib/components/afhandeling/LeveringenPage.js +2 -2
  3. package/dist-lib/components/afhandeling/PickAgendaView.d.ts.map +1 -1
  4. package/dist-lib/components/afhandeling/PickAgendaView.js +2 -3
  5. package/dist-lib/components/afhandeling/WeekAgendaView.d.ts.map +1 -1
  6. package/dist-lib/components/afhandeling/WeekAgendaView.js +31 -17
  7. package/dist-lib/components/engine/CapaciteitsmaatregelenPage.d.ts +2 -0
  8. package/dist-lib/components/engine/CapaciteitsmaatregelenPage.d.ts.map +1 -0
  9. package/dist-lib/components/engine/CapaciteitsmaatregelenPage.js +40 -0
  10. package/dist-lib/components/engine/CapaciteitsmonitorPage.d.ts +2 -0
  11. package/dist-lib/components/engine/CapaciteitsmonitorPage.d.ts.map +1 -0
  12. package/dist-lib/components/engine/CapaciteitsmonitorPage.js +49 -0
  13. package/dist-lib/components/engine/FormulesPage.d.ts +2 -0
  14. package/dist-lib/components/engine/FormulesPage.d.ts.map +1 -0
  15. package/dist-lib/components/engine/FormulesPage.js +252 -0
  16. package/dist-lib/components/engine/PlaceholderPage.d.ts +6 -0
  17. package/dist-lib/components/engine/PlaceholderPage.d.ts.map +1 -0
  18. package/dist-lib/components/engine/PlaceholderPage.js +6 -0
  19. package/dist-lib/components/engine/StrategieenPage.d.ts +2 -0
  20. package/dist-lib/components/engine/StrategieenPage.d.ts.map +1 -0
  21. package/dist-lib/components/engine/StrategieenPage.js +80 -0
  22. package/dist-lib/components/pickstation/PickstationPage.d.ts.map +1 -1
  23. package/dist-lib/components/pickstation/PickstationPage.js +16 -4
  24. package/dist-lib/hooks/useOrderPlanning.d.ts.map +1 -1
  25. package/dist-lib/hooks/useOrderPlanning.js +37 -3
  26. package/dist-lib/index.d.ts.map +1 -1
  27. package/dist-lib/index.js +2 -1
  28. package/dist-lib/integrations/supabase/auth-middleware.d.ts +1496 -272
  29. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  30. package/dist-lib/integrations/supabase/client.d.ts +1496 -272
  31. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  32. package/dist-lib/integrations/supabase/client.server.d.ts +1496 -272
  33. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  34. package/dist-lib/integrations/supabase/types.d.ts +1523 -266
  35. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  36. package/dist-lib/lib/afhandelingSettings.functions.d.ts +2944 -496
  37. package/dist-lib/lib/afhandelingSettings.functions.d.ts.map +1 -1
  38. package/dist-lib/lib/ai-gateway.server.d.ts +2 -0
  39. package/dist-lib/lib/ai-gateway.server.d.ts.map +1 -0
  40. package/dist-lib/lib/ai-gateway.server.js +11 -0
  41. package/dist-lib/lib/authGateway.server.d.ts +16 -0
  42. package/dist-lib/lib/authGateway.server.d.ts.map +1 -0
  43. package/dist-lib/lib/authGateway.server.js +200 -0
  44. package/dist-lib/lib/carriers.functions.d.ts +7100 -980
  45. package/dist-lib/lib/carriers.functions.d.ts.map +1 -1
  46. package/dist-lib/lib/cartAssignments.functions.d.ts +7100 -980
  47. package/dist-lib/lib/cartAssignments.functions.d.ts.map +1 -1
  48. package/dist-lib/lib/cartControl.functions.d.ts +14630 -2390
  49. package/dist-lib/lib/cartControl.functions.d.ts.map +1 -1
  50. package/dist-lib/lib/floriday.functions.d.ts +1496 -272
  51. package/dist-lib/lib/floriday.functions.d.ts.map +1 -1
  52. package/dist-lib/lib/floriday.functions.js +41 -8
  53. package/dist-lib/lib/logisticsEngine/capacity.functions.d.ts +50282 -0
  54. package/dist-lib/lib/logisticsEngine/capacity.functions.d.ts.map +1 -0
  55. package/dist-lib/lib/logisticsEngine/capacity.functions.js +90 -0
  56. package/dist-lib/lib/logisticsEngine/config.d.ts +140 -0
  57. package/dist-lib/lib/logisticsEngine/config.d.ts.map +1 -0
  58. package/dist-lib/lib/logisticsEngine/config.js +488 -0
  59. package/dist-lib/lib/logisticsEngine/enginePickTime.d.ts +29 -0
  60. package/dist-lib/lib/logisticsEngine/enginePickTime.d.ts.map +1 -0
  61. package/dist-lib/lib/logisticsEngine/enginePickTime.js +136 -0
  62. package/dist-lib/lib/logisticsEngine/evaluate.functions.d.ts +12604 -0
  63. package/dist-lib/lib/logisticsEngine/evaluate.functions.d.ts.map +1 -0
  64. package/dist-lib/lib/logisticsEngine/evaluate.functions.js +104 -0
  65. package/dist-lib/lib/logisticsEngine/expression.d.ts +21 -0
  66. package/dist-lib/lib/logisticsEngine/expression.d.ts.map +1 -0
  67. package/dist-lib/lib/logisticsEngine/expression.js +263 -0
  68. package/dist-lib/lib/logisticsEngine/formulas.functions.d.ts +25164 -0
  69. package/dist-lib/lib/logisticsEngine/formulas.functions.d.ts.map +1 -0
  70. package/dist-lib/lib/logisticsEngine/formulas.functions.js +58 -0
  71. package/dist-lib/lib/logisticsEngine/safetyLayer.d.ts +83 -0
  72. package/dist-lib/lib/logisticsEngine/safetyLayer.d.ts.map +1 -0
  73. package/dist-lib/lib/logisticsEngine/safetyLayer.js +182 -0
  74. package/dist-lib/lib/logisticsEngine/strategies.functions.d.ts +100569 -0
  75. package/dist-lib/lib/logisticsEngine/strategies.functions.d.ts.map +1 -0
  76. package/dist-lib/lib/logisticsEngine/strategies.functions.js +176 -0
  77. package/dist-lib/lib/logisticsEngine/variables.d.ts +29 -0
  78. package/dist-lib/lib/logisticsEngine/variables.d.ts.map +1 -0
  79. package/dist-lib/lib/logisticsEngine/variables.js +144 -0
  80. package/dist-lib/lib/logisticsEngine/wizard.functions.d.ts +50288 -0
  81. package/dist-lib/lib/logisticsEngine/wizard.functions.d.ts.map +1 -0
  82. package/dist-lib/lib/logisticsEngine/wizard.functions.js +175 -0
  83. package/dist-lib/lib/pickstationI18n.d.ts +2 -0
  84. package/dist-lib/lib/pickstationI18n.d.ts.map +1 -1
  85. package/dist-lib/lib/pickstationI18n.js +12 -0
  86. package/dist-lib/lib/pickstationOrders.server.d.ts +5 -0
  87. package/dist-lib/lib/pickstationOrders.server.d.ts.map +1 -1
  88. package/dist-lib/lib/pickstationOrders.server.js +29 -0
  89. package/dist-lib/lib/pickstationTypes.d.ts +4 -0
  90. package/dist-lib/lib/pickstationTypes.d.ts.map +1 -1
  91. package/package.json +24 -4
@@ -241,6 +241,165 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
241
241
  };
242
242
  Relationships: [];
243
243
  };
244
+ ai_credentials: {
245
+ Row: {
246
+ active: boolean;
247
+ api_key: string;
248
+ created_at: string;
249
+ created_by: string | null;
250
+ id: string;
251
+ label: string;
252
+ provider_id: string;
253
+ updated_at: string;
254
+ };
255
+ Insert: {
256
+ active?: boolean;
257
+ api_key: string;
258
+ created_at?: string;
259
+ created_by?: string | null;
260
+ id?: string;
261
+ label: string;
262
+ provider_id: string;
263
+ updated_at?: string;
264
+ };
265
+ Update: {
266
+ active?: boolean;
267
+ api_key?: string;
268
+ created_at?: string;
269
+ created_by?: string | null;
270
+ id?: string;
271
+ label?: string;
272
+ provider_id?: string;
273
+ updated_at?: string;
274
+ };
275
+ Relationships: [{
276
+ foreignKeyName: "ai_credentials_provider_id_fkey";
277
+ columns: ["provider_id"];
278
+ isOneToOne: false;
279
+ referencedRelation: "ai_providers";
280
+ referencedColumns: ["id"];
281
+ }];
282
+ };
283
+ ai_models: {
284
+ Row: {
285
+ active: boolean;
286
+ context_window: number | null;
287
+ created_at: string;
288
+ display_name: string;
289
+ id: string;
290
+ is_default: boolean;
291
+ modality: string;
292
+ provider_id: string;
293
+ slug: string;
294
+ updated_at: string;
295
+ };
296
+ Insert: {
297
+ active?: boolean;
298
+ context_window?: number | null;
299
+ created_at?: string;
300
+ display_name: string;
301
+ id?: string;
302
+ is_default?: boolean;
303
+ modality?: string;
304
+ provider_id: string;
305
+ slug: string;
306
+ updated_at?: string;
307
+ };
308
+ Update: {
309
+ active?: boolean;
310
+ context_window?: number | null;
311
+ created_at?: string;
312
+ display_name?: string;
313
+ id?: string;
314
+ is_default?: boolean;
315
+ modality?: string;
316
+ provider_id?: string;
317
+ slug?: string;
318
+ updated_at?: string;
319
+ };
320
+ Relationships: [{
321
+ foreignKeyName: "ai_models_provider_id_fkey";
322
+ columns: ["provider_id"];
323
+ isOneToOne: false;
324
+ referencedRelation: "ai_providers";
325
+ referencedColumns: ["id"];
326
+ }];
327
+ };
328
+ ai_module_bindings: {
329
+ Row: {
330
+ consumer_module_id: string;
331
+ created_at: string;
332
+ credential_id: string;
333
+ id: string;
334
+ model_id: string;
335
+ notes: string | null;
336
+ updated_at: string;
337
+ };
338
+ Insert: {
339
+ consumer_module_id: string;
340
+ created_at?: string;
341
+ credential_id: string;
342
+ id?: string;
343
+ model_id: string;
344
+ notes?: string | null;
345
+ updated_at?: string;
346
+ };
347
+ Update: {
348
+ consumer_module_id?: string;
349
+ created_at?: string;
350
+ credential_id?: string;
351
+ id?: string;
352
+ model_id?: string;
353
+ notes?: string | null;
354
+ updated_at?: string;
355
+ };
356
+ Relationships: [{
357
+ foreignKeyName: "ai_module_bindings_credential_id_fkey";
358
+ columns: ["credential_id"];
359
+ isOneToOne: false;
360
+ referencedRelation: "ai_credentials";
361
+ referencedColumns: ["id"];
362
+ }, {
363
+ foreignKeyName: "ai_module_bindings_model_id_fkey";
364
+ columns: ["model_id"];
365
+ isOneToOne: false;
366
+ referencedRelation: "ai_models";
367
+ referencedColumns: ["id"];
368
+ }];
369
+ };
370
+ ai_providers: {
371
+ Row: {
372
+ active: boolean;
373
+ auth_type: string;
374
+ base_url: string | null;
375
+ created_at: string;
376
+ id: string;
377
+ name: string;
378
+ slug: string;
379
+ updated_at: string;
380
+ };
381
+ Insert: {
382
+ active?: boolean;
383
+ auth_type?: string;
384
+ base_url?: string | null;
385
+ created_at?: string;
386
+ id?: string;
387
+ name: string;
388
+ slug: string;
389
+ updated_at?: string;
390
+ };
391
+ Update: {
392
+ active?: boolean;
393
+ auth_type?: string;
394
+ base_url?: string | null;
395
+ created_at?: string;
396
+ id?: string;
397
+ name?: string;
398
+ slug?: string;
399
+ updated_at?: string;
400
+ };
401
+ Relationships: [];
402
+ };
244
403
  app_settings: {
245
404
  Row: {
246
405
  created_at: string;
@@ -868,6 +1027,141 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
868
1027
  };
869
1028
  Relationships: [];
870
1029
  };
1030
+ cart_planning_pick_times: {
1031
+ Row: {
1032
+ created_at: string;
1033
+ id: string;
1034
+ pot_size: string;
1035
+ seconds_per_cart: number;
1036
+ updated_at: string;
1037
+ };
1038
+ Insert: {
1039
+ created_at?: string;
1040
+ id?: string;
1041
+ pot_size: string;
1042
+ seconds_per_cart: number;
1043
+ updated_at?: string;
1044
+ };
1045
+ Update: {
1046
+ created_at?: string;
1047
+ id?: string;
1048
+ pot_size?: string;
1049
+ seconds_per_cart?: number;
1050
+ updated_at?: string;
1051
+ };
1052
+ Relationships: [];
1053
+ };
1054
+ cart_planning_product_overrides: {
1055
+ Row: {
1056
+ created_at: string;
1057
+ id: string;
1058
+ max_party_share_per_layer_pct_override: number | null;
1059
+ never_mix: boolean;
1060
+ notes: string | null;
1061
+ product_id: string;
1062
+ updated_at: string;
1063
+ };
1064
+ Insert: {
1065
+ created_at?: string;
1066
+ id?: string;
1067
+ max_party_share_per_layer_pct_override?: number | null;
1068
+ never_mix?: boolean;
1069
+ notes?: string | null;
1070
+ product_id: string;
1071
+ updated_at?: string;
1072
+ };
1073
+ Update: {
1074
+ created_at?: string;
1075
+ id?: string;
1076
+ max_party_share_per_layer_pct_override?: number | null;
1077
+ never_mix?: boolean;
1078
+ notes?: string | null;
1079
+ product_id?: string;
1080
+ updated_at?: string;
1081
+ };
1082
+ Relationships: [{
1083
+ foreignKeyName: "cart_planning_product_overrides_product_id_fkey";
1084
+ columns: ["product_id"];
1085
+ isOneToOne: true;
1086
+ referencedRelation: "products";
1087
+ referencedColumns: ["id"];
1088
+ }];
1089
+ };
1090
+ cart_planning_settings: {
1091
+ Row: {
1092
+ allow_editing_after_pickstation_send: boolean;
1093
+ buffer_grouping_mode: string;
1094
+ combine_floriday_orders: boolean;
1095
+ combine_floriday_orders_window: string;
1096
+ combine_orders_scope: string;
1097
+ default_workers: number;
1098
+ id: number;
1099
+ max_beladingen_per_layer: number;
1100
+ max_customers_per_cart: number;
1101
+ max_one_customer_per_layer: boolean;
1102
+ max_party_share_per_layer_pct: number;
1103
+ optimization_strategy: string;
1104
+ own_cart_from_layers: number;
1105
+ pick_time_mode: string;
1106
+ plants_per_day: number;
1107
+ plants_per_hour: number;
1108
+ require_same_carrier: boolean;
1109
+ require_same_crate_type: boolean;
1110
+ require_same_delivery_date: boolean;
1111
+ require_same_delivery_location: boolean;
1112
+ updated_at: string;
1113
+ updated_by: string | null;
1114
+ };
1115
+ Insert: {
1116
+ allow_editing_after_pickstation_send?: boolean;
1117
+ buffer_grouping_mode?: string;
1118
+ combine_floriday_orders?: boolean;
1119
+ combine_floriday_orders_window?: string;
1120
+ combine_orders_scope?: string;
1121
+ default_workers?: number;
1122
+ id?: number;
1123
+ max_beladingen_per_layer?: number;
1124
+ max_customers_per_cart?: number;
1125
+ max_one_customer_per_layer?: boolean;
1126
+ max_party_share_per_layer_pct?: number;
1127
+ optimization_strategy?: string;
1128
+ own_cart_from_layers?: number;
1129
+ pick_time_mode?: string;
1130
+ plants_per_day?: number;
1131
+ plants_per_hour?: number;
1132
+ require_same_carrier?: boolean;
1133
+ require_same_crate_type?: boolean;
1134
+ require_same_delivery_date?: boolean;
1135
+ require_same_delivery_location?: boolean;
1136
+ updated_at?: string;
1137
+ updated_by?: string | null;
1138
+ };
1139
+ Update: {
1140
+ allow_editing_after_pickstation_send?: boolean;
1141
+ buffer_grouping_mode?: string;
1142
+ combine_floriday_orders?: boolean;
1143
+ combine_floriday_orders_window?: string;
1144
+ combine_orders_scope?: string;
1145
+ default_workers?: number;
1146
+ id?: number;
1147
+ max_beladingen_per_layer?: number;
1148
+ max_customers_per_cart?: number;
1149
+ max_one_customer_per_layer?: boolean;
1150
+ max_party_share_per_layer_pct?: number;
1151
+ optimization_strategy?: string;
1152
+ own_cart_from_layers?: number;
1153
+ pick_time_mode?: string;
1154
+ plants_per_day?: number;
1155
+ plants_per_hour?: number;
1156
+ require_same_carrier?: boolean;
1157
+ require_same_crate_type?: boolean;
1158
+ require_same_delivery_date?: boolean;
1159
+ require_same_delivery_location?: boolean;
1160
+ updated_at?: string;
1161
+ updated_by?: string | null;
1162
+ };
1163
+ Relationships: [];
1164
+ };
871
1165
  cart_replan_queue: {
872
1166
  Row: {
873
1167
  attempts: number;
@@ -898,6 +1192,39 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
898
1192
  referencedColumns: ["id"];
899
1193
  }];
900
1194
  };
1195
+ cart_types: {
1196
+ Row: {
1197
+ created_at: string;
1198
+ id: string;
1199
+ is_default: boolean;
1200
+ layer_length_cm: number;
1201
+ layer_width_cm: number;
1202
+ layers_per_cart: number;
1203
+ name: string;
1204
+ updated_at: string;
1205
+ };
1206
+ Insert: {
1207
+ created_at?: string;
1208
+ id?: string;
1209
+ is_default?: boolean;
1210
+ layer_length_cm: number;
1211
+ layer_width_cm: number;
1212
+ layers_per_cart?: number;
1213
+ name: string;
1214
+ updated_at?: string;
1215
+ };
1216
+ Update: {
1217
+ created_at?: string;
1218
+ id?: string;
1219
+ is_default?: boolean;
1220
+ layer_length_cm?: number;
1221
+ layer_width_cm?: number;
1222
+ layers_per_cart?: number;
1223
+ name?: string;
1224
+ updated_at?: string;
1225
+ };
1226
+ Relationships: [];
1227
+ };
901
1228
  collections: {
902
1229
  Row: {
903
1230
  created_at: string;
@@ -922,6 +1249,36 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
922
1249
  };
923
1250
  Relationships: [];
924
1251
  };
1252
+ crate_types: {
1253
+ Row: {
1254
+ created_at: string;
1255
+ id: string;
1256
+ length_cm: number;
1257
+ name: string;
1258
+ plants_per_crate: number;
1259
+ updated_at: string;
1260
+ width_cm: number;
1261
+ };
1262
+ Insert: {
1263
+ created_at?: string;
1264
+ id?: string;
1265
+ length_cm: number;
1266
+ name: string;
1267
+ plants_per_crate?: number;
1268
+ updated_at?: string;
1269
+ width_cm: number;
1270
+ };
1271
+ Update: {
1272
+ created_at?: string;
1273
+ id?: string;
1274
+ length_cm?: number;
1275
+ name?: string;
1276
+ plants_per_crate?: number;
1277
+ updated_at?: string;
1278
+ width_cm?: number;
1279
+ };
1280
+ Relationships: [];
1281
+ };
925
1282
  customer_audit_log: {
926
1283
  Row: {
927
1284
  action: string;
@@ -3247,127 +3604,28 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
3247
3604
  referencedColumns: ["id"];
3248
3605
  }];
3249
3606
  };
3250
- floriday_agreement_calloffs_cache: {
3607
+ floriday_auction_letters_cache: {
3251
3608
  Row: {
3252
- agreement_id: string | null;
3609
+ auction_letter_code: string;
3610
+ clock_supply_id: string;
3253
3611
  connection_id: string;
3254
- data: import("./types").Json;
3255
- delivery_date: string | null;
3612
+ content_type: string;
3256
3613
  fetched_at: string;
3257
- floriday_id: string;
3258
3614
  id: string;
3259
- is_deleted: boolean;
3260
- sequence_number: number;
3261
- status: string | null;
3262
- updated_at: string;
3615
+ storage_path: string;
3263
3616
  };
3264
3617
  Insert: {
3265
- agreement_id?: string | null;
3618
+ auction_letter_code: string;
3619
+ clock_supply_id: string;
3266
3620
  connection_id: string;
3267
- data?: import("./types").Json;
3268
- delivery_date?: string | null;
3621
+ content_type?: string;
3269
3622
  fetched_at?: string;
3270
- floriday_id: string;
3271
3623
  id?: string;
3272
- is_deleted?: boolean;
3273
- sequence_number?: number;
3274
- status?: string | null;
3275
- updated_at?: string;
3624
+ storage_path: string;
3276
3625
  };
3277
3626
  Update: {
3278
- agreement_id?: string | null;
3279
- connection_id?: string;
3280
- data?: import("./types").Json;
3281
- delivery_date?: string | null;
3282
- fetched_at?: string;
3283
- floriday_id?: string;
3284
- id?: string;
3285
- is_deleted?: boolean;
3286
- sequence_number?: number;
3287
- status?: string | null;
3288
- updated_at?: string;
3289
- };
3290
- Relationships: [{
3291
- foreignKeyName: "floriday_agreement_calloffs_cache_connection_id_fkey";
3292
- columns: ["connection_id"];
3293
- isOneToOne: false;
3294
- referencedRelation: "floriday_connections";
3295
- referencedColumns: ["id"];
3296
- }];
3297
- };
3298
- floriday_agreements_cache: {
3299
- Row: {
3300
- buyer_organization_id: string | null;
3301
- connection_id: string;
3302
- data: import("./types").Json;
3303
- fetched_at: string;
3304
- floriday_id: string;
3305
- id: string;
3306
- is_deleted: boolean;
3307
- sequence_number: number;
3308
- status: string | null;
3309
- updated_at: string;
3310
- valid_from: string | null;
3311
- valid_until: string | null;
3312
- };
3313
- Insert: {
3314
- buyer_organization_id?: string | null;
3315
- connection_id: string;
3316
- data?: import("./types").Json;
3317
- fetched_at?: string;
3318
- floriday_id: string;
3319
- id?: string;
3320
- is_deleted?: boolean;
3321
- sequence_number?: number;
3322
- status?: string | null;
3323
- updated_at?: string;
3324
- valid_from?: string | null;
3325
- valid_until?: string | null;
3326
- };
3327
- Update: {
3328
- buyer_organization_id?: string | null;
3329
- connection_id?: string;
3330
- data?: import("./types").Json;
3331
- fetched_at?: string;
3332
- floriday_id?: string;
3333
- id?: string;
3334
- is_deleted?: boolean;
3335
- sequence_number?: number;
3336
- status?: string | null;
3337
- updated_at?: string;
3338
- valid_from?: string | null;
3339
- valid_until?: string | null;
3340
- };
3341
- Relationships: [{
3342
- foreignKeyName: "floriday_agreements_cache_connection_id_fkey";
3343
- columns: ["connection_id"];
3344
- isOneToOne: false;
3345
- referencedRelation: "floriday_connections";
3346
- referencedColumns: ["id"];
3347
- }];
3348
- };
3349
- floriday_auction_letters_cache: {
3350
- Row: {
3351
- auction_letter_code: string;
3352
- clock_supply_id: string;
3353
- connection_id: string;
3354
- content_type: string;
3355
- fetched_at: string;
3356
- id: string;
3357
- storage_path: string;
3358
- };
3359
- Insert: {
3360
- auction_letter_code: string;
3361
- clock_supply_id: string;
3362
- connection_id: string;
3363
- content_type?: string;
3364
- fetched_at?: string;
3365
- id?: string;
3366
- storage_path: string;
3367
- };
3368
- Update: {
3369
- auction_letter_code?: string;
3370
- clock_supply_id?: string;
3627
+ auction_letter_code?: string;
3628
+ clock_supply_id?: string;
3371
3629
  connection_id?: string;
3372
3630
  content_type?: string;
3373
3631
  fetched_at?: string;
@@ -3844,6 +4102,27 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
3844
4102
  referencedColumns: ["id"];
3845
4103
  }];
3846
4104
  };
4105
+ floriday_continuous_stock_cache: {
4106
+ Row: {
4107
+ connection_id: string;
4108
+ fetched_at: string;
4109
+ number_of_pieces: number;
4110
+ trade_item_id: string;
4111
+ };
4112
+ Insert: {
4113
+ connection_id: string;
4114
+ fetched_at?: string;
4115
+ number_of_pieces?: number;
4116
+ trade_item_id: string;
4117
+ };
4118
+ Update: {
4119
+ connection_id?: string;
4120
+ fetched_at?: string;
4121
+ number_of_pieces?: number;
4122
+ trade_item_id?: string;
4123
+ };
4124
+ Relationships: [];
4125
+ };
3847
4126
  floriday_continuous_stock_queue: {
3848
4127
  Row: {
3849
4128
  attempts: number;
@@ -4619,6 +4898,8 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
4619
4898
  Row: {
4620
4899
  buyer_organization_id: string | null;
4621
4900
  connection_id: string;
4901
+ controlled_at: string | null;
4902
+ controlled_by: string | null;
4622
4903
  created_at: string;
4623
4904
  data: import("./types").Json;
4624
4905
  floriday_id: string;
@@ -4630,6 +4911,8 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
4630
4911
  Insert: {
4631
4912
  buyer_organization_id?: string | null;
4632
4913
  connection_id: string;
4914
+ controlled_at?: string | null;
4915
+ controlled_by?: string | null;
4633
4916
  created_at?: string;
4634
4917
  data: import("./types").Json;
4635
4918
  floriday_id: string;
@@ -4641,6 +4924,8 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
4641
4924
  Update: {
4642
4925
  buyer_organization_id?: string | null;
4643
4926
  connection_id?: string;
4927
+ controlled_at?: string | null;
4928
+ controlled_by?: string | null;
4644
4929
  created_at?: string;
4645
4930
  data?: import("./types").Json;
4646
4931
  floriday_id?: string;
@@ -4822,6 +5107,45 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
4822
5107
  referencedColumns: ["id"];
4823
5108
  }];
4824
5109
  };
5110
+ floriday_trade_settings_customers_cache: {
5111
+ Row: {
5112
+ connection_id: string;
5113
+ data: import("./types").Json;
5114
+ fetched_at: string;
5115
+ floriday_id: string;
5116
+ id: string;
5117
+ is_deleted: boolean;
5118
+ sequence_number: number;
5119
+ updated_at: string;
5120
+ };
5121
+ Insert: {
5122
+ connection_id: string;
5123
+ data: import("./types").Json;
5124
+ fetched_at?: string;
5125
+ floriday_id: string;
5126
+ id?: string;
5127
+ is_deleted?: boolean;
5128
+ sequence_number?: number;
5129
+ updated_at?: string;
5130
+ };
5131
+ Update: {
5132
+ connection_id?: string;
5133
+ data?: import("./types").Json;
5134
+ fetched_at?: string;
5135
+ floriday_id?: string;
5136
+ id?: string;
5137
+ is_deleted?: boolean;
5138
+ sequence_number?: number;
5139
+ updated_at?: string;
5140
+ };
5141
+ Relationships: [{
5142
+ foreignKeyName: "floriday_trade_settings_customers_cache_connection_id_fkey";
5143
+ columns: ["connection_id"];
5144
+ isOneToOne: false;
5145
+ referencedRelation: "floriday_connections";
5146
+ referencedColumns: ["id"];
5147
+ }];
5148
+ };
4825
5149
  floriday_trips_cache: {
4826
5150
  Row: {
4827
5151
  carrier_organization_id: string | null;
@@ -4870,6 +5194,27 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
4870
5194
  referencedColumns: ["id"];
4871
5195
  }];
4872
5196
  };
5197
+ floriday_vbn_required_characteristics: {
5198
+ Row: {
5199
+ required_codes: string[];
5200
+ updated_at: string;
5201
+ updated_by: string | null;
5202
+ vbn_code: string;
5203
+ };
5204
+ Insert: {
5205
+ required_codes?: string[];
5206
+ updated_at?: string;
5207
+ updated_by?: string | null;
5208
+ vbn_code: string;
5209
+ };
5210
+ Update: {
5211
+ required_codes?: string[];
5212
+ updated_at?: string;
5213
+ updated_by?: string | null;
5214
+ vbn_code?: string;
5215
+ };
5216
+ Relationships: [];
5217
+ };
4873
5218
  floriday_warehouses_cache: {
4874
5219
  Row: {
4875
5220
  connection_id: string;
@@ -5572,115 +5917,394 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
5572
5917
  };
5573
5918
  Relationships: [];
5574
5919
  };
5575
- mailbox_messages: {
5920
+ logistics_capacity_events: {
5576
5921
  Row: {
5577
- body_html: string | null;
5578
- body_text: string | null;
5579
- connection_id: string | null;
5922
+ available_carts: number;
5580
5923
  created_at: string;
5581
- error_message: string | null;
5582
- external_id: string | null;
5583
- from_email: string | null;
5584
- from_name: string | null;
5585
5924
  id: string;
5586
- message_id: string | null;
5587
- profile_id: string | null;
5588
- raw_size: number | null;
5589
- received_at: string | null;
5925
+ measures: import("./types").Json;
5926
+ note: string | null;
5927
+ outcome: string;
5928
+ required_carts: number;
5929
+ reserve_minutes: number;
5930
+ shortage_carts: number;
5590
5931
  status: string;
5591
- subject: string | null;
5592
- uid: number | null;
5593
- updated_at: string;
5932
+ user_id: string;
5594
5933
  };
5595
5934
  Insert: {
5596
- body_html?: string | null;
5597
- body_text?: string | null;
5598
- connection_id?: string | null;
5935
+ available_carts?: number;
5599
5936
  created_at?: string;
5600
- error_message?: string | null;
5601
- external_id?: string | null;
5602
- from_email?: string | null;
5603
- from_name?: string | null;
5604
5937
  id?: string;
5605
- message_id?: string | null;
5606
- profile_id?: string | null;
5607
- raw_size?: number | null;
5608
- received_at?: string | null;
5609
- status?: string;
5610
- subject?: string | null;
5611
- uid?: number | null;
5612
- updated_at?: string;
5938
+ measures?: import("./types").Json;
5939
+ note?: string | null;
5940
+ outcome?: string;
5941
+ required_carts?: number;
5942
+ reserve_minutes?: number;
5943
+ shortage_carts?: number;
5944
+ status: string;
5945
+ user_id: string;
5613
5946
  };
5614
5947
  Update: {
5615
- body_html?: string | null;
5616
- body_text?: string | null;
5617
- connection_id?: string | null;
5948
+ available_carts?: number;
5618
5949
  created_at?: string;
5619
- error_message?: string | null;
5620
- external_id?: string | null;
5621
- from_email?: string | null;
5622
- from_name?: string | null;
5623
5950
  id?: string;
5624
- message_id?: string | null;
5625
- profile_id?: string | null;
5626
- raw_size?: number | null;
5627
- received_at?: string | null;
5951
+ measures?: import("./types").Json;
5952
+ note?: string | null;
5953
+ outcome?: string;
5954
+ required_carts?: number;
5955
+ reserve_minutes?: number;
5956
+ shortage_carts?: number;
5628
5957
  status?: string;
5629
- subject?: string | null;
5630
- uid?: number | null;
5631
- updated_at?: string;
5958
+ user_id?: string;
5632
5959
  };
5633
- Relationships: [{
5634
- foreignKeyName: "mailbox_messages_connection_id_fkey";
5635
- columns: ["connection_id"];
5636
- isOneToOne: false;
5637
- referencedRelation: "email_auth_connections";
5638
- referencedColumns: ["id"];
5639
- }, {
5640
- foreignKeyName: "mailbox_messages_connection_id_fkey";
5641
- columns: ["connection_id"];
5642
- isOneToOne: false;
5643
- referencedRelation: "email_auth_connections_safe";
5644
- referencedColumns: ["id"];
5645
- }, {
5646
- foreignKeyName: "mailbox_messages_profile_id_fkey";
5647
- columns: ["profile_id"];
5648
- isOneToOne: false;
5649
- referencedRelation: "imap_profiles";
5650
- referencedColumns: ["id"];
5651
- }];
5960
+ Relationships: [];
5652
5961
  };
5653
- mailbox_order_proposals: {
5962
+ logistics_capacity_settings: {
5654
5963
  Row: {
5655
- confidence: number | null;
5656
5964
  created_at: string;
5657
- created_order_id: string | null;
5658
- delivery_date: string | null;
5659
- id: string;
5660
- matched_customer_id: string | null;
5661
- message_id: string;
5662
- notes: string | null;
5663
- order_number: string | null;
5664
- parsed_payload: import("./types").Json | null;
5665
- reviewed_at: string | null;
5666
- reviewed_by: string | null;
5667
- status: string;
5965
+ settings: import("./types").Json;
5668
5966
  updated_at: string;
5967
+ user_id: string;
5669
5968
  };
5670
5969
  Insert: {
5671
- confidence?: number | null;
5672
5970
  created_at?: string;
5673
- created_order_id?: string | null;
5674
- delivery_date?: string | null;
5675
- id?: string;
5676
- matched_customer_id?: string | null;
5677
- message_id: string;
5678
- notes?: string | null;
5679
- order_number?: string | null;
5680
- parsed_payload?: import("./types").Json | null;
5681
- reviewed_at?: string | null;
5682
- reviewed_by?: string | null;
5683
- status?: string;
5971
+ settings?: import("./types").Json;
5972
+ updated_at?: string;
5973
+ user_id: string;
5974
+ };
5975
+ Update: {
5976
+ created_at?: string;
5977
+ settings?: import("./types").Json;
5978
+ updated_at?: string;
5979
+ user_id?: string;
5980
+ };
5981
+ Relationships: [];
5982
+ };
5983
+ logistics_decisions: {
5984
+ Row: {
5985
+ created_at: string;
5986
+ explanation: string | null;
5987
+ id: string;
5988
+ input_snapshot: import("./types").Json;
5989
+ result: import("./types").Json;
5990
+ slot: string;
5991
+ strategy_id: string | null;
5992
+ subject_id: string;
5993
+ subject_type: string;
5994
+ user_id: string;
5995
+ };
5996
+ Insert: {
5997
+ created_at?: string;
5998
+ explanation?: string | null;
5999
+ id?: string;
6000
+ input_snapshot?: import("./types").Json;
6001
+ result?: import("./types").Json;
6002
+ slot: string;
6003
+ strategy_id?: string | null;
6004
+ subject_id: string;
6005
+ subject_type: string;
6006
+ user_id: string;
6007
+ };
6008
+ Update: {
6009
+ created_at?: string;
6010
+ explanation?: string | null;
6011
+ id?: string;
6012
+ input_snapshot?: import("./types").Json;
6013
+ result?: import("./types").Json;
6014
+ slot?: string;
6015
+ strategy_id?: string | null;
6016
+ subject_id?: string;
6017
+ subject_type?: string;
6018
+ user_id?: string;
6019
+ };
6020
+ Relationships: [{
6021
+ foreignKeyName: "logistics_decisions_strategy_id_fkey";
6022
+ columns: ["strategy_id"];
6023
+ isOneToOne: false;
6024
+ referencedRelation: "logistics_strategies";
6025
+ referencedColumns: ["id"];
6026
+ }];
6027
+ };
6028
+ logistics_formulas: {
6029
+ Row: {
6030
+ created_at: string;
6031
+ expression: string;
6032
+ id: string;
6033
+ notes: string | null;
6034
+ slot: string;
6035
+ strategy_id: string;
6036
+ updated_at: string;
6037
+ user_id: string;
6038
+ version: number;
6039
+ };
6040
+ Insert: {
6041
+ created_at?: string;
6042
+ expression?: string;
6043
+ id?: string;
6044
+ notes?: string | null;
6045
+ slot: string;
6046
+ strategy_id: string;
6047
+ updated_at?: string;
6048
+ user_id: string;
6049
+ version?: number;
6050
+ };
6051
+ Update: {
6052
+ created_at?: string;
6053
+ expression?: string;
6054
+ id?: string;
6055
+ notes?: string | null;
6056
+ slot?: string;
6057
+ strategy_id?: string;
6058
+ updated_at?: string;
6059
+ user_id?: string;
6060
+ version?: number;
6061
+ };
6062
+ Relationships: [{
6063
+ foreignKeyName: "logistics_formulas_strategy_id_fkey";
6064
+ columns: ["strategy_id"];
6065
+ isOneToOne: false;
6066
+ referencedRelation: "logistics_strategies";
6067
+ referencedColumns: ["id"];
6068
+ }];
6069
+ };
6070
+ logistics_strategies: {
6071
+ Row: {
6072
+ color: string;
6073
+ created_at: string;
6074
+ description: string | null;
6075
+ id: string;
6076
+ is_active: boolean;
6077
+ name: string;
6078
+ priority: number;
6079
+ updated_at: string;
6080
+ updated_by: string | null;
6081
+ user_id: string;
6082
+ version: number;
6083
+ };
6084
+ Insert: {
6085
+ color?: string;
6086
+ created_at?: string;
6087
+ description?: string | null;
6088
+ id?: string;
6089
+ is_active?: boolean;
6090
+ name: string;
6091
+ priority?: number;
6092
+ updated_at?: string;
6093
+ updated_by?: string | null;
6094
+ user_id: string;
6095
+ version?: number;
6096
+ };
6097
+ Update: {
6098
+ color?: string;
6099
+ created_at?: string;
6100
+ description?: string | null;
6101
+ id?: string;
6102
+ is_active?: boolean;
6103
+ name?: string;
6104
+ priority?: number;
6105
+ updated_at?: string;
6106
+ updated_by?: string | null;
6107
+ user_id?: string;
6108
+ version?: number;
6109
+ };
6110
+ Relationships: [];
6111
+ };
6112
+ logistics_strategy_schedules: {
6113
+ Row: {
6114
+ condition_expression: string | null;
6115
+ created_at: string;
6116
+ end_date: string | null;
6117
+ id: string;
6118
+ is_enabled: boolean;
6119
+ priority: number;
6120
+ rule_type: string;
6121
+ start_date: string | null;
6122
+ strategy_id: string;
6123
+ updated_at: string;
6124
+ user_id: string;
6125
+ };
6126
+ Insert: {
6127
+ condition_expression?: string | null;
6128
+ created_at?: string;
6129
+ end_date?: string | null;
6130
+ id?: string;
6131
+ is_enabled?: boolean;
6132
+ priority?: number;
6133
+ rule_type: string;
6134
+ start_date?: string | null;
6135
+ strategy_id: string;
6136
+ updated_at?: string;
6137
+ user_id: string;
6138
+ };
6139
+ Update: {
6140
+ condition_expression?: string | null;
6141
+ created_at?: string;
6142
+ end_date?: string | null;
6143
+ id?: string;
6144
+ is_enabled?: boolean;
6145
+ priority?: number;
6146
+ rule_type?: string;
6147
+ start_date?: string | null;
6148
+ strategy_id?: string;
6149
+ updated_at?: string;
6150
+ user_id?: string;
6151
+ };
6152
+ Relationships: [{
6153
+ foreignKeyName: "logistics_strategy_schedules_strategy_id_fkey";
6154
+ columns: ["strategy_id"];
6155
+ isOneToOne: false;
6156
+ referencedRelation: "logistics_strategies";
6157
+ referencedColumns: ["id"];
6158
+ }];
6159
+ };
6160
+ logistics_variables: {
6161
+ Row: {
6162
+ created_at: string;
6163
+ default_value: string | null;
6164
+ description: string | null;
6165
+ id: string;
6166
+ is_builtin: boolean;
6167
+ key: string;
6168
+ label: string;
6169
+ updated_at: string;
6170
+ user_id: string;
6171
+ value_type: string;
6172
+ };
6173
+ Insert: {
6174
+ created_at?: string;
6175
+ default_value?: string | null;
6176
+ description?: string | null;
6177
+ id?: string;
6178
+ is_builtin?: boolean;
6179
+ key: string;
6180
+ label: string;
6181
+ updated_at?: string;
6182
+ user_id: string;
6183
+ value_type: string;
6184
+ };
6185
+ Update: {
6186
+ created_at?: string;
6187
+ default_value?: string | null;
6188
+ description?: string | null;
6189
+ id?: string;
6190
+ is_builtin?: boolean;
6191
+ key?: string;
6192
+ label?: string;
6193
+ updated_at?: string;
6194
+ user_id?: string;
6195
+ value_type?: string;
6196
+ };
6197
+ Relationships: [];
6198
+ };
6199
+ mailbox_messages: {
6200
+ Row: {
6201
+ body_html: string | null;
6202
+ body_text: string | null;
6203
+ connection_id: string | null;
6204
+ created_at: string;
6205
+ error_message: string | null;
6206
+ external_id: string | null;
6207
+ from_email: string | null;
6208
+ from_name: string | null;
6209
+ id: string;
6210
+ message_id: string | null;
6211
+ profile_id: string | null;
6212
+ raw_size: number | null;
6213
+ received_at: string | null;
6214
+ status: string;
6215
+ subject: string | null;
6216
+ uid: number | null;
6217
+ updated_at: string;
6218
+ };
6219
+ Insert: {
6220
+ body_html?: string | null;
6221
+ body_text?: string | null;
6222
+ connection_id?: string | null;
6223
+ created_at?: string;
6224
+ error_message?: string | null;
6225
+ external_id?: string | null;
6226
+ from_email?: string | null;
6227
+ from_name?: string | null;
6228
+ id?: string;
6229
+ message_id?: string | null;
6230
+ profile_id?: string | null;
6231
+ raw_size?: number | null;
6232
+ received_at?: string | null;
6233
+ status?: string;
6234
+ subject?: string | null;
6235
+ uid?: number | null;
6236
+ updated_at?: string;
6237
+ };
6238
+ Update: {
6239
+ body_html?: string | null;
6240
+ body_text?: string | null;
6241
+ connection_id?: string | null;
6242
+ created_at?: string;
6243
+ error_message?: string | null;
6244
+ external_id?: string | null;
6245
+ from_email?: string | null;
6246
+ from_name?: string | null;
6247
+ id?: string;
6248
+ message_id?: string | null;
6249
+ profile_id?: string | null;
6250
+ raw_size?: number | null;
6251
+ received_at?: string | null;
6252
+ status?: string;
6253
+ subject?: string | null;
6254
+ uid?: number | null;
6255
+ updated_at?: string;
6256
+ };
6257
+ Relationships: [{
6258
+ foreignKeyName: "mailbox_messages_connection_id_fkey";
6259
+ columns: ["connection_id"];
6260
+ isOneToOne: false;
6261
+ referencedRelation: "email_auth_connections";
6262
+ referencedColumns: ["id"];
6263
+ }, {
6264
+ foreignKeyName: "mailbox_messages_connection_id_fkey";
6265
+ columns: ["connection_id"];
6266
+ isOneToOne: false;
6267
+ referencedRelation: "email_auth_connections_safe";
6268
+ referencedColumns: ["id"];
6269
+ }, {
6270
+ foreignKeyName: "mailbox_messages_profile_id_fkey";
6271
+ columns: ["profile_id"];
6272
+ isOneToOne: false;
6273
+ referencedRelation: "imap_profiles";
6274
+ referencedColumns: ["id"];
6275
+ }];
6276
+ };
6277
+ mailbox_order_proposals: {
6278
+ Row: {
6279
+ confidence: number | null;
6280
+ created_at: string;
6281
+ created_order_id: string | null;
6282
+ delivery_date: string | null;
6283
+ id: string;
6284
+ matched_customer_id: string | null;
6285
+ message_id: string;
6286
+ notes: string | null;
6287
+ order_number: string | null;
6288
+ parsed_payload: import("./types").Json | null;
6289
+ reviewed_at: string | null;
6290
+ reviewed_by: string | null;
6291
+ status: string;
6292
+ updated_at: string;
6293
+ };
6294
+ Insert: {
6295
+ confidence?: number | null;
6296
+ created_at?: string;
6297
+ created_order_id?: string | null;
6298
+ delivery_date?: string | null;
6299
+ id?: string;
6300
+ matched_customer_id?: string | null;
6301
+ message_id: string;
6302
+ notes?: string | null;
6303
+ order_number?: string | null;
6304
+ parsed_payload?: import("./types").Json | null;
6305
+ reviewed_at?: string | null;
6306
+ reviewed_by?: string | null;
6307
+ status?: string;
5684
6308
  updated_at?: string;
5685
6309
  };
5686
6310
  Update: {
@@ -5967,39 +6591,60 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
5967
6591
  };
5968
6592
  manufacture_products: {
5969
6593
  Row: {
6594
+ aantal_te_produceren: number;
5970
6595
  created_at: string;
5971
6596
  description: string | null;
5972
6597
  id: string;
5973
6598
  is_active: boolean;
6599
+ location_id: string | null;
5974
6600
  name: string;
6601
+ partij_nummer: string | null;
6602
+ photos: import("./types").Json;
5975
6603
  produced_stock: number;
5976
6604
  product_code: string;
5977
6605
  tenant_id: string;
6606
+ unit: string;
5978
6607
  updated_at: string;
5979
6608
  };
5980
6609
  Insert: {
6610
+ aantal_te_produceren?: number;
5981
6611
  created_at?: string;
5982
6612
  description?: string | null;
5983
6613
  id?: string;
5984
6614
  is_active?: boolean;
6615
+ location_id?: string | null;
5985
6616
  name: string;
6617
+ partij_nummer?: string | null;
6618
+ photos?: import("./types").Json;
5986
6619
  produced_stock?: number;
5987
6620
  product_code: string;
5988
6621
  tenant_id: string;
6622
+ unit?: string;
5989
6623
  updated_at?: string;
5990
6624
  };
5991
6625
  Update: {
6626
+ aantal_te_produceren?: number;
5992
6627
  created_at?: string;
5993
6628
  description?: string | null;
5994
6629
  id?: string;
5995
6630
  is_active?: boolean;
6631
+ location_id?: string | null;
5996
6632
  name?: string;
6633
+ partij_nummer?: string | null;
6634
+ photos?: import("./types").Json;
5997
6635
  produced_stock?: number;
5998
6636
  product_code?: string;
5999
6637
  tenant_id?: string;
6638
+ unit?: string;
6000
6639
  updated_at?: string;
6001
6640
  };
6002
- Relationships: [];
6641
+ Relationships: [{
6642
+ foreignKeyName: "manufacture_products_location_id_fkey";
6643
+ columns: ["location_id"];
6644
+ isOneToOne: false;
6645
+ referencedRelation: "locations";
6646
+ referencedColumns: ["id"];
6647
+ }];
6003
6648
  };
6004
6649
  monteurs: {
6005
6650
  Row: {
@@ -6730,6 +7375,42 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6730
7375
  };
6731
7376
  Relationships: [];
6732
7377
  };
7378
+ order_buffers: {
7379
+ Row: {
7380
+ buffer_key: string;
7381
+ created_at: string;
7382
+ customer_id: string | null;
7383
+ grouping_mode: string;
7384
+ id: string;
7385
+ pickup_date: string | null;
7386
+ pickup_location: string | null;
7387
+ plan_locked_at: string | null;
7388
+ updated_at: string;
7389
+ };
7390
+ Insert: {
7391
+ buffer_key: string;
7392
+ created_at?: string;
7393
+ customer_id?: string | null;
7394
+ grouping_mode: string;
7395
+ id?: string;
7396
+ pickup_date?: string | null;
7397
+ pickup_location?: string | null;
7398
+ plan_locked_at?: string | null;
7399
+ updated_at?: string;
7400
+ };
7401
+ Update: {
7402
+ buffer_key?: string;
7403
+ created_at?: string;
7404
+ customer_id?: string | null;
7405
+ grouping_mode?: string;
7406
+ id?: string;
7407
+ pickup_date?: string | null;
7408
+ pickup_location?: string | null;
7409
+ plan_locked_at?: string | null;
7410
+ updated_at?: string;
7411
+ };
7412
+ Relationships: [];
7413
+ };
6733
7414
  order_cart_items: {
6734
7415
  Row: {
6735
7416
  cart_id: string;
@@ -6796,6 +7477,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6796
7477
  order_carts: {
6797
7478
  Row: {
6798
7479
  algorithm_version: number;
7480
+ buffer_id: string | null;
6799
7481
  cart_number: number;
6800
7482
  created_at: string;
6801
7483
  id: string;
@@ -6803,13 +7485,14 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6803
7485
  is_complete: boolean;
6804
7486
  notes: string | null;
6805
7487
  occupancy_pct: number;
6806
- order_id: string;
7488
+ order_id: string | null;
6807
7489
  source: string;
6808
7490
  total_layers_used: number;
6809
7491
  updated_at: string;
6810
7492
  };
6811
7493
  Insert: {
6812
7494
  algorithm_version?: number;
7495
+ buffer_id?: string | null;
6813
7496
  cart_number: number;
6814
7497
  created_at?: string;
6815
7498
  id?: string;
@@ -6817,13 +7500,14 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6817
7500
  is_complete?: boolean;
6818
7501
  notes?: string | null;
6819
7502
  occupancy_pct?: number;
6820
- order_id: string;
7503
+ order_id?: string | null;
6821
7504
  source?: string;
6822
7505
  total_layers_used?: number;
6823
7506
  updated_at?: string;
6824
7507
  };
6825
7508
  Update: {
6826
7509
  algorithm_version?: number;
7510
+ buffer_id?: string | null;
6827
7511
  cart_number?: number;
6828
7512
  created_at?: string;
6829
7513
  id?: string;
@@ -6831,12 +7515,18 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6831
7515
  is_complete?: boolean;
6832
7516
  notes?: string | null;
6833
7517
  occupancy_pct?: number;
6834
- order_id?: string;
7518
+ order_id?: string | null;
6835
7519
  source?: string;
6836
7520
  total_layers_used?: number;
6837
7521
  updated_at?: string;
6838
7522
  };
6839
7523
  Relationships: [{
7524
+ foreignKeyName: "order_carts_buffer_id_fkey";
7525
+ columns: ["buffer_id"];
7526
+ isOneToOne: false;
7527
+ referencedRelation: "order_buffers";
7528
+ referencedColumns: ["id"];
7529
+ }, {
6840
7530
  foreignKeyName: "order_carts_order_id_fkey";
6841
7531
  columns: ["order_id"];
6842
7532
  isOneToOne: false;
@@ -6973,15 +7663,117 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6973
7663
  };
6974
7664
  Relationships: [];
6975
7665
  };
7666
+ order_shipment_items: {
7667
+ Row: {
7668
+ created_at: string;
7669
+ id: string;
7670
+ order_item_id: string;
7671
+ product_id: string | null;
7672
+ product_name: string;
7673
+ quantity: number;
7674
+ shipment_id: string;
7675
+ updated_at: string;
7676
+ };
7677
+ Insert: {
7678
+ created_at?: string;
7679
+ id?: string;
7680
+ order_item_id: string;
7681
+ product_id?: string | null;
7682
+ product_name: string;
7683
+ quantity: number;
7684
+ shipment_id: string;
7685
+ updated_at?: string;
7686
+ };
7687
+ Update: {
7688
+ created_at?: string;
7689
+ id?: string;
7690
+ order_item_id?: string;
7691
+ product_id?: string | null;
7692
+ product_name?: string;
7693
+ quantity?: number;
7694
+ shipment_id?: string;
7695
+ updated_at?: string;
7696
+ };
7697
+ Relationships: [{
7698
+ foreignKeyName: "order_shipment_items_order_item_id_fkey";
7699
+ columns: ["order_item_id"];
7700
+ isOneToOne: false;
7701
+ referencedRelation: "order_items";
7702
+ referencedColumns: ["id"];
7703
+ }, {
7704
+ foreignKeyName: "order_shipment_items_shipment_id_fkey";
7705
+ columns: ["shipment_id"];
7706
+ isOneToOne: false;
7707
+ referencedRelation: "order_shipments";
7708
+ referencedColumns: ["id"];
7709
+ }];
7710
+ };
7711
+ order_shipments: {
7712
+ Row: {
7713
+ carrier_id: string | null;
7714
+ created_at: string;
7715
+ delivery_date: string | null;
7716
+ delivery_location_id: string | null;
7717
+ id: string;
7718
+ notes: string | null;
7719
+ order_id: string;
7720
+ shipment_number: number;
7721
+ shipped_at: string | null;
7722
+ status: string;
7723
+ updated_at: string;
7724
+ };
7725
+ Insert: {
7726
+ carrier_id?: string | null;
7727
+ created_at?: string;
7728
+ delivery_date?: string | null;
7729
+ delivery_location_id?: string | null;
7730
+ id?: string;
7731
+ notes?: string | null;
7732
+ order_id: string;
7733
+ shipment_number: number;
7734
+ shipped_at?: string | null;
7735
+ status?: string;
7736
+ updated_at?: string;
7737
+ };
7738
+ Update: {
7739
+ carrier_id?: string | null;
7740
+ created_at?: string;
7741
+ delivery_date?: string | null;
7742
+ delivery_location_id?: string | null;
7743
+ id?: string;
7744
+ notes?: string | null;
7745
+ order_id?: string;
7746
+ shipment_number?: number;
7747
+ shipped_at?: string | null;
7748
+ status?: string;
7749
+ updated_at?: string;
7750
+ };
7751
+ Relationships: [{
7752
+ foreignKeyName: "order_shipments_carrier_id_fkey";
7753
+ columns: ["carrier_id"];
7754
+ isOneToOne: false;
7755
+ referencedRelation: "carriers";
7756
+ referencedColumns: ["id"];
7757
+ }, {
7758
+ foreignKeyName: "order_shipments_order_id_fkey";
7759
+ columns: ["order_id"];
7760
+ isOneToOne: false;
7761
+ referencedRelation: "orders";
7762
+ referencedColumns: ["id"];
7763
+ }];
7764
+ };
6976
7765
  orders: {
6977
7766
  Row: {
7767
+ buffer_id: string | null;
6978
7768
  created_at: string;
6979
7769
  custom_fields: import("./types").Json;
6980
7770
  customer_id: string | null;
6981
7771
  customer_name: string;
6982
7772
  deleted_at: string | null;
6983
- delivery_date: string;
7773
+ delivery_date: string | null;
7774
+ floriday_sales_order_id: string | null;
6984
7775
  id: string;
7776
+ is_reservation: boolean;
6985
7777
  notes: string | null;
6986
7778
  order_date: string;
6987
7779
  order_number: string;
@@ -6993,13 +7785,16 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
6993
7785
  updated_at: string;
6994
7786
  };
6995
7787
  Insert: {
7788
+ buffer_id?: string | null;
6996
7789
  created_at?: string;
6997
7790
  custom_fields?: import("./types").Json;
6998
7791
  customer_id?: string | null;
6999
7792
  customer_name?: string;
7000
7793
  deleted_at?: string | null;
7001
- delivery_date: string;
7794
+ delivery_date?: string | null;
7795
+ floriday_sales_order_id?: string | null;
7002
7796
  id?: string;
7797
+ is_reservation?: boolean;
7003
7798
  notes?: string | null;
7004
7799
  order_date?: string;
7005
7800
  order_number: string;
@@ -7011,13 +7806,16 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7011
7806
  updated_at?: string;
7012
7807
  };
7013
7808
  Update: {
7809
+ buffer_id?: string | null;
7014
7810
  created_at?: string;
7015
7811
  custom_fields?: import("./types").Json;
7016
7812
  customer_id?: string | null;
7017
7813
  customer_name?: string;
7018
7814
  deleted_at?: string | null;
7019
- delivery_date?: string;
7815
+ delivery_date?: string | null;
7816
+ floriday_sales_order_id?: string | null;
7020
7817
  id?: string;
7818
+ is_reservation?: boolean;
7021
7819
  notes?: string | null;
7022
7820
  order_date?: string;
7023
7821
  order_number?: string;
@@ -7029,6 +7827,12 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7029
7827
  updated_at?: string;
7030
7828
  };
7031
7829
  Relationships: [{
7830
+ foreignKeyName: "orders_buffer_id_fkey";
7831
+ columns: ["buffer_id"];
7832
+ isOneToOne: false;
7833
+ referencedRelation: "order_buffers";
7834
+ referencedColumns: ["id"];
7835
+ }, {
7032
7836
  foreignKeyName: "orders_customer_id_fkey";
7033
7837
  columns: ["customer_id"];
7034
7838
  isOneToOne: false;
@@ -7159,6 +7963,66 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7159
7963
  };
7160
7964
  Relationships: [];
7161
7965
  };
7966
+ product_bom_items: {
7967
+ Row: {
7968
+ component_product_id: string | null;
7969
+ component_trade_item_floriday_id: string | null;
7970
+ created_at: string;
7971
+ id: string;
7972
+ notes: string | null;
7973
+ packing_configuration_id: string | null;
7974
+ parent_product_id: string | null;
7975
+ parent_trade_item_floriday_id: string | null;
7976
+ quantity: number;
7977
+ sort_order: number;
7978
+ tenant_id: string;
7979
+ unit: string;
7980
+ updated_at: string;
7981
+ };
7982
+ Insert: {
7983
+ component_product_id?: string | null;
7984
+ component_trade_item_floriday_id?: string | null;
7985
+ created_at?: string;
7986
+ id?: string;
7987
+ notes?: string | null;
7988
+ packing_configuration_id?: string | null;
7989
+ parent_product_id?: string | null;
7990
+ parent_trade_item_floriday_id?: string | null;
7991
+ quantity?: number;
7992
+ sort_order?: number;
7993
+ tenant_id: string;
7994
+ unit?: string;
7995
+ updated_at?: string;
7996
+ };
7997
+ Update: {
7998
+ component_product_id?: string | null;
7999
+ component_trade_item_floriday_id?: string | null;
8000
+ created_at?: string;
8001
+ id?: string;
8002
+ notes?: string | null;
8003
+ packing_configuration_id?: string | null;
8004
+ parent_product_id?: string | null;
8005
+ parent_trade_item_floriday_id?: string | null;
8006
+ quantity?: number;
8007
+ sort_order?: number;
8008
+ tenant_id?: string;
8009
+ unit?: string;
8010
+ updated_at?: string;
8011
+ };
8012
+ Relationships: [{
8013
+ foreignKeyName: "product_bom_items_component_product_id_fkey";
8014
+ columns: ["component_product_id"];
8015
+ isOneToOne: false;
8016
+ referencedRelation: "products";
8017
+ referencedColumns: ["id"];
8018
+ }, {
8019
+ foreignKeyName: "product_bom_items_parent_product_id_fkey";
8020
+ columns: ["parent_product_id"];
8021
+ isOneToOne: false;
8022
+ referencedRelation: "products";
8023
+ referencedColumns: ["id"];
8024
+ }];
8025
+ };
7162
8026
  product_categories: {
7163
8027
  Row: {
7164
8028
  color: string;
@@ -7264,6 +8128,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7264
8128
  id: string;
7265
8129
  product_group_id: string;
7266
8130
  quantity: number;
8131
+ sort_order: number;
7267
8132
  trade_item_id: string;
7268
8133
  };
7269
8134
  Insert: {
@@ -7271,6 +8136,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7271
8136
  id?: string;
7272
8137
  product_group_id: string;
7273
8138
  quantity?: number;
8139
+ sort_order?: number;
7274
8140
  trade_item_id: string;
7275
8141
  };
7276
8142
  Update: {
@@ -7278,56 +8144,173 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7278
8144
  id?: string;
7279
8145
  product_group_id?: string;
7280
8146
  quantity?: number;
8147
+ sort_order?: number;
7281
8148
  trade_item_id?: string;
7282
8149
  };
7283
8150
  Relationships: [{
7284
8151
  foreignKeyName: "product_group_items_product_group_id_fkey";
7285
8152
  columns: ["product_group_id"];
7286
8153
  isOneToOne: false;
7287
- referencedRelation: "product_groups";
8154
+ referencedRelation: "product_groups";
8155
+ referencedColumns: ["id"];
8156
+ }];
8157
+ };
8158
+ product_groups: {
8159
+ Row: {
8160
+ created_at: string;
8161
+ description: string | null;
8162
+ head_product_id: string | null;
8163
+ head_trade_item_floriday_id: string | null;
8164
+ id: string;
8165
+ is_active: boolean;
8166
+ name: string;
8167
+ tenant_id: string;
8168
+ updated_at: string;
8169
+ };
8170
+ Insert: {
8171
+ created_at?: string;
8172
+ description?: string | null;
8173
+ head_product_id?: string | null;
8174
+ head_trade_item_floriday_id?: string | null;
8175
+ id?: string;
8176
+ is_active?: boolean;
8177
+ name: string;
8178
+ tenant_id: string;
8179
+ updated_at?: string;
8180
+ };
8181
+ Update: {
8182
+ created_at?: string;
8183
+ description?: string | null;
8184
+ head_product_id?: string | null;
8185
+ head_trade_item_floriday_id?: string | null;
8186
+ id?: string;
8187
+ is_active?: boolean;
8188
+ name?: string;
8189
+ tenant_id?: string;
8190
+ updated_at?: string;
8191
+ };
8192
+ Relationships: [{
8193
+ foreignKeyName: "product_groups_head_product_id_fkey";
8194
+ columns: ["head_product_id"];
8195
+ isOneToOne: false;
8196
+ referencedRelation: "products";
8197
+ referencedColumns: ["id"];
8198
+ }];
8199
+ };
8200
+ product_load_settings: {
8201
+ Row: {
8202
+ created_at: string;
8203
+ id: string;
8204
+ is_package: boolean;
8205
+ label: string | null;
8206
+ layers_per_load_carrier: number | null;
8207
+ load_carrier: string | null;
8208
+ package_id: string | null;
8209
+ package_label: string | null;
8210
+ packages_per_layer: number | null;
8211
+ packing_configuration_id: string;
8212
+ product_id: string | null;
8213
+ tenant_id: string;
8214
+ trade_item_floriday_id: string | null;
8215
+ units_per_package: number | null;
8216
+ updated_at: string;
8217
+ };
8218
+ Insert: {
8219
+ created_at?: string;
8220
+ id?: string;
8221
+ is_package?: boolean;
8222
+ label?: string | null;
8223
+ layers_per_load_carrier?: number | null;
8224
+ load_carrier?: string | null;
8225
+ package_id?: string | null;
8226
+ package_label?: string | null;
8227
+ packages_per_layer?: number | null;
8228
+ packing_configuration_id?: string;
8229
+ product_id?: string | null;
8230
+ tenant_id: string;
8231
+ trade_item_floriday_id?: string | null;
8232
+ units_per_package?: number | null;
8233
+ updated_at?: string;
8234
+ };
8235
+ Update: {
8236
+ created_at?: string;
8237
+ id?: string;
8238
+ is_package?: boolean;
8239
+ label?: string | null;
8240
+ layers_per_load_carrier?: number | null;
8241
+ load_carrier?: string | null;
8242
+ package_id?: string | null;
8243
+ package_label?: string | null;
8244
+ packages_per_layer?: number | null;
8245
+ packing_configuration_id?: string;
8246
+ product_id?: string | null;
8247
+ tenant_id?: string;
8248
+ trade_item_floriday_id?: string | null;
8249
+ units_per_package?: number | null;
8250
+ updated_at?: string;
8251
+ };
8252
+ Relationships: [{
8253
+ foreignKeyName: "product_load_settings_package_id_fkey";
8254
+ columns: ["package_id"];
8255
+ isOneToOne: false;
8256
+ referencedRelation: "packages";
8257
+ referencedColumns: ["id"];
8258
+ }, {
8259
+ foreignKeyName: "product_load_settings_product_id_fkey";
8260
+ columns: ["product_id"];
8261
+ isOneToOne: false;
8262
+ referencedRelation: "products";
7288
8263
  referencedColumns: ["id"];
7289
8264
  }];
7290
8265
  };
7291
- product_groups: {
8266
+ product_merge_log: {
7292
8267
  Row: {
7293
- created_at: string;
7294
- description: string | null;
8268
+ canonical_product_id: string | null;
7295
8269
  id: string;
7296
- is_active: boolean;
7297
- name: string;
7298
- tenant_id: string;
7299
- updated_at: string;
8270
+ merged_at: string;
8271
+ merged_from_id: string;
8272
+ notes: string | null;
8273
+ snapshot: import("./types").Json;
8274
+ source_table: string;
8275
+ status: string;
7300
8276
  };
7301
8277
  Insert: {
7302
- created_at?: string;
7303
- description?: string | null;
8278
+ canonical_product_id?: string | null;
7304
8279
  id?: string;
7305
- is_active?: boolean;
7306
- name: string;
7307
- tenant_id: string;
7308
- updated_at?: string;
8280
+ merged_at?: string;
8281
+ merged_from_id: string;
8282
+ notes?: string | null;
8283
+ snapshot?: import("./types").Json;
8284
+ source_table: string;
8285
+ status?: string;
7309
8286
  };
7310
8287
  Update: {
7311
- created_at?: string;
7312
- description?: string | null;
8288
+ canonical_product_id?: string | null;
7313
8289
  id?: string;
7314
- is_active?: boolean;
7315
- name?: string;
7316
- tenant_id?: string;
7317
- updated_at?: string;
8290
+ merged_at?: string;
8291
+ merged_from_id?: string;
8292
+ notes?: string | null;
8293
+ snapshot?: import("./types").Json;
8294
+ source_table?: string;
8295
+ status?: string;
7318
8296
  };
7319
8297
  Relationships: [];
7320
8298
  };
7321
8299
  products: {
7322
8300
  Row: {
8301
+ article_number: string | null;
7323
8302
  barcode: string | null;
7324
8303
  batch: string;
7325
8304
  crates_per_layer: number;
7326
8305
  created_at: string;
7327
8306
  custom_fields: import("./types").Json;
8307
+ floriday_active: boolean;
8308
+ floriday_payload: import("./types").Json;
8309
+ floriday_trade_item_id: string | null;
7328
8310
  id: string;
7329
8311
  image_url: string | null;
7330
8312
  incoming_quantity: number;
8313
+ is_layer: boolean;
7331
8314
  layers_per_cart: number;
7332
8315
  location: string;
7333
8316
  min_quantity: number;
@@ -7340,17 +8323,24 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7340
8323
  trade_item_key: string | null;
7341
8324
  unit: string;
7342
8325
  updated_at: string;
8326
+ vat_code: string | null;
8327
+ vat_rate: number | null;
7343
8328
  weight: string | null;
7344
8329
  };
7345
8330
  Insert: {
8331
+ article_number?: string | null;
7346
8332
  barcode?: string | null;
7347
8333
  batch: string;
7348
8334
  crates_per_layer?: number;
7349
8335
  created_at?: string;
7350
8336
  custom_fields?: import("./types").Json;
8337
+ floriday_active?: boolean;
8338
+ floriday_payload?: import("./types").Json;
8339
+ floriday_trade_item_id?: string | null;
7351
8340
  id?: string;
7352
8341
  image_url?: string | null;
7353
8342
  incoming_quantity?: number;
8343
+ is_layer?: boolean;
7354
8344
  layers_per_cart?: number;
7355
8345
  location: string;
7356
8346
  min_quantity?: number;
@@ -7363,17 +8353,24 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7363
8353
  trade_item_key?: string | null;
7364
8354
  unit?: string;
7365
8355
  updated_at?: string;
8356
+ vat_code?: string | null;
8357
+ vat_rate?: number | null;
7366
8358
  weight?: string | null;
7367
8359
  };
7368
8360
  Update: {
8361
+ article_number?: string | null;
7369
8362
  barcode?: string | null;
7370
8363
  batch?: string;
7371
8364
  crates_per_layer?: number;
7372
8365
  created_at?: string;
7373
8366
  custom_fields?: import("./types").Json;
8367
+ floriday_active?: boolean;
8368
+ floriday_payload?: import("./types").Json;
8369
+ floriday_trade_item_id?: string | null;
7374
8370
  id?: string;
7375
8371
  image_url?: string | null;
7376
8372
  incoming_quantity?: number;
8373
+ is_layer?: boolean;
7377
8374
  layers_per_cart?: number;
7378
8375
  location?: string;
7379
8376
  min_quantity?: number;
@@ -7386,6 +8383,8 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
7386
8383
  trade_item_key?: string | null;
7387
8384
  unit?: string;
7388
8385
  updated_at?: string;
8386
+ vat_code?: string | null;
8387
+ vat_rate?: number | null;
7389
8388
  weight?: string | null;
7390
8389
  };
7391
8390
  Relationships: [];
@@ -8279,8 +9278,10 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8279
9278
  order_id: string | null;
8280
9279
  order_item_id: string | null;
8281
9280
  order_source: string | null;
9281
+ parent_trade_item_key: string | null;
8282
9282
  physical_after: number | null;
8283
9283
  physical_before: number | null;
9284
+ production_batch_id: string | null;
8284
9285
  qty_delta: number;
8285
9286
  reason: string | null;
8286
9287
  reserved_after: number | null;
@@ -8296,8 +9297,10 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8296
9297
  order_id?: string | null;
8297
9298
  order_item_id?: string | null;
8298
9299
  order_source?: string | null;
9300
+ parent_trade_item_key?: string | null;
8299
9301
  physical_after?: number | null;
8300
9302
  physical_before?: number | null;
9303
+ production_batch_id?: string | null;
8301
9304
  qty_delta: number;
8302
9305
  reason?: string | null;
8303
9306
  reserved_after?: number | null;
@@ -8313,8 +9316,10 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8313
9316
  order_id?: string | null;
8314
9317
  order_item_id?: string | null;
8315
9318
  order_source?: string | null;
9319
+ parent_trade_item_key?: string | null;
8316
9320
  physical_after?: number | null;
8317
9321
  physical_before?: number | null;
9322
+ production_batch_id?: string | null;
8318
9323
  qty_delta?: number;
8319
9324
  reason?: string | null;
8320
9325
  reserved_after?: number | null;
@@ -8620,6 +9625,48 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8620
9625
  };
8621
9626
  Relationships: [];
8622
9627
  };
9628
+ trade_item_prices: {
9629
+ Row: {
9630
+ created_at: string;
9631
+ currency: string;
9632
+ id: string;
9633
+ last_push_error: string | null;
9634
+ last_pushed_at: string | null;
9635
+ price_group_id: string | null;
9636
+ price_per_piece: number;
9637
+ supply_line_id: string | null;
9638
+ trade_item_key: string;
9639
+ updated_at: string;
9640
+ user_id: string;
9641
+ };
9642
+ Insert: {
9643
+ created_at?: string;
9644
+ currency?: string;
9645
+ id?: string;
9646
+ last_push_error?: string | null;
9647
+ last_pushed_at?: string | null;
9648
+ price_group_id?: string | null;
9649
+ price_per_piece: number;
9650
+ supply_line_id?: string | null;
9651
+ trade_item_key: string;
9652
+ updated_at?: string;
9653
+ user_id: string;
9654
+ };
9655
+ Update: {
9656
+ created_at?: string;
9657
+ currency?: string;
9658
+ id?: string;
9659
+ last_push_error?: string | null;
9660
+ last_pushed_at?: string | null;
9661
+ price_group_id?: string | null;
9662
+ price_per_piece?: number;
9663
+ supply_line_id?: string | null;
9664
+ trade_item_key?: string;
9665
+ updated_at?: string;
9666
+ user_id?: string;
9667
+ };
9668
+ Relationships: [];
9669
+ };
8623
9670
  trade_item_stock: {
8624
9671
  Row: {
8625
9672
  connection_id: string;
@@ -8773,7 +9820,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8773
9820
  twinfield_connections: {
8774
9821
  Row: {
8775
9822
  access_token: string | null;
8776
- client_id: string;
9823
+ client_id: string | null;
8777
9824
  client_secret: string | null;
8778
9825
  cluster_uri: string | null;
8779
9826
  company_code: string | null;
@@ -8785,7 +9832,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8785
9832
  is_active: boolean;
8786
9833
  label: string | null;
8787
9834
  office_code: string | null;
8788
- redirect_uri: string;
9835
+ redirect_uri: string | null;
8789
9836
  refresh_token: string | null;
8790
9837
  token_expires_at: string | null;
8791
9838
  updated_at: string;
@@ -8793,7 +9840,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8793
9840
  };
8794
9841
  Insert: {
8795
9842
  access_token?: string | null;
8796
- client_id: string;
9843
+ client_id?: string | null;
8797
9844
  client_secret?: string | null;
8798
9845
  cluster_uri?: string | null;
8799
9846
  company_code?: string | null;
@@ -8805,7 +9852,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8805
9852
  is_active?: boolean;
8806
9853
  label?: string | null;
8807
9854
  office_code?: string | null;
8808
- redirect_uri: string;
9855
+ redirect_uri?: string | null;
8809
9856
  refresh_token?: string | null;
8810
9857
  token_expires_at?: string | null;
8811
9858
  updated_at?: string;
@@ -8813,7 +9860,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8813
9860
  };
8814
9861
  Update: {
8815
9862
  access_token?: string | null;
8816
- client_id?: string;
9863
+ client_id?: string | null;
8817
9864
  client_secret?: string | null;
8818
9865
  cluster_uri?: string | null;
8819
9866
  company_code?: string | null;
@@ -8825,7 +9872,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
8825
9872
  is_active?: boolean;
8826
9873
  label?: string | null;
8827
9874
  office_code?: string | null;
8828
- redirect_uri?: string;
9875
+ redirect_uri?: string | null;
8829
9876
  refresh_token?: string | null;
8830
9877
  token_expires_at?: string | null;
8831
9878
  updated_at?: string;
@@ -9082,6 +10129,51 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
9082
10129
  referencedColumns: ["id"];
9083
10130
  }];
9084
10131
  };
10132
+ twinfield_invoice_pdf_cache: {
10133
+ Row: {
10134
+ connection_id: string;
10135
+ created_at: string;
10136
+ fetched_at: string;
10137
+ id: string;
10138
+ invoice_number: string;
10139
+ last_accessed_at: string;
10140
+ object_path: string;
10141
+ office_code: string;
10142
+ size_bytes: number;
10143
+ updated_at: string;
10144
+ };
10145
+ Insert: {
10146
+ connection_id: string;
10147
+ created_at?: string;
10148
+ fetched_at?: string;
10149
+ id?: string;
10150
+ invoice_number: string;
10151
+ last_accessed_at?: string;
10152
+ object_path: string;
10153
+ office_code: string;
10154
+ size_bytes?: number;
10155
+ updated_at?: string;
10156
+ };
10157
+ Update: {
10158
+ connection_id?: string;
10159
+ created_at?: string;
10160
+ fetched_at?: string;
10161
+ id?: string;
10162
+ invoice_number?: string;
10163
+ last_accessed_at?: string;
10164
+ object_path?: string;
10165
+ office_code?: string;
10166
+ size_bytes?: number;
10167
+ updated_at?: string;
10168
+ };
10169
+ Relationships: [{
10170
+ foreignKeyName: "twinfield_invoice_pdf_cache_connection_id_fkey";
10171
+ columns: ["connection_id"];
10172
+ isOneToOne: false;
10173
+ referencedRelation: "twinfield_connections";
10174
+ referencedColumns: ["id"];
10175
+ }];
10176
+ };
9085
10177
  twinfield_invoice_settings: {
9086
10178
  Row: {
9087
10179
  created_at: string;
@@ -10020,25 +11112,6 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10020
11112
  };
10021
11113
  Relationships: [];
10022
11114
  };
10023
- floriday_customer_discounts: {
10024
- Row: {
10025
- base_price: number | null;
10026
- buyer_organization_id: string | null;
10027
- currency: string | null;
10028
- discount_type: string | null;
10029
- discount_value: number | null;
10030
- min_quantity: number | null;
10031
- net_price: number | null;
10032
- product_group_id: string | null;
10033
- raw: import("./types").Json | null;
10034
- source: string | null;
10035
- source_id: string | null;
10036
- trade_item_id: string | null;
10037
- valid_from: string | null;
10038
- valid_until: string | null;
10039
- };
10040
- Relationships: [];
10041
- };
10042
11115
  local_customer_discounts: {
10043
11116
  Row: {
10044
11117
  base_price: number | null;
@@ -10342,6 +11415,13 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10342
11415
  };
10343
11416
  Returns: number;
10344
11417
  };
11418
+ _migrate_rewrite_stock_key: {
11419
+ Args: {
11420
+ _from_key: string;
11421
+ _to_key: string;
11422
+ };
11423
+ Returns: undefined;
11424
+ };
10345
11425
  afh_city_code: {
10346
11426
  Args: {
10347
11427
  _city: string;
@@ -10425,6 +11505,12 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10425
11505
  processed_items: number;
10426
11506
  }[];
10427
11507
  };
11508
+ calculate_layer_stock: {
11509
+ Args: {
11510
+ p_product_id: string;
11511
+ };
11512
+ Returns: number;
11513
+ };
10428
11514
  call_exact_route: {
10429
11515
  Args: {
10430
11516
  path: string;
@@ -10457,6 +11543,28 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10457
11543
  Args: never;
10458
11544
  Returns: undefined;
10459
11545
  };
11546
+ consume_bom_for_production: {
11547
+ Args: {
11548
+ p_connection_id: string;
11549
+ p_parent_id: string;
11550
+ p_parent_key: string;
11551
+ p_parent_kind: string;
11552
+ p_quantity: number;
11553
+ p_user_id: string;
11554
+ };
11555
+ Returns: import("./types").Json;
11556
+ } | {
11557
+ Args: {
11558
+ p_batch_id?: string;
11559
+ p_connection_id: string;
11560
+ p_parent_id: string;
11561
+ p_parent_key: string;
11562
+ p_parent_kind: string;
11563
+ p_quantity: number;
11564
+ p_user_id: string;
11565
+ };
11566
+ Returns: import("./types").Json;
11567
+ };
10460
11568
  consume_floriday_rate_limit: {
10461
11569
  Args: {
10462
11570
  p_bucket: string;
@@ -10508,6 +11616,13 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10508
11616
  table_name: string;
10509
11617
  }[];
10510
11618
  };
11619
+ delete_samenstelling: {
11620
+ Args: {
11621
+ p_parent_id: string;
11622
+ p_parent_kind: string;
11623
+ };
11624
+ Returns: import("./types").Json;
11625
+ };
10511
11626
  dispatch_carrier_signups_sql: {
10512
11627
  Args: {
10513
11628
  _catchup?: string;
@@ -10549,6 +11664,16 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10549
11664
  status: string;
10550
11665
  }[];
10551
11666
  };
11667
+ email_auth_upsert_connection: {
11668
+ Args: {
11669
+ _account_email: string;
11670
+ _created_by: string;
11671
+ _is_active: boolean;
11672
+ _provider: string;
11673
+ _status: string;
11674
+ };
11675
+ Returns: string;
11676
+ };
10552
11677
  enqueue_cart_replan_if_unlocked: {
10553
11678
  Args: {
10554
11679
  p_order_id: string;
@@ -10668,19 +11793,6 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10668
11793
  resource: string;
10669
11794
  }[];
10670
11795
  };
10671
- get_floriday_agreements_active: {
10672
- Args: {
10673
- p_on_date?: string;
10674
- };
10675
- Returns: {
10676
- buyer_organization_id: string;
10677
- data: import("./types").Json;
10678
- floriday_id: string;
10679
- status: string;
10680
- valid_from: string;
10681
- valid_until: string;
10682
- }[];
10683
- };
10684
11796
  get_floriday_clock_supplies_window: {
10685
11797
  Args: {
10686
11798
  p_from: string;
@@ -10753,6 +11865,27 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10753
11865
  minutes_since_success: number;
10754
11866
  }[];
10755
11867
  };
11868
+ get_group_allocation_keys: {
11869
+ Args: {
11870
+ p_product_id: string;
11871
+ };
11872
+ Returns: {
11873
+ k: string;
11874
+ ord: number;
11875
+ }[];
11876
+ };
11877
+ get_group_head_key: {
11878
+ Args: {
11879
+ p_group_id: string;
11880
+ };
11881
+ Returns: string;
11882
+ };
11883
+ get_inventory_stock_for_key: {
11884
+ Args: {
11885
+ p_key: string;
11886
+ };
11887
+ Returns: number;
11888
+ };
10756
11889
  get_offer_by_link_code: {
10757
11890
  Args: {
10758
11891
  p_code: string;
@@ -10783,6 +11916,12 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10783
11916
  };
10784
11917
  Returns: string;
10785
11918
  };
11919
+ get_product_group_available_stock: {
11920
+ Args: {
11921
+ p_group_id: string;
11922
+ };
11923
+ Returns: number;
11924
+ };
10786
11925
  get_room_busy_windows: {
10787
11926
  Args: {
10788
11927
  p_from: string;
@@ -10863,6 +12002,32 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10863
12002
  };
10864
12003
  Returns: undefined;
10865
12004
  };
12005
+ mark_salesorder_controlled: {
12006
+ Args: {
12007
+ p_controlled: boolean;
12008
+ p_floriday_id: string;
12009
+ };
12010
+ Returns: undefined;
12011
+ };
12012
+ mark_shipment_shipped: {
12013
+ Args: {
12014
+ p_shipment_id: string;
12015
+ };
12016
+ Returns: undefined;
12017
+ };
12018
+ merge_products: {
12019
+ Args: {
12020
+ _canonical: string;
12021
+ _loser: string;
12022
+ };
12023
+ Returns: undefined;
12024
+ };
12025
+ next_manufacture_partij: {
12026
+ Args: {
12027
+ _tenant_id: string;
12028
+ };
12029
+ Returns: string;
12030
+ };
10866
12031
  next_order_number: {
10867
12032
  Args: {
10868
12033
  p_prefix: string;
@@ -10932,6 +12097,15 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10932
12097
  };
10933
12098
  Returns: undefined;
10934
12099
  };
12100
+ pickstation_resolve_delivery_orders: {
12101
+ Args: {
12102
+ p_sales_order_ids: string[];
12103
+ };
12104
+ Returns: {
12105
+ delivery_order_id: string;
12106
+ sales_order_id: string;
12107
+ }[];
12108
+ };
10935
12109
  pickstation_set_cart_status: {
10936
12110
  Args: {
10937
12111
  p_cart_index: number;
@@ -10941,6 +12115,14 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10941
12115
  };
10942
12116
  Returns: undefined;
10943
12117
  };
12118
+ produce_designed_product: {
12119
+ Args: {
12120
+ p_parent_id: string;
12121
+ p_parent_kind: string;
12122
+ p_quantity: number;
12123
+ };
12124
+ Returns: import("./types").Json;
12125
+ };
10944
12126
  promote_trade_item_key: {
10945
12127
  Args: {
10946
12128
  p_new: string;
@@ -10948,6 +12130,10 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10948
12130
  };
10949
12131
  Returns: undefined;
10950
12132
  };
12133
+ recompute_all_reserved_stock: {
12134
+ Args: never;
12135
+ Returns: undefined;
12136
+ };
10951
12137
  recompute_order_status: {
10952
12138
  Args: {
10953
12139
  p_order_id: string;
@@ -10997,27 +12183,45 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
10997
12183
  };
10998
12184
  Returns: undefined;
10999
12185
  };
12186
+ resolve_group_allocation: {
12187
+ Args: {
12188
+ _needed: number;
12189
+ _product_group_id: string;
12190
+ };
12191
+ Returns: {
12192
+ allocated: number;
12193
+ trade_item_id: string;
12194
+ }[];
12195
+ };
12196
+ resolve_group_member_stock_key: {
12197
+ Args: {
12198
+ p_trade_item_id: string;
12199
+ };
12200
+ Returns: string;
12201
+ };
11000
12202
  resolve_product_id_for_item: {
11001
12203
  Args: {
11002
12204
  p_product_name: string;
11003
12205
  };
11004
12206
  Returns: string;
11005
12207
  };
11006
- schedule_floriday_additional_services_sync: {
12208
+ resolve_stock_trade_item_key: {
11007
12209
  Args: {
11008
- p_apikey: string;
11009
- p_url: string;
12210
+ p_product_id: string;
11010
12211
  };
11011
- Returns: number;
12212
+ Returns: string;
11012
12213
  };
11013
- schedule_floriday_agreement_calloffs_sync: {
12214
+ reverse_production: {
11014
12215
  Args: {
11015
- p_apikey: string;
11016
- p_url: string;
12216
+ p_connection_id?: string;
12217
+ p_parent_key: string;
12218
+ p_quantity: number;
12219
+ p_reason?: string;
12220
+ p_user_id?: string;
11017
12221
  };
11018
- Returns: number;
12222
+ Returns: import("./types").Json;
11019
12223
  };
11020
- schedule_floriday_agreements_sync: {
12224
+ schedule_floriday_additional_services_sync: {
11021
12225
  Args: {
11022
12226
  p_apikey: string;
11023
12227
  p_url: string;
@@ -11270,6 +12474,10 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
11270
12474
  };
11271
12475
  Returns: number;
11272
12476
  };
12477
+ self_heal_floriday_links: {
12478
+ Args: never;
12479
+ Returns: number;
12480
+ };
11273
12481
  show_limit: {
11274
12482
  Args: never;
11275
12483
  Returns: number;
@@ -11280,18 +12488,34 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
11280
12488
  };
11281
12489
  Returns: string[];
11282
12490
  };
12491
+ sync_all_layer_stocks: {
12492
+ Args: never;
12493
+ Returns: undefined;
12494
+ };
11283
12495
  sync_cached_packing_from_product: {
11284
12496
  Args: {
11285
12497
  p_product_id: string;
11286
12498
  };
11287
12499
  Returns: undefined;
11288
12500
  };
12501
+ sync_layer_stock: {
12502
+ Args: {
12503
+ p_product_id: string;
12504
+ };
12505
+ Returns: undefined;
12506
+ };
11289
12507
  sync_order_cart_item_packing_from_product: {
11290
12508
  Args: {
11291
12509
  p_product_id: string;
11292
12510
  };
11293
12511
  Returns: undefined;
11294
12512
  };
12513
+ sync_product_group_belading: {
12514
+ Args: {
12515
+ _group_id: string;
12516
+ };
12517
+ Returns: undefined;
12518
+ };
11295
12519
  sync_product_packing_from_floriday_cache: {
11296
12520
  Args: {
11297
12521
  p_floriday_id: string;