@flowselections/floriday-verkoop-module 1.0.16 → 1.0.18

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 (60) hide show
  1. package/dist-lib/components/verkoop/CreateOrderPage.d.ts.map +1 -1
  2. package/dist-lib/components/verkoop/CreateOrderPage.js +12 -12
  3. package/dist-lib/components/verkoop/EditLocalOrderDialog.d.ts +6 -0
  4. package/dist-lib/components/verkoop/EditLocalOrderDialog.d.ts.map +1 -0
  5. package/dist-lib/components/verkoop/EditLocalOrderDialog.js +102 -0
  6. package/dist-lib/components/verkoop/OrderKarindelingCard.d.ts.map +1 -1
  7. package/dist-lib/components/verkoop/OrderKarindelingCard.js +26 -28
  8. package/dist-lib/components/verkoop/OrderShipmentsCard.d.ts +5 -0
  9. package/dist-lib/components/verkoop/OrderShipmentsCard.d.ts.map +1 -0
  10. package/dist-lib/components/verkoop/OrderShipmentsCard.js +137 -0
  11. package/dist-lib/components/verkoop/SalesOrderDetailPage.d.ts.map +1 -1
  12. package/dist-lib/components/verkoop/SalesOrderDetailPage.js +8 -2
  13. package/dist-lib/components/verkoop/SalesOrderDetailView.d.ts.map +1 -1
  14. package/dist-lib/components/verkoop/SalesOrderDetailView.js +2 -1
  15. package/dist-lib/components/verkoop/SalesOrdersFilters.d.ts.map +1 -1
  16. package/dist-lib/components/verkoop/SalesOrdersFilters.js +2 -8
  17. package/dist-lib/components/verkoop/SalesOrdersTable.d.ts +4 -1
  18. package/dist-lib/components/verkoop/SalesOrdersTable.d.ts.map +1 -1
  19. package/dist-lib/components/verkoop/SalesOrdersTable.js +2 -2
  20. package/dist-lib/components/verkoop/VerkoopOrdersPage.d.ts.map +1 -1
  21. package/dist-lib/components/verkoop/VerkoopOrdersPage.js +43 -1
  22. package/dist-lib/index.js +2 -2
  23. package/dist-lib/integrations/supabase/auth-middleware.d.ts +607 -169
  24. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  25. package/dist-lib/integrations/supabase/client.d.ts +607 -169
  26. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  27. package/dist-lib/integrations/supabase/client.server.d.ts +607 -169
  28. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  29. package/dist-lib/integrations/supabase/types.d.ts +623 -164
  30. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  31. package/dist-lib/lib/cart-lock.functions.d.ts +607 -169
  32. package/dist-lib/lib/cart-lock.functions.d.ts.map +1 -1
  33. package/dist-lib/lib/cart-replan.functions.d.ts +1221 -345
  34. package/dist-lib/lib/cart-replan.functions.d.ts.map +1 -1
  35. package/dist-lib/lib/create-order.functions.d.ts +40700 -1397
  36. package/dist-lib/lib/create-order.functions.d.ts.map +1 -1
  37. package/dist-lib/lib/create-order.functions.js +792 -52
  38. package/dist-lib/lib/expand-group-order-items.d.ts +13 -0
  39. package/dist-lib/lib/expand-group-order-items.d.ts.map +1 -0
  40. package/dist-lib/lib/expand-group-order-items.js +216 -0
  41. package/dist-lib/lib/floriday-auto-fulfillment.functions.d.ts +1767 -453
  42. package/dist-lib/lib/floriday-auto-fulfillment.functions.d.ts.map +1 -1
  43. package/dist-lib/lib/floriday-logistic-labels.functions.d.ts +607 -169
  44. package/dist-lib/lib/floriday-logistic-labels.functions.d.ts.map +1 -1
  45. package/dist-lib/lib/floriday-public.functions.d.ts +4123 -1057
  46. package/dist-lib/lib/floriday-public.functions.d.ts.map +1 -1
  47. package/dist-lib/lib/floriday-writes.functions.d.ts +2945 -755
  48. package/dist-lib/lib/floriday-writes.functions.d.ts.map +1 -1
  49. package/dist-lib/lib/order-shipments.functions.d.ts +47158 -0
  50. package/dist-lib/lib/order-shipments.functions.d.ts.map +1 -0
  51. package/dist-lib/lib/order-shipments.functions.js +178 -0
  52. package/dist-lib/lib/salesorders-mapping.d.ts +1 -0
  53. package/dist-lib/lib/salesorders-mapping.d.ts.map +1 -1
  54. package/dist-lib/lib/salesorders.functions.d.ts +1767 -453
  55. package/dist-lib/lib/salesorders.functions.d.ts.map +1 -1
  56. package/dist-lib/lib/tradeitems.functions.d.ts +607 -169
  57. package/dist-lib/lib/tradeitems.functions.d.ts.map +1 -1
  58. package/dist-lib/lib/useSalesOrdersQuery.d.ts.map +1 -1
  59. package/dist-lib/lib/useSalesOrdersQuery.js +39 -2
  60. package/package.json +2 -2
@@ -242,6 +242,165 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
242
242
  };
243
243
  Relationships: [];
244
244
  };
245
+ ai_credentials: {
246
+ Row: {
247
+ active: boolean;
248
+ api_key: string;
249
+ created_at: string;
250
+ created_by: string | null;
251
+ id: string;
252
+ label: string;
253
+ provider_id: string;
254
+ updated_at: string;
255
+ };
256
+ Insert: {
257
+ active?: boolean;
258
+ api_key: string;
259
+ created_at?: string;
260
+ created_by?: string | null;
261
+ id?: string;
262
+ label: string;
263
+ provider_id: string;
264
+ updated_at?: string;
265
+ };
266
+ Update: {
267
+ active?: boolean;
268
+ api_key?: string;
269
+ created_at?: string;
270
+ created_by?: string | null;
271
+ id?: string;
272
+ label?: string;
273
+ provider_id?: string;
274
+ updated_at?: string;
275
+ };
276
+ Relationships: [{
277
+ foreignKeyName: "ai_credentials_provider_id_fkey";
278
+ columns: ["provider_id"];
279
+ isOneToOne: false;
280
+ referencedRelation: "ai_providers";
281
+ referencedColumns: ["id"];
282
+ }];
283
+ };
284
+ ai_models: {
285
+ Row: {
286
+ active: boolean;
287
+ context_window: number | null;
288
+ created_at: string;
289
+ display_name: string;
290
+ id: string;
291
+ is_default: boolean;
292
+ modality: string;
293
+ provider_id: string;
294
+ slug: string;
295
+ updated_at: string;
296
+ };
297
+ Insert: {
298
+ active?: boolean;
299
+ context_window?: number | null;
300
+ created_at?: string;
301
+ display_name: string;
302
+ id?: string;
303
+ is_default?: boolean;
304
+ modality?: string;
305
+ provider_id: string;
306
+ slug: string;
307
+ updated_at?: string;
308
+ };
309
+ Update: {
310
+ active?: boolean;
311
+ context_window?: number | null;
312
+ created_at?: string;
313
+ display_name?: string;
314
+ id?: string;
315
+ is_default?: boolean;
316
+ modality?: string;
317
+ provider_id?: string;
318
+ slug?: string;
319
+ updated_at?: string;
320
+ };
321
+ Relationships: [{
322
+ foreignKeyName: "ai_models_provider_id_fkey";
323
+ columns: ["provider_id"];
324
+ isOneToOne: false;
325
+ referencedRelation: "ai_providers";
326
+ referencedColumns: ["id"];
327
+ }];
328
+ };
329
+ ai_module_bindings: {
330
+ Row: {
331
+ consumer_module_id: string;
332
+ created_at: string;
333
+ credential_id: string;
334
+ id: string;
335
+ model_id: string;
336
+ notes: string | null;
337
+ updated_at: string;
338
+ };
339
+ Insert: {
340
+ consumer_module_id: string;
341
+ created_at?: string;
342
+ credential_id: string;
343
+ id?: string;
344
+ model_id: string;
345
+ notes?: string | null;
346
+ updated_at?: string;
347
+ };
348
+ Update: {
349
+ consumer_module_id?: string;
350
+ created_at?: string;
351
+ credential_id?: string;
352
+ id?: string;
353
+ model_id?: string;
354
+ notes?: string | null;
355
+ updated_at?: string;
356
+ };
357
+ Relationships: [{
358
+ foreignKeyName: "ai_module_bindings_credential_id_fkey";
359
+ columns: ["credential_id"];
360
+ isOneToOne: false;
361
+ referencedRelation: "ai_credentials";
362
+ referencedColumns: ["id"];
363
+ }, {
364
+ foreignKeyName: "ai_module_bindings_model_id_fkey";
365
+ columns: ["model_id"];
366
+ isOneToOne: false;
367
+ referencedRelation: "ai_models";
368
+ referencedColumns: ["id"];
369
+ }];
370
+ };
371
+ ai_providers: {
372
+ Row: {
373
+ active: boolean;
374
+ auth_type: string;
375
+ base_url: string | null;
376
+ created_at: string;
377
+ id: string;
378
+ name: string;
379
+ slug: string;
380
+ updated_at: string;
381
+ };
382
+ Insert: {
383
+ active?: boolean;
384
+ auth_type?: string;
385
+ base_url?: string | null;
386
+ created_at?: string;
387
+ id?: string;
388
+ name: string;
389
+ slug: string;
390
+ updated_at?: string;
391
+ };
392
+ Update: {
393
+ active?: boolean;
394
+ auth_type?: string;
395
+ base_url?: string | null;
396
+ created_at?: string;
397
+ id?: string;
398
+ name?: string;
399
+ slug?: string;
400
+ updated_at?: string;
401
+ };
402
+ Relationships: [];
403
+ };
245
404
  app_settings: {
246
405
  Row: {
247
406
  created_at: string;
@@ -3248,105 +3407,6 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
3248
3407
  referencedColumns: ["id"];
3249
3408
  }];
3250
3409
  };
3251
- floriday_agreement_calloffs_cache: {
3252
- Row: {
3253
- agreement_id: string | null;
3254
- connection_id: string;
3255
- data: import("./types").Json;
3256
- delivery_date: string | null;
3257
- fetched_at: string;
3258
- floriday_id: string;
3259
- id: string;
3260
- is_deleted: boolean;
3261
- sequence_number: number;
3262
- status: string | null;
3263
- updated_at: string;
3264
- };
3265
- Insert: {
3266
- agreement_id?: string | null;
3267
- connection_id: string;
3268
- data?: import("./types").Json;
3269
- delivery_date?: string | null;
3270
- fetched_at?: string;
3271
- floriday_id: string;
3272
- id?: string;
3273
- is_deleted?: boolean;
3274
- sequence_number?: number;
3275
- status?: string | null;
3276
- updated_at?: string;
3277
- };
3278
- Update: {
3279
- agreement_id?: string | null;
3280
- connection_id?: string;
3281
- data?: import("./types").Json;
3282
- delivery_date?: string | null;
3283
- fetched_at?: string;
3284
- floriday_id?: string;
3285
- id?: string;
3286
- is_deleted?: boolean;
3287
- sequence_number?: number;
3288
- status?: string | null;
3289
- updated_at?: string;
3290
- };
3291
- Relationships: [{
3292
- foreignKeyName: "floriday_agreement_calloffs_cache_connection_id_fkey";
3293
- columns: ["connection_id"];
3294
- isOneToOne: false;
3295
- referencedRelation: "floriday_connections";
3296
- referencedColumns: ["id"];
3297
- }];
3298
- };
3299
- floriday_agreements_cache: {
3300
- Row: {
3301
- buyer_organization_id: string | null;
3302
- connection_id: string;
3303
- data: import("./types").Json;
3304
- fetched_at: string;
3305
- floriday_id: string;
3306
- id: string;
3307
- is_deleted: boolean;
3308
- sequence_number: number;
3309
- status: string | null;
3310
- updated_at: string;
3311
- valid_from: string | null;
3312
- valid_until: string | null;
3313
- };
3314
- Insert: {
3315
- buyer_organization_id?: string | null;
3316
- connection_id: string;
3317
- data?: import("./types").Json;
3318
- fetched_at?: string;
3319
- floriday_id: string;
3320
- id?: string;
3321
- is_deleted?: boolean;
3322
- sequence_number?: number;
3323
- status?: string | null;
3324
- updated_at?: string;
3325
- valid_from?: string | null;
3326
- valid_until?: string | null;
3327
- };
3328
- Update: {
3329
- buyer_organization_id?: string | null;
3330
- connection_id?: string;
3331
- data?: import("./types").Json;
3332
- fetched_at?: string;
3333
- floriday_id?: string;
3334
- id?: string;
3335
- is_deleted?: boolean;
3336
- sequence_number?: number;
3337
- status?: string | null;
3338
- updated_at?: string;
3339
- valid_from?: string | null;
3340
- valid_until?: string | null;
3341
- };
3342
- Relationships: [{
3343
- foreignKeyName: "floriday_agreements_cache_connection_id_fkey";
3344
- columns: ["connection_id"];
3345
- isOneToOne: false;
3346
- referencedRelation: "floriday_connections";
3347
- referencedColumns: ["id"];
3348
- }];
3349
- };
3350
3410
  floriday_auction_letters_cache: {
3351
3411
  Row: {
3352
3412
  auction_letter_code: string;
@@ -3845,6 +3905,27 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
3845
3905
  referencedColumns: ["id"];
3846
3906
  }];
3847
3907
  };
3908
+ floriday_continuous_stock_cache: {
3909
+ Row: {
3910
+ connection_id: string;
3911
+ fetched_at: string;
3912
+ number_of_pieces: number;
3913
+ trade_item_id: string;
3914
+ };
3915
+ Insert: {
3916
+ connection_id: string;
3917
+ fetched_at?: string;
3918
+ number_of_pieces?: number;
3919
+ trade_item_id: string;
3920
+ };
3921
+ Update: {
3922
+ connection_id?: string;
3923
+ fetched_at?: string;
3924
+ number_of_pieces?: number;
3925
+ trade_item_id?: string;
3926
+ };
3927
+ Relationships: [];
3928
+ };
3848
3929
  floriday_continuous_stock_queue: {
3849
3930
  Row: {
3850
3931
  attempts: number;
@@ -4823,9 +4904,8 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
4823
4904
  referencedColumns: ["id"];
4824
4905
  }];
4825
4906
  };
4826
- floriday_trips_cache: {
4907
+ floriday_trade_settings_customers_cache: {
4827
4908
  Row: {
4828
- carrier_organization_id: string | null;
4829
4909
  connection_id: string;
4830
4910
  data: import("./types").Json;
4831
4911
  fetched_at: string;
@@ -4833,25 +4913,19 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
4833
4913
  id: string;
4834
4914
  is_deleted: boolean;
4835
4915
  sequence_number: number;
4836
- status: string | null;
4837
- trip_date: string | null;
4838
4916
  updated_at: string;
4839
4917
  };
4840
4918
  Insert: {
4841
- carrier_organization_id?: string | null;
4842
4919
  connection_id: string;
4843
- data?: import("./types").Json;
4920
+ data: import("./types").Json;
4844
4921
  fetched_at?: string;
4845
4922
  floriday_id: string;
4846
4923
  id?: string;
4847
4924
  is_deleted?: boolean;
4848
4925
  sequence_number?: number;
4849
- status?: string | null;
4850
- trip_date?: string | null;
4851
4926
  updated_at?: string;
4852
4927
  };
4853
4928
  Update: {
4854
- carrier_organization_id?: string | null;
4855
4929
  connection_id?: string;
4856
4930
  data?: import("./types").Json;
4857
4931
  fetched_at?: string;
@@ -4859,31 +4933,77 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
4859
4933
  id?: string;
4860
4934
  is_deleted?: boolean;
4861
4935
  sequence_number?: number;
4862
- status?: string | null;
4863
- trip_date?: string | null;
4864
4936
  updated_at?: string;
4865
4937
  };
4866
4938
  Relationships: [{
4867
- foreignKeyName: "floriday_trips_cache_connection_id_fkey";
4939
+ foreignKeyName: "floriday_trade_settings_customers_cache_connection_id_fkey";
4868
4940
  columns: ["connection_id"];
4869
4941
  isOneToOne: false;
4870
4942
  referencedRelation: "floriday_connections";
4871
4943
  referencedColumns: ["id"];
4872
4944
  }];
4873
4945
  };
4874
- floriday_warehouses_cache: {
4946
+ floriday_trips_cache: {
4875
4947
  Row: {
4948
+ carrier_organization_id: string | null;
4876
4949
  connection_id: string;
4877
4950
  data: import("./types").Json;
4878
4951
  fetched_at: string;
4879
4952
  floriday_id: string;
4880
- gln_code: string | null;
4881
4953
  id: string;
4882
- is_default: boolean;
4883
4954
  is_deleted: boolean;
4884
- name: string | null;
4885
- updated_at: string;
4886
- };
4955
+ sequence_number: number;
4956
+ status: string | null;
4957
+ trip_date: string | null;
4958
+ updated_at: string;
4959
+ };
4960
+ Insert: {
4961
+ carrier_organization_id?: string | null;
4962
+ connection_id: string;
4963
+ data?: import("./types").Json;
4964
+ fetched_at?: string;
4965
+ floriday_id: string;
4966
+ id?: string;
4967
+ is_deleted?: boolean;
4968
+ sequence_number?: number;
4969
+ status?: string | null;
4970
+ trip_date?: string | null;
4971
+ updated_at?: string;
4972
+ };
4973
+ Update: {
4974
+ carrier_organization_id?: string | null;
4975
+ connection_id?: string;
4976
+ data?: import("./types").Json;
4977
+ fetched_at?: string;
4978
+ floriday_id?: string;
4979
+ id?: string;
4980
+ is_deleted?: boolean;
4981
+ sequence_number?: number;
4982
+ status?: string | null;
4983
+ trip_date?: string | null;
4984
+ updated_at?: string;
4985
+ };
4986
+ Relationships: [{
4987
+ foreignKeyName: "floriday_trips_cache_connection_id_fkey";
4988
+ columns: ["connection_id"];
4989
+ isOneToOne: false;
4990
+ referencedRelation: "floriday_connections";
4991
+ referencedColumns: ["id"];
4992
+ }];
4993
+ };
4994
+ floriday_warehouses_cache: {
4995
+ Row: {
4996
+ connection_id: string;
4997
+ data: import("./types").Json;
4998
+ fetched_at: string;
4999
+ floriday_id: string;
5000
+ gln_code: string | null;
5001
+ id: string;
5002
+ is_default: boolean;
5003
+ is_deleted: boolean;
5004
+ name: string | null;
5005
+ updated_at: string;
5006
+ };
4887
5007
  Insert: {
4888
5008
  connection_id: string;
4889
5009
  data?: import("./types").Json;
@@ -5968,39 +6088,60 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
5968
6088
  };
5969
6089
  manufacture_products: {
5970
6090
  Row: {
6091
+ aantal_te_produceren: number;
5971
6092
  created_at: string;
5972
6093
  description: string | null;
5973
6094
  id: string;
5974
6095
  is_active: boolean;
6096
+ location_id: string | null;
5975
6097
  name: string;
6098
+ partij_nummer: string | null;
6099
+ photos: import("./types").Json;
5976
6100
  produced_stock: number;
5977
6101
  product_code: string;
5978
6102
  tenant_id: string;
6103
+ unit: string;
5979
6104
  updated_at: string;
5980
6105
  };
5981
6106
  Insert: {
6107
+ aantal_te_produceren?: number;
5982
6108
  created_at?: string;
5983
6109
  description?: string | null;
5984
6110
  id?: string;
5985
6111
  is_active?: boolean;
6112
+ location_id?: string | null;
5986
6113
  name: string;
6114
+ partij_nummer?: string | null;
6115
+ photos?: import("./types").Json;
5987
6116
  produced_stock?: number;
5988
6117
  product_code: string;
5989
6118
  tenant_id: string;
6119
+ unit?: string;
5990
6120
  updated_at?: string;
5991
6121
  };
5992
6122
  Update: {
6123
+ aantal_te_produceren?: number;
5993
6124
  created_at?: string;
5994
6125
  description?: string | null;
5995
6126
  id?: string;
5996
6127
  is_active?: boolean;
6128
+ location_id?: string | null;
5997
6129
  name?: string;
6130
+ partij_nummer?: string | null;
6131
+ photos?: import("./types").Json;
5998
6132
  produced_stock?: number;
5999
6133
  product_code?: string;
6000
6134
  tenant_id?: string;
6135
+ unit?: string;
6001
6136
  updated_at?: string;
6002
6137
  };
6003
- Relationships: [];
6138
+ Relationships: [{
6139
+ foreignKeyName: "manufacture_products_location_id_fkey";
6140
+ columns: ["location_id"];
6141
+ isOneToOne: false;
6142
+ referencedRelation: "locations";
6143
+ referencedColumns: ["id"];
6144
+ }];
6004
6145
  };
6005
6146
  monteurs: {
6006
6147
  Row: {
@@ -6974,6 +7115,105 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
6974
7115
  };
6975
7116
  Relationships: [];
6976
7117
  };
7118
+ order_shipment_items: {
7119
+ Row: {
7120
+ created_at: string;
7121
+ id: string;
7122
+ order_item_id: string;
7123
+ product_id: string | null;
7124
+ product_name: string;
7125
+ quantity: number;
7126
+ shipment_id: string;
7127
+ updated_at: string;
7128
+ };
7129
+ Insert: {
7130
+ created_at?: string;
7131
+ id?: string;
7132
+ order_item_id: string;
7133
+ product_id?: string | null;
7134
+ product_name: string;
7135
+ quantity: number;
7136
+ shipment_id: string;
7137
+ updated_at?: string;
7138
+ };
7139
+ Update: {
7140
+ created_at?: string;
7141
+ id?: string;
7142
+ order_item_id?: string;
7143
+ product_id?: string | null;
7144
+ product_name?: string;
7145
+ quantity?: number;
7146
+ shipment_id?: string;
7147
+ updated_at?: string;
7148
+ };
7149
+ Relationships: [{
7150
+ foreignKeyName: "order_shipment_items_order_item_id_fkey";
7151
+ columns: ["order_item_id"];
7152
+ isOneToOne: false;
7153
+ referencedRelation: "order_items";
7154
+ referencedColumns: ["id"];
7155
+ }, {
7156
+ foreignKeyName: "order_shipment_items_shipment_id_fkey";
7157
+ columns: ["shipment_id"];
7158
+ isOneToOne: false;
7159
+ referencedRelation: "order_shipments";
7160
+ referencedColumns: ["id"];
7161
+ }];
7162
+ };
7163
+ order_shipments: {
7164
+ Row: {
7165
+ carrier_id: string | null;
7166
+ created_at: string;
7167
+ delivery_date: string | null;
7168
+ delivery_location_id: string | null;
7169
+ id: string;
7170
+ notes: string | null;
7171
+ order_id: string;
7172
+ shipment_number: number;
7173
+ shipped_at: string | null;
7174
+ status: string;
7175
+ updated_at: string;
7176
+ };
7177
+ Insert: {
7178
+ carrier_id?: string | null;
7179
+ created_at?: string;
7180
+ delivery_date?: string | null;
7181
+ delivery_location_id?: string | null;
7182
+ id?: string;
7183
+ notes?: string | null;
7184
+ order_id: string;
7185
+ shipment_number: number;
7186
+ shipped_at?: string | null;
7187
+ status?: string;
7188
+ updated_at?: string;
7189
+ };
7190
+ Update: {
7191
+ carrier_id?: string | null;
7192
+ created_at?: string;
7193
+ delivery_date?: string | null;
7194
+ delivery_location_id?: string | null;
7195
+ id?: string;
7196
+ notes?: string | null;
7197
+ order_id?: string;
7198
+ shipment_number?: number;
7199
+ shipped_at?: string | null;
7200
+ status?: string;
7201
+ updated_at?: string;
7202
+ };
7203
+ Relationships: [{
7204
+ foreignKeyName: "order_shipments_carrier_id_fkey";
7205
+ columns: ["carrier_id"];
7206
+ isOneToOne: false;
7207
+ referencedRelation: "carriers";
7208
+ referencedColumns: ["id"];
7209
+ }, {
7210
+ foreignKeyName: "order_shipments_order_id_fkey";
7211
+ columns: ["order_id"];
7212
+ isOneToOne: false;
7213
+ referencedRelation: "orders";
7214
+ referencedColumns: ["id"];
7215
+ }];
7216
+ };
6977
7217
  orders: {
6978
7218
  Row: {
6979
7219
  created_at: string;
@@ -6981,8 +7221,9 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
6981
7221
  customer_id: string | null;
6982
7222
  customer_name: string;
6983
7223
  deleted_at: string | null;
6984
- delivery_date: string;
7224
+ delivery_date: string | null;
6985
7225
  id: string;
7226
+ is_reservation: boolean;
6986
7227
  notes: string | null;
6987
7228
  order_date: string;
6988
7229
  order_number: string;
@@ -6999,8 +7240,9 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
6999
7240
  customer_id?: string | null;
7000
7241
  customer_name?: string;
7001
7242
  deleted_at?: string | null;
7002
- delivery_date: string;
7243
+ delivery_date?: string | null;
7003
7244
  id?: string;
7245
+ is_reservation?: boolean;
7004
7246
  notes?: string | null;
7005
7247
  order_date?: string;
7006
7248
  order_number: string;
@@ -7017,8 +7259,9 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7017
7259
  customer_id?: string | null;
7018
7260
  customer_name?: string;
7019
7261
  deleted_at?: string | null;
7020
- delivery_date?: string;
7262
+ delivery_date?: string | null;
7021
7263
  id?: string;
7264
+ is_reservation?: boolean;
7022
7265
  notes?: string | null;
7023
7266
  order_date?: string;
7024
7267
  order_number?: string;
@@ -7160,6 +7403,63 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7160
7403
  };
7161
7404
  Relationships: [];
7162
7405
  };
7406
+ product_bom_items: {
7407
+ Row: {
7408
+ component_product_id: string | null;
7409
+ component_trade_item_floriday_id: string | null;
7410
+ created_at: string;
7411
+ id: string;
7412
+ notes: string | null;
7413
+ parent_product_id: string | null;
7414
+ parent_trade_item_floriday_id: string | null;
7415
+ quantity: number;
7416
+ sort_order: number;
7417
+ tenant_id: string;
7418
+ unit: string;
7419
+ updated_at: string;
7420
+ };
7421
+ Insert: {
7422
+ component_product_id?: string | null;
7423
+ component_trade_item_floriday_id?: string | null;
7424
+ created_at?: string;
7425
+ id?: string;
7426
+ notes?: string | null;
7427
+ parent_product_id?: string | null;
7428
+ parent_trade_item_floriday_id?: string | null;
7429
+ quantity?: number;
7430
+ sort_order?: number;
7431
+ tenant_id: string;
7432
+ unit?: string;
7433
+ updated_at?: string;
7434
+ };
7435
+ Update: {
7436
+ component_product_id?: string | null;
7437
+ component_trade_item_floriday_id?: string | null;
7438
+ created_at?: string;
7439
+ id?: string;
7440
+ notes?: string | null;
7441
+ parent_product_id?: string | null;
7442
+ parent_trade_item_floriday_id?: string | null;
7443
+ quantity?: number;
7444
+ sort_order?: number;
7445
+ tenant_id?: string;
7446
+ unit?: string;
7447
+ updated_at?: string;
7448
+ };
7449
+ Relationships: [{
7450
+ foreignKeyName: "product_bom_items_component_product_id_fkey";
7451
+ columns: ["component_product_id"];
7452
+ isOneToOne: false;
7453
+ referencedRelation: "products";
7454
+ referencedColumns: ["id"];
7455
+ }, {
7456
+ foreignKeyName: "product_bom_items_parent_product_id_fkey";
7457
+ columns: ["parent_product_id"];
7458
+ isOneToOne: false;
7459
+ referencedRelation: "products";
7460
+ referencedColumns: ["id"];
7461
+ }];
7462
+ };
7163
7463
  product_categories: {
7164
7464
  Row: {
7165
7465
  color: string;
@@ -7265,6 +7565,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7265
7565
  id: string;
7266
7566
  product_group_id: string;
7267
7567
  quantity: number;
7568
+ sort_order: number;
7268
7569
  trade_item_id: string;
7269
7570
  };
7270
7571
  Insert: {
@@ -7272,6 +7573,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7272
7573
  id?: string;
7273
7574
  product_group_id: string;
7274
7575
  quantity?: number;
7576
+ sort_order?: number;
7275
7577
  trade_item_id: string;
7276
7578
  };
7277
7579
  Update: {
@@ -7279,6 +7581,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7279
7581
  id?: string;
7280
7582
  product_group_id?: string;
7281
7583
  quantity?: number;
7584
+ sort_order?: number;
7282
7585
  trade_item_id?: string;
7283
7586
  };
7284
7587
  Relationships: [{
@@ -7293,6 +7596,8 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7293
7596
  Row: {
7294
7597
  created_at: string;
7295
7598
  description: string | null;
7599
+ head_product_id: string | null;
7600
+ head_trade_item_floriday_id: string | null;
7296
7601
  id: string;
7297
7602
  is_active: boolean;
7298
7603
  name: string;
@@ -7302,6 +7607,8 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7302
7607
  Insert: {
7303
7608
  created_at?: string;
7304
7609
  description?: string | null;
7610
+ head_product_id?: string | null;
7611
+ head_trade_item_floriday_id?: string | null;
7305
7612
  id?: string;
7306
7613
  is_active?: boolean;
7307
7614
  name: string;
@@ -7311,16 +7618,85 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7311
7618
  Update: {
7312
7619
  created_at?: string;
7313
7620
  description?: string | null;
7621
+ head_product_id?: string | null;
7622
+ head_trade_item_floriday_id?: string | null;
7314
7623
  id?: string;
7315
7624
  is_active?: boolean;
7316
7625
  name?: string;
7317
7626
  tenant_id?: string;
7318
7627
  updated_at?: string;
7319
7628
  };
7320
- Relationships: [];
7629
+ Relationships: [{
7630
+ foreignKeyName: "product_groups_head_product_id_fkey";
7631
+ columns: ["head_product_id"];
7632
+ isOneToOne: false;
7633
+ referencedRelation: "products";
7634
+ referencedColumns: ["id"];
7635
+ }];
7636
+ };
7637
+ product_load_settings: {
7638
+ Row: {
7639
+ created_at: string;
7640
+ id: string;
7641
+ is_package: boolean;
7642
+ layers_per_load_carrier: number | null;
7643
+ load_carrier: string | null;
7644
+ package_id: string | null;
7645
+ package_label: string | null;
7646
+ packages_per_layer: number | null;
7647
+ product_id: string | null;
7648
+ tenant_id: string;
7649
+ trade_item_floriday_id: string | null;
7650
+ units_per_package: number | null;
7651
+ updated_at: string;
7652
+ };
7653
+ Insert: {
7654
+ created_at?: string;
7655
+ id?: string;
7656
+ is_package?: boolean;
7657
+ layers_per_load_carrier?: number | null;
7658
+ load_carrier?: string | null;
7659
+ package_id?: string | null;
7660
+ package_label?: string | null;
7661
+ packages_per_layer?: number | null;
7662
+ product_id?: string | null;
7663
+ tenant_id: string;
7664
+ trade_item_floriday_id?: string | null;
7665
+ units_per_package?: number | null;
7666
+ updated_at?: string;
7667
+ };
7668
+ Update: {
7669
+ created_at?: string;
7670
+ id?: string;
7671
+ is_package?: boolean;
7672
+ layers_per_load_carrier?: number | null;
7673
+ load_carrier?: string | null;
7674
+ package_id?: string | null;
7675
+ package_label?: string | null;
7676
+ packages_per_layer?: number | null;
7677
+ product_id?: string | null;
7678
+ tenant_id?: string;
7679
+ trade_item_floriday_id?: string | null;
7680
+ units_per_package?: number | null;
7681
+ updated_at?: string;
7682
+ };
7683
+ Relationships: [{
7684
+ foreignKeyName: "product_load_settings_package_id_fkey";
7685
+ columns: ["package_id"];
7686
+ isOneToOne: false;
7687
+ referencedRelation: "packages";
7688
+ referencedColumns: ["id"];
7689
+ }, {
7690
+ foreignKeyName: "product_load_settings_product_id_fkey";
7691
+ columns: ["product_id"];
7692
+ isOneToOne: false;
7693
+ referencedRelation: "products";
7694
+ referencedColumns: ["id"];
7695
+ }];
7321
7696
  };
7322
7697
  products: {
7323
7698
  Row: {
7699
+ article_number: string | null;
7324
7700
  barcode: string | null;
7325
7701
  batch: string;
7326
7702
  crates_per_layer: number;
@@ -7344,6 +7720,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7344
7720
  weight: string | null;
7345
7721
  };
7346
7722
  Insert: {
7723
+ article_number?: string | null;
7347
7724
  barcode?: string | null;
7348
7725
  batch: string;
7349
7726
  crates_per_layer?: number;
@@ -7367,6 +7744,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
7367
7744
  weight?: string | null;
7368
7745
  };
7369
7746
  Update: {
7747
+ article_number?: string | null;
7370
7748
  barcode?: string | null;
7371
7749
  batch?: string;
7372
7750
  crates_per_layer?: number;
@@ -8280,8 +8658,10 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8280
8658
  order_id: string | null;
8281
8659
  order_item_id: string | null;
8282
8660
  order_source: string | null;
8661
+ parent_trade_item_key: string | null;
8283
8662
  physical_after: number | null;
8284
8663
  physical_before: number | null;
8664
+ production_batch_id: string | null;
8285
8665
  qty_delta: number;
8286
8666
  reason: string | null;
8287
8667
  reserved_after: number | null;
@@ -8297,8 +8677,10 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8297
8677
  order_id?: string | null;
8298
8678
  order_item_id?: string | null;
8299
8679
  order_source?: string | null;
8680
+ parent_trade_item_key?: string | null;
8300
8681
  physical_after?: number | null;
8301
8682
  physical_before?: number | null;
8683
+ production_batch_id?: string | null;
8302
8684
  qty_delta: number;
8303
8685
  reason?: string | null;
8304
8686
  reserved_after?: number | null;
@@ -8314,8 +8696,10 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8314
8696
  order_id?: string | null;
8315
8697
  order_item_id?: string | null;
8316
8698
  order_source?: string | null;
8699
+ parent_trade_item_key?: string | null;
8317
8700
  physical_after?: number | null;
8318
8701
  physical_before?: number | null;
8702
+ production_batch_id?: string | null;
8319
8703
  qty_delta?: number;
8320
8704
  reason?: string | null;
8321
8705
  reserved_after?: number | null;
@@ -8774,7 +9158,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8774
9158
  twinfield_connections: {
8775
9159
  Row: {
8776
9160
  access_token: string | null;
8777
- client_id: string;
9161
+ client_id: string | null;
8778
9162
  client_secret: string | null;
8779
9163
  cluster_uri: string | null;
8780
9164
  company_code: string | null;
@@ -8786,7 +9170,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8786
9170
  is_active: boolean;
8787
9171
  label: string | null;
8788
9172
  office_code: string | null;
8789
- redirect_uri: string;
9173
+ redirect_uri: string | null;
8790
9174
  refresh_token: string | null;
8791
9175
  token_expires_at: string | null;
8792
9176
  updated_at: string;
@@ -8794,7 +9178,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8794
9178
  };
8795
9179
  Insert: {
8796
9180
  access_token?: string | null;
8797
- client_id: string;
9181
+ client_id?: string | null;
8798
9182
  client_secret?: string | null;
8799
9183
  cluster_uri?: string | null;
8800
9184
  company_code?: string | null;
@@ -8806,7 +9190,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8806
9190
  is_active?: boolean;
8807
9191
  label?: string | null;
8808
9192
  office_code?: string | null;
8809
- redirect_uri: string;
9193
+ redirect_uri?: string | null;
8810
9194
  refresh_token?: string | null;
8811
9195
  token_expires_at?: string | null;
8812
9196
  updated_at?: string;
@@ -8814,7 +9198,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8814
9198
  };
8815
9199
  Update: {
8816
9200
  access_token?: string | null;
8817
- client_id?: string;
9201
+ client_id?: string | null;
8818
9202
  client_secret?: string | null;
8819
9203
  cluster_uri?: string | null;
8820
9204
  company_code?: string | null;
@@ -8826,7 +9210,7 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
8826
9210
  is_active?: boolean;
8827
9211
  label?: string | null;
8828
9212
  office_code?: string | null;
8829
- redirect_uri?: string;
9213
+ redirect_uri?: string | null;
8830
9214
  refresh_token?: string | null;
8831
9215
  token_expires_at?: string | null;
8832
9216
  updated_at?: string;
@@ -10021,25 +10405,6 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10021
10405
  };
10022
10406
  Relationships: [];
10023
10407
  };
10024
- floriday_customer_discounts: {
10025
- Row: {
10026
- base_price: number | null;
10027
- buyer_organization_id: string | null;
10028
- currency: string | null;
10029
- discount_type: string | null;
10030
- discount_value: number | null;
10031
- min_quantity: number | null;
10032
- net_price: number | null;
10033
- product_group_id: string | null;
10034
- raw: import("./types").Json | null;
10035
- source: string | null;
10036
- source_id: string | null;
10037
- trade_item_id: string | null;
10038
- valid_from: string | null;
10039
- valid_until: string | null;
10040
- };
10041
- Relationships: [];
10042
- };
10043
10408
  local_customer_discounts: {
10044
10409
  Row: {
10045
10410
  base_price: number | null;
@@ -10458,6 +10823,28 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10458
10823
  Args: never;
10459
10824
  Returns: undefined;
10460
10825
  };
10826
+ consume_bom_for_production: {
10827
+ Args: {
10828
+ p_connection_id: string;
10829
+ p_parent_id: string;
10830
+ p_parent_key: string;
10831
+ p_parent_kind: string;
10832
+ p_quantity: number;
10833
+ p_user_id: string;
10834
+ };
10835
+ Returns: import("./types").Json;
10836
+ } | {
10837
+ Args: {
10838
+ p_batch_id?: string;
10839
+ p_connection_id: string;
10840
+ p_parent_id: string;
10841
+ p_parent_key: string;
10842
+ p_parent_kind: string;
10843
+ p_quantity: number;
10844
+ p_user_id: string;
10845
+ };
10846
+ Returns: import("./types").Json;
10847
+ };
10461
10848
  consume_floriday_rate_limit: {
10462
10849
  Args: {
10463
10850
  p_bucket: string;
@@ -10509,6 +10896,13 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10509
10896
  table_name: string;
10510
10897
  }[];
10511
10898
  };
10899
+ delete_samenstelling: {
10900
+ Args: {
10901
+ p_parent_id: string;
10902
+ p_parent_kind: string;
10903
+ };
10904
+ Returns: import("./types").Json;
10905
+ };
10512
10906
  dispatch_carrier_signups_sql: {
10513
10907
  Args: {
10514
10908
  _catchup?: string;
@@ -10669,19 +11063,6 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10669
11063
  resource: string;
10670
11064
  }[];
10671
11065
  };
10672
- get_floriday_agreements_active: {
10673
- Args: {
10674
- p_on_date?: string;
10675
- };
10676
- Returns: {
10677
- buyer_organization_id: string;
10678
- data: import("./types").Json;
10679
- floriday_id: string;
10680
- status: string;
10681
- valid_from: string;
10682
- valid_until: string;
10683
- }[];
10684
- };
10685
11066
  get_floriday_clock_supplies_window: {
10686
11067
  Args: {
10687
11068
  p_from: string;
@@ -10754,6 +11135,21 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10754
11135
  minutes_since_success: number;
10755
11136
  }[];
10756
11137
  };
11138
+ get_group_allocation_keys: {
11139
+ Args: {
11140
+ p_product_id: string;
11141
+ };
11142
+ Returns: {
11143
+ k: string;
11144
+ ord: number;
11145
+ }[];
11146
+ };
11147
+ get_group_head_key: {
11148
+ Args: {
11149
+ p_group_id: string;
11150
+ };
11151
+ Returns: string;
11152
+ };
10757
11153
  get_offer_by_link_code: {
10758
11154
  Args: {
10759
11155
  p_code: string;
@@ -10864,6 +11260,18 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10864
11260
  };
10865
11261
  Returns: undefined;
10866
11262
  };
11263
+ mark_shipment_shipped: {
11264
+ Args: {
11265
+ p_shipment_id: string;
11266
+ };
11267
+ Returns: undefined;
11268
+ };
11269
+ next_manufacture_partij: {
11270
+ Args: {
11271
+ _tenant_id: string;
11272
+ };
11273
+ Returns: string;
11274
+ };
10867
11275
  next_order_number: {
10868
11276
  Args: {
10869
11277
  p_prefix: string;
@@ -10942,6 +11350,14 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10942
11350
  };
10943
11351
  Returns: undefined;
10944
11352
  };
11353
+ produce_designed_product: {
11354
+ Args: {
11355
+ p_parent_id: string;
11356
+ p_parent_kind: string;
11357
+ p_quantity: number;
11358
+ };
11359
+ Returns: import("./types").Json;
11360
+ };
10945
11361
  promote_trade_item_key: {
10946
11362
  Args: {
10947
11363
  p_new: string;
@@ -10949,6 +11365,10 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10949
11365
  };
10950
11366
  Returns: undefined;
10951
11367
  };
11368
+ recompute_all_reserved_stock: {
11369
+ Args: never;
11370
+ Returns: undefined;
11371
+ };
10952
11372
  recompute_order_status: {
10953
11373
  Args: {
10954
11374
  p_order_id: string;
@@ -10998,27 +11418,45 @@ export declare const requireSupabaseAuth: import("@tanstack/start-client-core").
10998
11418
  };
10999
11419
  Returns: undefined;
11000
11420
  };
11421
+ resolve_group_allocation: {
11422
+ Args: {
11423
+ _needed: number;
11424
+ _product_group_id: string;
11425
+ };
11426
+ Returns: {
11427
+ allocated: number;
11428
+ trade_item_id: string;
11429
+ }[];
11430
+ };
11431
+ resolve_group_member_stock_key: {
11432
+ Args: {
11433
+ p_trade_item_id: string;
11434
+ };
11435
+ Returns: string;
11436
+ };
11001
11437
  resolve_product_id_for_item: {
11002
11438
  Args: {
11003
11439
  p_product_name: string;
11004
11440
  };
11005
11441
  Returns: string;
11006
11442
  };
11007
- schedule_floriday_additional_services_sync: {
11443
+ resolve_stock_trade_item_key: {
11008
11444
  Args: {
11009
- p_apikey: string;
11010
- p_url: string;
11445
+ p_product_id: string;
11011
11446
  };
11012
- Returns: number;
11447
+ Returns: string;
11013
11448
  };
11014
- schedule_floriday_agreement_calloffs_sync: {
11449
+ reverse_production: {
11015
11450
  Args: {
11016
- p_apikey: string;
11017
- p_url: string;
11451
+ p_connection_id?: string;
11452
+ p_parent_key: string;
11453
+ p_quantity: number;
11454
+ p_reason?: string;
11455
+ p_user_id?: string;
11018
11456
  };
11019
- Returns: number;
11457
+ Returns: import("./types").Json;
11020
11458
  };
11021
- schedule_floriday_agreements_sync: {
11459
+ schedule_floriday_additional_services_sync: {
11022
11460
  Args: {
11023
11461
  p_apikey: string;
11024
11462
  p_url: string;