@flowselections/floriday-verkoop-module 1.0.17 → 1.0.19

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 (57) hide show
  1. package/dist-lib/components/verkoop/CreateOrderPage.d.ts.map +1 -1
  2. package/dist-lib/components/verkoop/CreateOrderPage.js +6 -4
  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/SalesOrdersTable.d.ts +4 -1
  16. package/dist-lib/components/verkoop/SalesOrdersTable.d.ts.map +1 -1
  17. package/dist-lib/components/verkoop/SalesOrdersTable.js +2 -2
  18. package/dist-lib/components/verkoop/VerkoopOrdersPage.d.ts.map +1 -1
  19. package/dist-lib/components/verkoop/VerkoopOrdersPage.js +43 -1
  20. package/dist-lib/integrations/supabase/auth-middleware.d.ts +436 -149
  21. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  22. package/dist-lib/integrations/supabase/client.d.ts +436 -149
  23. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  24. package/dist-lib/integrations/supabase/client.server.d.ts +436 -149
  25. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  26. package/dist-lib/integrations/supabase/types.d.ts +452 -153
  27. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  28. package/dist-lib/lib/cart-lock.functions.d.ts +436 -149
  29. package/dist-lib/lib/cart-lock.functions.d.ts.map +1 -1
  30. package/dist-lib/lib/cart-replan.functions.d.ts +884 -310
  31. package/dist-lib/lib/cart-replan.functions.d.ts.map +1 -1
  32. package/dist-lib/lib/create-order.functions.d.ts +39491 -1379
  33. package/dist-lib/lib/create-order.functions.d.ts.map +1 -1
  34. package/dist-lib/lib/create-order.functions.js +814 -64
  35. package/dist-lib/lib/expand-group-order-items.d.ts +13 -0
  36. package/dist-lib/lib/expand-group-order-items.d.ts.map +1 -0
  37. package/dist-lib/lib/expand-group-order-items.js +216 -0
  38. package/dist-lib/lib/floriday-auto-fulfillment.functions.d.ts +1321 -460
  39. package/dist-lib/lib/floriday-auto-fulfillment.functions.d.ts.map +1 -1
  40. package/dist-lib/lib/floriday-logistic-labels.functions.d.ts +436 -149
  41. package/dist-lib/lib/floriday-logistic-labels.functions.d.ts.map +1 -1
  42. package/dist-lib/lib/floriday-public.functions.d.ts +3052 -1043
  43. package/dist-lib/lib/floriday-public.functions.d.ts.map +1 -1
  44. package/dist-lib/lib/floriday-writes.functions.d.ts +2180 -745
  45. package/dist-lib/lib/floriday-writes.functions.d.ts.map +1 -1
  46. package/dist-lib/lib/order-shipments.functions.d.ts +47382 -0
  47. package/dist-lib/lib/order-shipments.functions.d.ts.map +1 -0
  48. package/dist-lib/lib/order-shipments.functions.js +178 -0
  49. package/dist-lib/lib/salesorders-mapping.d.ts +1 -0
  50. package/dist-lib/lib/salesorders-mapping.d.ts.map +1 -1
  51. package/dist-lib/lib/salesorders.functions.d.ts +1321 -460
  52. package/dist-lib/lib/salesorders.functions.d.ts.map +1 -1
  53. package/dist-lib/lib/tradeitems.functions.d.ts +436 -149
  54. package/dist-lib/lib/tradeitems.functions.d.ts.map +1 -1
  55. package/dist-lib/lib/useSalesOrdersQuery.d.ts.map +1 -1
  56. package/dist-lib/lib/useSalesOrdersQuery.js +39 -2
  57. package/package.json +2 -2
@@ -3406,105 +3406,6 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
3406
3406
  referencedColumns: ["id"];
3407
3407
  }];
3408
3408
  };
3409
- floriday_agreement_calloffs_cache: {
3410
- Row: {
3411
- agreement_id: string | null;
3412
- connection_id: string;
3413
- data: import("../integrations/supabase/types").Json;
3414
- delivery_date: string | null;
3415
- fetched_at: string;
3416
- floriday_id: string;
3417
- id: string;
3418
- is_deleted: boolean;
3419
- sequence_number: number;
3420
- status: string | null;
3421
- updated_at: string;
3422
- };
3423
- Insert: {
3424
- agreement_id?: string | null;
3425
- connection_id: string;
3426
- data?: import("../integrations/supabase/types").Json;
3427
- delivery_date?: string | null;
3428
- fetched_at?: string;
3429
- floriday_id: string;
3430
- id?: string;
3431
- is_deleted?: boolean;
3432
- sequence_number?: number;
3433
- status?: string | null;
3434
- updated_at?: string;
3435
- };
3436
- Update: {
3437
- agreement_id?: string | null;
3438
- connection_id?: string;
3439
- data?: import("../integrations/supabase/types").Json;
3440
- delivery_date?: string | null;
3441
- fetched_at?: string;
3442
- floriday_id?: string;
3443
- id?: string;
3444
- is_deleted?: boolean;
3445
- sequence_number?: number;
3446
- status?: string | null;
3447
- updated_at?: string;
3448
- };
3449
- Relationships: [{
3450
- foreignKeyName: "floriday_agreement_calloffs_cache_connection_id_fkey";
3451
- columns: ["connection_id"];
3452
- isOneToOne: false;
3453
- referencedRelation: "floriday_connections";
3454
- referencedColumns: ["id"];
3455
- }];
3456
- };
3457
- floriday_agreements_cache: {
3458
- Row: {
3459
- buyer_organization_id: string | null;
3460
- connection_id: string;
3461
- data: import("../integrations/supabase/types").Json;
3462
- fetched_at: string;
3463
- floriday_id: string;
3464
- id: string;
3465
- is_deleted: boolean;
3466
- sequence_number: number;
3467
- status: string | null;
3468
- updated_at: string;
3469
- valid_from: string | null;
3470
- valid_until: string | null;
3471
- };
3472
- Insert: {
3473
- buyer_organization_id?: string | null;
3474
- connection_id: string;
3475
- data?: import("../integrations/supabase/types").Json;
3476
- fetched_at?: string;
3477
- floriday_id: string;
3478
- id?: string;
3479
- is_deleted?: boolean;
3480
- sequence_number?: number;
3481
- status?: string | null;
3482
- updated_at?: string;
3483
- valid_from?: string | null;
3484
- valid_until?: string | null;
3485
- };
3486
- Update: {
3487
- buyer_organization_id?: string | null;
3488
- connection_id?: string;
3489
- data?: import("../integrations/supabase/types").Json;
3490
- fetched_at?: string;
3491
- floriday_id?: string;
3492
- id?: string;
3493
- is_deleted?: boolean;
3494
- sequence_number?: number;
3495
- status?: string | null;
3496
- updated_at?: string;
3497
- valid_from?: string | null;
3498
- valid_until?: string | null;
3499
- };
3500
- Relationships: [{
3501
- foreignKeyName: "floriday_agreements_cache_connection_id_fkey";
3502
- columns: ["connection_id"];
3503
- isOneToOne: false;
3504
- referencedRelation: "floriday_connections";
3505
- referencedColumns: ["id"];
3506
- }];
3507
- };
3508
3409
  floriday_auction_letters_cache: {
3509
3410
  Row: {
3510
3411
  auction_letter_code: string;
@@ -5002,6 +4903,45 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
5002
4903
  referencedColumns: ["id"];
5003
4904
  }];
5004
4905
  };
4906
+ floriday_trade_settings_customers_cache: {
4907
+ Row: {
4908
+ connection_id: string;
4909
+ data: import("../integrations/supabase/types").Json;
4910
+ fetched_at: string;
4911
+ floriday_id: string;
4912
+ id: string;
4913
+ is_deleted: boolean;
4914
+ sequence_number: number;
4915
+ updated_at: string;
4916
+ };
4917
+ Insert: {
4918
+ connection_id: string;
4919
+ data: import("../integrations/supabase/types").Json;
4920
+ fetched_at?: string;
4921
+ floriday_id: string;
4922
+ id?: string;
4923
+ is_deleted?: boolean;
4924
+ sequence_number?: number;
4925
+ updated_at?: string;
4926
+ };
4927
+ Update: {
4928
+ connection_id?: string;
4929
+ data?: import("../integrations/supabase/types").Json;
4930
+ fetched_at?: string;
4931
+ floriday_id?: string;
4932
+ id?: string;
4933
+ is_deleted?: boolean;
4934
+ sequence_number?: number;
4935
+ updated_at?: string;
4936
+ };
4937
+ Relationships: [{
4938
+ foreignKeyName: "floriday_trade_settings_customers_cache_connection_id_fkey";
4939
+ columns: ["connection_id"];
4940
+ isOneToOne: false;
4941
+ referencedRelation: "floriday_connections";
4942
+ referencedColumns: ["id"];
4943
+ }];
4944
+ };
5005
4945
  floriday_trips_cache: {
5006
4946
  Row: {
5007
4947
  carrier_organization_id: string | null;
@@ -7174,6 +7114,105 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7174
7114
  };
7175
7115
  Relationships: [];
7176
7116
  };
7117
+ order_shipment_items: {
7118
+ Row: {
7119
+ created_at: string;
7120
+ id: string;
7121
+ order_item_id: string;
7122
+ product_id: string | null;
7123
+ product_name: string;
7124
+ quantity: number;
7125
+ shipment_id: string;
7126
+ updated_at: string;
7127
+ };
7128
+ Insert: {
7129
+ created_at?: string;
7130
+ id?: string;
7131
+ order_item_id: string;
7132
+ product_id?: string | null;
7133
+ product_name: string;
7134
+ quantity: number;
7135
+ shipment_id: string;
7136
+ updated_at?: string;
7137
+ };
7138
+ Update: {
7139
+ created_at?: string;
7140
+ id?: string;
7141
+ order_item_id?: string;
7142
+ product_id?: string | null;
7143
+ product_name?: string;
7144
+ quantity?: number;
7145
+ shipment_id?: string;
7146
+ updated_at?: string;
7147
+ };
7148
+ Relationships: [{
7149
+ foreignKeyName: "order_shipment_items_order_item_id_fkey";
7150
+ columns: ["order_item_id"];
7151
+ isOneToOne: false;
7152
+ referencedRelation: "order_items";
7153
+ referencedColumns: ["id"];
7154
+ }, {
7155
+ foreignKeyName: "order_shipment_items_shipment_id_fkey";
7156
+ columns: ["shipment_id"];
7157
+ isOneToOne: false;
7158
+ referencedRelation: "order_shipments";
7159
+ referencedColumns: ["id"];
7160
+ }];
7161
+ };
7162
+ order_shipments: {
7163
+ Row: {
7164
+ carrier_id: string | null;
7165
+ created_at: string;
7166
+ delivery_date: string | null;
7167
+ delivery_location_id: string | null;
7168
+ id: string;
7169
+ notes: string | null;
7170
+ order_id: string;
7171
+ shipment_number: number;
7172
+ shipped_at: string | null;
7173
+ status: string;
7174
+ updated_at: string;
7175
+ };
7176
+ Insert: {
7177
+ carrier_id?: string | null;
7178
+ created_at?: string;
7179
+ delivery_date?: string | null;
7180
+ delivery_location_id?: string | null;
7181
+ id?: string;
7182
+ notes?: string | null;
7183
+ order_id: string;
7184
+ shipment_number: number;
7185
+ shipped_at?: string | null;
7186
+ status?: string;
7187
+ updated_at?: string;
7188
+ };
7189
+ Update: {
7190
+ carrier_id?: string | null;
7191
+ created_at?: string;
7192
+ delivery_date?: string | null;
7193
+ delivery_location_id?: string | null;
7194
+ id?: string;
7195
+ notes?: string | null;
7196
+ order_id?: string;
7197
+ shipment_number?: number;
7198
+ shipped_at?: string | null;
7199
+ status?: string;
7200
+ updated_at?: string;
7201
+ };
7202
+ Relationships: [{
7203
+ foreignKeyName: "order_shipments_carrier_id_fkey";
7204
+ columns: ["carrier_id"];
7205
+ isOneToOne: false;
7206
+ referencedRelation: "carriers";
7207
+ referencedColumns: ["id"];
7208
+ }, {
7209
+ foreignKeyName: "order_shipments_order_id_fkey";
7210
+ columns: ["order_id"];
7211
+ isOneToOne: false;
7212
+ referencedRelation: "orders";
7213
+ referencedColumns: ["id"];
7214
+ }];
7215
+ };
7177
7216
  orders: {
7178
7217
  Row: {
7179
7218
  created_at: string;
@@ -7181,8 +7220,9 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7181
7220
  customer_id: string | null;
7182
7221
  customer_name: string;
7183
7222
  deleted_at: string | null;
7184
- delivery_date: string;
7223
+ delivery_date: string | null;
7185
7224
  id: string;
7225
+ is_reservation: boolean;
7186
7226
  notes: string | null;
7187
7227
  order_date: string;
7188
7228
  order_number: string;
@@ -7199,8 +7239,9 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7199
7239
  customer_id?: string | null;
7200
7240
  customer_name?: string;
7201
7241
  deleted_at?: string | null;
7202
- delivery_date: string;
7242
+ delivery_date?: string | null;
7203
7243
  id?: string;
7244
+ is_reservation?: boolean;
7204
7245
  notes?: string | null;
7205
7246
  order_date?: string;
7206
7247
  order_number: string;
@@ -7217,8 +7258,9 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7217
7258
  customer_id?: string | null;
7218
7259
  customer_name?: string;
7219
7260
  deleted_at?: string | null;
7220
- delivery_date?: string;
7261
+ delivery_date?: string | null;
7221
7262
  id?: string;
7263
+ is_reservation?: boolean;
7222
7264
  notes?: string | null;
7223
7265
  order_date?: string;
7224
7266
  order_number?: string;
@@ -7360,6 +7402,63 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7360
7402
  };
7361
7403
  Relationships: [];
7362
7404
  };
7405
+ product_bom_items: {
7406
+ Row: {
7407
+ component_product_id: string | null;
7408
+ component_trade_item_floriday_id: string | null;
7409
+ created_at: string;
7410
+ id: string;
7411
+ notes: string | null;
7412
+ parent_product_id: string | null;
7413
+ parent_trade_item_floriday_id: string | null;
7414
+ quantity: number;
7415
+ sort_order: number;
7416
+ tenant_id: string;
7417
+ unit: string;
7418
+ updated_at: string;
7419
+ };
7420
+ Insert: {
7421
+ component_product_id?: string | null;
7422
+ component_trade_item_floriday_id?: string | null;
7423
+ created_at?: string;
7424
+ id?: string;
7425
+ notes?: string | null;
7426
+ parent_product_id?: string | null;
7427
+ parent_trade_item_floriday_id?: string | null;
7428
+ quantity?: number;
7429
+ sort_order?: number;
7430
+ tenant_id: string;
7431
+ unit?: string;
7432
+ updated_at?: string;
7433
+ };
7434
+ Update: {
7435
+ component_product_id?: string | null;
7436
+ component_trade_item_floriday_id?: string | null;
7437
+ created_at?: string;
7438
+ id?: string;
7439
+ notes?: string | null;
7440
+ parent_product_id?: string | null;
7441
+ parent_trade_item_floriday_id?: string | null;
7442
+ quantity?: number;
7443
+ sort_order?: number;
7444
+ tenant_id?: string;
7445
+ unit?: string;
7446
+ updated_at?: string;
7447
+ };
7448
+ Relationships: [{
7449
+ foreignKeyName: "product_bom_items_component_product_id_fkey";
7450
+ columns: ["component_product_id"];
7451
+ isOneToOne: false;
7452
+ referencedRelation: "products";
7453
+ referencedColumns: ["id"];
7454
+ }, {
7455
+ foreignKeyName: "product_bom_items_parent_product_id_fkey";
7456
+ columns: ["parent_product_id"];
7457
+ isOneToOne: false;
7458
+ referencedRelation: "products";
7459
+ referencedColumns: ["id"];
7460
+ }];
7461
+ };
7363
7462
  product_categories: {
7364
7463
  Row: {
7365
7464
  color: string;
@@ -7465,6 +7564,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7465
7564
  id: string;
7466
7565
  product_group_id: string;
7467
7566
  quantity: number;
7567
+ sort_order: number;
7468
7568
  trade_item_id: string;
7469
7569
  };
7470
7570
  Insert: {
@@ -7472,6 +7572,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7472
7572
  id?: string;
7473
7573
  product_group_id: string;
7474
7574
  quantity?: number;
7575
+ sort_order?: number;
7475
7576
  trade_item_id: string;
7476
7577
  };
7477
7578
  Update: {
@@ -7479,6 +7580,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7479
7580
  id?: string;
7480
7581
  product_group_id?: string;
7481
7582
  quantity?: number;
7583
+ sort_order?: number;
7482
7584
  trade_item_id?: string;
7483
7585
  };
7484
7586
  Relationships: [{
@@ -7493,6 +7595,8 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7493
7595
  Row: {
7494
7596
  created_at: string;
7495
7597
  description: string | null;
7598
+ head_product_id: string | null;
7599
+ head_trade_item_floriday_id: string | null;
7496
7600
  id: string;
7497
7601
  is_active: boolean;
7498
7602
  name: string;
@@ -7502,6 +7606,8 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7502
7606
  Insert: {
7503
7607
  created_at?: string;
7504
7608
  description?: string | null;
7609
+ head_product_id?: string | null;
7610
+ head_trade_item_floriday_id?: string | null;
7505
7611
  id?: string;
7506
7612
  is_active?: boolean;
7507
7613
  name: string;
@@ -7511,21 +7617,126 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7511
7617
  Update: {
7512
7618
  created_at?: string;
7513
7619
  description?: string | null;
7620
+ head_product_id?: string | null;
7621
+ head_trade_item_floriday_id?: string | null;
7514
7622
  id?: string;
7515
7623
  is_active?: boolean;
7516
7624
  name?: string;
7517
7625
  tenant_id?: string;
7518
7626
  updated_at?: string;
7519
7627
  };
7628
+ Relationships: [{
7629
+ foreignKeyName: "product_groups_head_product_id_fkey";
7630
+ columns: ["head_product_id"];
7631
+ isOneToOne: false;
7632
+ referencedRelation: "products";
7633
+ referencedColumns: ["id"];
7634
+ }];
7635
+ };
7636
+ product_load_settings: {
7637
+ Row: {
7638
+ created_at: string;
7639
+ id: string;
7640
+ is_package: boolean;
7641
+ layers_per_load_carrier: number | null;
7642
+ load_carrier: string | null;
7643
+ package_id: string | null;
7644
+ package_label: string | null;
7645
+ packages_per_layer: number | null;
7646
+ product_id: string | null;
7647
+ tenant_id: string;
7648
+ trade_item_floriday_id: string | null;
7649
+ units_per_package: number | null;
7650
+ updated_at: string;
7651
+ };
7652
+ Insert: {
7653
+ created_at?: string;
7654
+ id?: string;
7655
+ is_package?: boolean;
7656
+ layers_per_load_carrier?: number | null;
7657
+ load_carrier?: string | null;
7658
+ package_id?: string | null;
7659
+ package_label?: string | null;
7660
+ packages_per_layer?: number | null;
7661
+ product_id?: string | null;
7662
+ tenant_id: string;
7663
+ trade_item_floriday_id?: string | null;
7664
+ units_per_package?: number | null;
7665
+ updated_at?: string;
7666
+ };
7667
+ Update: {
7668
+ created_at?: string;
7669
+ id?: string;
7670
+ is_package?: boolean;
7671
+ layers_per_load_carrier?: number | null;
7672
+ load_carrier?: string | null;
7673
+ package_id?: string | null;
7674
+ package_label?: string | null;
7675
+ packages_per_layer?: number | null;
7676
+ product_id?: string | null;
7677
+ tenant_id?: string;
7678
+ trade_item_floriday_id?: string | null;
7679
+ units_per_package?: number | null;
7680
+ updated_at?: string;
7681
+ };
7682
+ Relationships: [{
7683
+ foreignKeyName: "product_load_settings_package_id_fkey";
7684
+ columns: ["package_id"];
7685
+ isOneToOne: false;
7686
+ referencedRelation: "packages";
7687
+ referencedColumns: ["id"];
7688
+ }, {
7689
+ foreignKeyName: "product_load_settings_product_id_fkey";
7690
+ columns: ["product_id"];
7691
+ isOneToOne: false;
7692
+ referencedRelation: "products";
7693
+ referencedColumns: ["id"];
7694
+ }];
7695
+ };
7696
+ product_merge_log: {
7697
+ Row: {
7698
+ canonical_product_id: string | null;
7699
+ id: string;
7700
+ merged_at: string;
7701
+ merged_from_id: string;
7702
+ notes: string | null;
7703
+ snapshot: import("../integrations/supabase/types").Json;
7704
+ source_table: string;
7705
+ status: string;
7706
+ };
7707
+ Insert: {
7708
+ canonical_product_id?: string | null;
7709
+ id?: string;
7710
+ merged_at?: string;
7711
+ merged_from_id: string;
7712
+ notes?: string | null;
7713
+ snapshot?: import("../integrations/supabase/types").Json;
7714
+ source_table: string;
7715
+ status?: string;
7716
+ };
7717
+ Update: {
7718
+ canonical_product_id?: string | null;
7719
+ id?: string;
7720
+ merged_at?: string;
7721
+ merged_from_id?: string;
7722
+ notes?: string | null;
7723
+ snapshot?: import("../integrations/supabase/types").Json;
7724
+ source_table?: string;
7725
+ status?: string;
7726
+ };
7520
7727
  Relationships: [];
7521
7728
  };
7522
7729
  products: {
7523
7730
  Row: {
7731
+ article_number: string | null;
7524
7732
  barcode: string | null;
7525
7733
  batch: string;
7526
7734
  crates_per_layer: number;
7527
7735
  created_at: string;
7528
7736
  custom_fields: import("../integrations/supabase/types").Json;
7737
+ floriday_active: boolean;
7738
+ floriday_payload: import("../integrations/supabase/types").Json;
7739
+ floriday_trade_item_id: string | null;
7529
7740
  id: string;
7530
7741
  image_url: string | null;
7531
7742
  incoming_quantity: number;
@@ -7544,11 +7755,15 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7544
7755
  weight: string | null;
7545
7756
  };
7546
7757
  Insert: {
7758
+ article_number?: string | null;
7547
7759
  barcode?: string | null;
7548
7760
  batch: string;
7549
7761
  crates_per_layer?: number;
7550
7762
  created_at?: string;
7551
7763
  custom_fields?: import("../integrations/supabase/types").Json;
7764
+ floriday_active?: boolean;
7765
+ floriday_payload?: import("../integrations/supabase/types").Json;
7766
+ floriday_trade_item_id?: string | null;
7552
7767
  id?: string;
7553
7768
  image_url?: string | null;
7554
7769
  incoming_quantity?: number;
@@ -7567,11 +7782,15 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
7567
7782
  weight?: string | null;
7568
7783
  };
7569
7784
  Update: {
7785
+ article_number?: string | null;
7570
7786
  barcode?: string | null;
7571
7787
  batch?: string;
7572
7788
  crates_per_layer?: number;
7573
7789
  created_at?: string;
7574
7790
  custom_fields?: import("../integrations/supabase/types").Json;
7791
+ floriday_active?: boolean;
7792
+ floriday_payload?: import("../integrations/supabase/types").Json;
7793
+ floriday_trade_item_id?: string | null;
7575
7794
  id?: string;
7576
7795
  image_url?: string | null;
7577
7796
  incoming_quantity?: number;
@@ -8480,8 +8699,10 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
8480
8699
  order_id: string | null;
8481
8700
  order_item_id: string | null;
8482
8701
  order_source: string | null;
8702
+ parent_trade_item_key: string | null;
8483
8703
  physical_after: number | null;
8484
8704
  physical_before: number | null;
8705
+ production_batch_id: string | null;
8485
8706
  qty_delta: number;
8486
8707
  reason: string | null;
8487
8708
  reserved_after: number | null;
@@ -8497,8 +8718,10 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
8497
8718
  order_id?: string | null;
8498
8719
  order_item_id?: string | null;
8499
8720
  order_source?: string | null;
8721
+ parent_trade_item_key?: string | null;
8500
8722
  physical_after?: number | null;
8501
8723
  physical_before?: number | null;
8724
+ production_batch_id?: string | null;
8502
8725
  qty_delta: number;
8503
8726
  reason?: string | null;
8504
8727
  reserved_after?: number | null;
@@ -8514,8 +8737,10 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
8514
8737
  order_id?: string | null;
8515
8738
  order_item_id?: string | null;
8516
8739
  order_source?: string | null;
8740
+ parent_trade_item_key?: string | null;
8517
8741
  physical_after?: number | null;
8518
8742
  physical_before?: number | null;
8743
+ production_batch_id?: string | null;
8519
8744
  qty_delta?: number;
8520
8745
  reason?: string | null;
8521
8746
  reserved_after?: number | null;
@@ -8974,7 +9199,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
8974
9199
  twinfield_connections: {
8975
9200
  Row: {
8976
9201
  access_token: string | null;
8977
- client_id: string;
9202
+ client_id: string | null;
8978
9203
  client_secret: string | null;
8979
9204
  cluster_uri: string | null;
8980
9205
  company_code: string | null;
@@ -8986,7 +9211,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
8986
9211
  is_active: boolean;
8987
9212
  label: string | null;
8988
9213
  office_code: string | null;
8989
- redirect_uri: string;
9214
+ redirect_uri: string | null;
8990
9215
  refresh_token: string | null;
8991
9216
  token_expires_at: string | null;
8992
9217
  updated_at: string;
@@ -8994,7 +9219,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
8994
9219
  };
8995
9220
  Insert: {
8996
9221
  access_token?: string | null;
8997
- client_id: string;
9222
+ client_id?: string | null;
8998
9223
  client_secret?: string | null;
8999
9224
  cluster_uri?: string | null;
9000
9225
  company_code?: string | null;
@@ -9006,7 +9231,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
9006
9231
  is_active?: boolean;
9007
9232
  label?: string | null;
9008
9233
  office_code?: string | null;
9009
- redirect_uri: string;
9234
+ redirect_uri?: string | null;
9010
9235
  refresh_token?: string | null;
9011
9236
  token_expires_at?: string | null;
9012
9237
  updated_at?: string;
@@ -9014,7 +9239,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
9014
9239
  };
9015
9240
  Update: {
9016
9241
  access_token?: string | null;
9017
- client_id?: string;
9242
+ client_id?: string | null;
9018
9243
  client_secret?: string | null;
9019
9244
  cluster_uri?: string | null;
9020
9245
  company_code?: string | null;
@@ -9026,7 +9251,7 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
9026
9251
  is_active?: boolean;
9027
9252
  label?: string | null;
9028
9253
  office_code?: string | null;
9029
- redirect_uri?: string;
9254
+ redirect_uri?: string | null;
9030
9255
  refresh_token?: string | null;
9031
9256
  token_expires_at?: string | null;
9032
9257
  updated_at?: string;
@@ -10221,25 +10446,6 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
10221
10446
  };
10222
10447
  Relationships: [];
10223
10448
  };
10224
- floriday_customer_discounts: {
10225
- Row: {
10226
- base_price: number | null;
10227
- buyer_organization_id: string | null;
10228
- currency: string | null;
10229
- discount_type: string | null;
10230
- discount_value: number | null;
10231
- min_quantity: number | null;
10232
- net_price: number | null;
10233
- product_group_id: string | null;
10234
- raw: import("../integrations/supabase/types").Json | null;
10235
- source: string | null;
10236
- source_id: string | null;
10237
- trade_item_id: string | null;
10238
- valid_from: string | null;
10239
- valid_until: string | null;
10240
- };
10241
- Relationships: [];
10242
- };
10243
10449
  local_customer_discounts: {
10244
10450
  Row: {
10245
10451
  base_price: number | null;
@@ -10543,6 +10749,13 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
10543
10749
  };
10544
10750
  Returns: number;
10545
10751
  };
10752
+ _migrate_rewrite_stock_key: {
10753
+ Args: {
10754
+ _from_key: string;
10755
+ _to_key: string;
10756
+ };
10757
+ Returns: undefined;
10758
+ };
10546
10759
  afh_city_code: {
10547
10760
  Args: {
10548
10761
  _city: string;
@@ -10658,6 +10871,28 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
10658
10871
  Args: never;
10659
10872
  Returns: undefined;
10660
10873
  };
10874
+ consume_bom_for_production: {
10875
+ Args: {
10876
+ p_connection_id: string;
10877
+ p_parent_id: string;
10878
+ p_parent_key: string;
10879
+ p_parent_kind: string;
10880
+ p_quantity: number;
10881
+ p_user_id: string;
10882
+ };
10883
+ Returns: import("../integrations/supabase/types").Json;
10884
+ } | {
10885
+ Args: {
10886
+ p_batch_id?: string;
10887
+ p_connection_id: string;
10888
+ p_parent_id: string;
10889
+ p_parent_key: string;
10890
+ p_parent_kind: string;
10891
+ p_quantity: number;
10892
+ p_user_id: string;
10893
+ };
10894
+ Returns: import("../integrations/supabase/types").Json;
10895
+ };
10661
10896
  consume_floriday_rate_limit: {
10662
10897
  Args: {
10663
10898
  p_bucket: string;
@@ -10709,6 +10944,13 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
10709
10944
  table_name: string;
10710
10945
  }[];
10711
10946
  };
10947
+ delete_samenstelling: {
10948
+ Args: {
10949
+ p_parent_id: string;
10950
+ p_parent_kind: string;
10951
+ };
10952
+ Returns: import("../integrations/supabase/types").Json;
10953
+ };
10712
10954
  dispatch_carrier_signups_sql: {
10713
10955
  Args: {
10714
10956
  _catchup?: string;
@@ -10869,19 +11111,6 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
10869
11111
  resource: string;
10870
11112
  }[];
10871
11113
  };
10872
- get_floriday_agreements_active: {
10873
- Args: {
10874
- p_on_date?: string;
10875
- };
10876
- Returns: {
10877
- buyer_organization_id: string;
10878
- data: import("../integrations/supabase/types").Json;
10879
- floriday_id: string;
10880
- status: string;
10881
- valid_from: string;
10882
- valid_until: string;
10883
- }[];
10884
- };
10885
11114
  get_floriday_clock_supplies_window: {
10886
11115
  Args: {
10887
11116
  p_from: string;
@@ -10954,6 +11183,21 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
10954
11183
  minutes_since_success: number;
10955
11184
  }[];
10956
11185
  };
11186
+ get_group_allocation_keys: {
11187
+ Args: {
11188
+ p_product_id: string;
11189
+ };
11190
+ Returns: {
11191
+ k: string;
11192
+ ord: number;
11193
+ }[];
11194
+ };
11195
+ get_group_head_key: {
11196
+ Args: {
11197
+ p_group_id: string;
11198
+ };
11199
+ Returns: string;
11200
+ };
10957
11201
  get_offer_by_link_code: {
10958
11202
  Args: {
10959
11203
  p_code: string;
@@ -11064,6 +11308,19 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
11064
11308
  };
11065
11309
  Returns: undefined;
11066
11310
  };
11311
+ mark_shipment_shipped: {
11312
+ Args: {
11313
+ p_shipment_id: string;
11314
+ };
11315
+ Returns: undefined;
11316
+ };
11317
+ merge_products: {
11318
+ Args: {
11319
+ _canonical: string;
11320
+ _loser: string;
11321
+ };
11322
+ Returns: undefined;
11323
+ };
11067
11324
  next_manufacture_partij: {
11068
11325
  Args: {
11069
11326
  _tenant_id: string;
@@ -11148,6 +11405,14 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
11148
11405
  };
11149
11406
  Returns: undefined;
11150
11407
  };
11408
+ produce_designed_product: {
11409
+ Args: {
11410
+ p_parent_id: string;
11411
+ p_parent_kind: string;
11412
+ p_quantity: number;
11413
+ };
11414
+ Returns: import("../integrations/supabase/types").Json;
11415
+ };
11151
11416
  promote_trade_item_key: {
11152
11417
  Args: {
11153
11418
  p_new: string;
@@ -11155,6 +11420,10 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
11155
11420
  };
11156
11421
  Returns: undefined;
11157
11422
  };
11423
+ recompute_all_reserved_stock: {
11424
+ Args: never;
11425
+ Returns: undefined;
11426
+ };
11158
11427
  recompute_order_status: {
11159
11428
  Args: {
11160
11429
  p_order_id: string;
@@ -11204,27 +11473,45 @@ export declare const getPreferredWarehouseStatus: import("@tanstack/start-client
11204
11473
  };
11205
11474
  Returns: undefined;
11206
11475
  };
11476
+ resolve_group_allocation: {
11477
+ Args: {
11478
+ _needed: number;
11479
+ _product_group_id: string;
11480
+ };
11481
+ Returns: {
11482
+ allocated: number;
11483
+ trade_item_id: string;
11484
+ }[];
11485
+ };
11486
+ resolve_group_member_stock_key: {
11487
+ Args: {
11488
+ p_trade_item_id: string;
11489
+ };
11490
+ Returns: string;
11491
+ };
11207
11492
  resolve_product_id_for_item: {
11208
11493
  Args: {
11209
11494
  p_product_name: string;
11210
11495
  };
11211
11496
  Returns: string;
11212
11497
  };
11213
- schedule_floriday_additional_services_sync: {
11498
+ resolve_stock_trade_item_key: {
11214
11499
  Args: {
11215
- p_apikey: string;
11216
- p_url: string;
11500
+ p_product_id: string;
11217
11501
  };
11218
- Returns: number;
11502
+ Returns: string;
11219
11503
  };
11220
- schedule_floriday_agreement_calloffs_sync: {
11504
+ reverse_production: {
11221
11505
  Args: {
11222
- p_apikey: string;
11223
- p_url: string;
11506
+ p_connection_id?: string;
11507
+ p_parent_key: string;
11508
+ p_quantity: number;
11509
+ p_reason?: string;
11510
+ p_user_id?: string;
11224
11511
  };
11225
- Returns: number;
11512
+ Returns: import("../integrations/supabase/types").Json;
11226
11513
  };
11227
- schedule_floriday_agreements_sync: {
11514
+ schedule_floriday_additional_services_sync: {
11228
11515
  Args: {
11229
11516
  p_apikey: string;
11230
11517
  p_url: string;
@@ -14946,106 +15233,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
14946
15233
  updated_at?: string;
14947
15234
  };
14948
15235
  Relationships: [{
14949
- foreignKeyName: "floriday_additional_services_cache_connection_id_fkey";
14950
- columns: ["connection_id"];
14951
- isOneToOne: false;
14952
- referencedRelation: "floriday_connections";
14953
- referencedColumns: ["id"];
14954
- }];
14955
- };
14956
- floriday_agreement_calloffs_cache: {
14957
- Row: {
14958
- agreement_id: string | null;
14959
- connection_id: string;
14960
- data: import("../integrations/supabase/types").Json;
14961
- delivery_date: string | null;
14962
- fetched_at: string;
14963
- floriday_id: string;
14964
- id: string;
14965
- is_deleted: boolean;
14966
- sequence_number: number;
14967
- status: string | null;
14968
- updated_at: string;
14969
- };
14970
- Insert: {
14971
- agreement_id?: string | null;
14972
- connection_id: string;
14973
- data?: import("../integrations/supabase/types").Json;
14974
- delivery_date?: string | null;
14975
- fetched_at?: string;
14976
- floriday_id: string;
14977
- id?: string;
14978
- is_deleted?: boolean;
14979
- sequence_number?: number;
14980
- status?: string | null;
14981
- updated_at?: string;
14982
- };
14983
- Update: {
14984
- agreement_id?: string | null;
14985
- connection_id?: string;
14986
- data?: import("../integrations/supabase/types").Json;
14987
- delivery_date?: string | null;
14988
- fetched_at?: string;
14989
- floriday_id?: string;
14990
- id?: string;
14991
- is_deleted?: boolean;
14992
- sequence_number?: number;
14993
- status?: string | null;
14994
- updated_at?: string;
14995
- };
14996
- Relationships: [{
14997
- foreignKeyName: "floriday_agreement_calloffs_cache_connection_id_fkey";
14998
- columns: ["connection_id"];
14999
- isOneToOne: false;
15000
- referencedRelation: "floriday_connections";
15001
- referencedColumns: ["id"];
15002
- }];
15003
- };
15004
- floriday_agreements_cache: {
15005
- Row: {
15006
- buyer_organization_id: string | null;
15007
- connection_id: string;
15008
- data: import("../integrations/supabase/types").Json;
15009
- fetched_at: string;
15010
- floriday_id: string;
15011
- id: string;
15012
- is_deleted: boolean;
15013
- sequence_number: number;
15014
- status: string | null;
15015
- updated_at: string;
15016
- valid_from: string | null;
15017
- valid_until: string | null;
15018
- };
15019
- Insert: {
15020
- buyer_organization_id?: string | null;
15021
- connection_id: string;
15022
- data?: import("../integrations/supabase/types").Json;
15023
- fetched_at?: string;
15024
- floriday_id: string;
15025
- id?: string;
15026
- is_deleted?: boolean;
15027
- sequence_number?: number;
15028
- status?: string | null;
15029
- updated_at?: string;
15030
- valid_from?: string | null;
15031
- valid_until?: string | null;
15032
- };
15033
- Update: {
15034
- buyer_organization_id?: string | null;
15035
- connection_id?: string;
15036
- data?: import("../integrations/supabase/types").Json;
15037
- fetched_at?: string;
15038
- floriday_id?: string;
15039
- id?: string;
15040
- is_deleted?: boolean;
15041
- sequence_number?: number;
15042
- status?: string | null;
15043
- updated_at?: string;
15044
- valid_from?: string | null;
15045
- valid_until?: string | null;
15046
- };
15047
- Relationships: [{
15048
- foreignKeyName: "floriday_agreements_cache_connection_id_fkey";
15236
+ foreignKeyName: "floriday_additional_services_cache_connection_id_fkey";
15049
15237
  columns: ["connection_id"];
15050
15238
  isOneToOne: false;
15051
15239
  referencedRelation: "floriday_connections";
@@ -16549,6 +16737,45 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
16549
16737
  referencedColumns: ["id"];
16550
16738
  }];
16551
16739
  };
16740
+ floriday_trade_settings_customers_cache: {
16741
+ Row: {
16742
+ connection_id: string;
16743
+ data: import("../integrations/supabase/types").Json;
16744
+ fetched_at: string;
16745
+ floriday_id: string;
16746
+ id: string;
16747
+ is_deleted: boolean;
16748
+ sequence_number: number;
16749
+ updated_at: string;
16750
+ };
16751
+ Insert: {
16752
+ connection_id: string;
16753
+ data: import("../integrations/supabase/types").Json;
16754
+ fetched_at?: string;
16755
+ floriday_id: string;
16756
+ id?: string;
16757
+ is_deleted?: boolean;
16758
+ sequence_number?: number;
16759
+ updated_at?: string;
16760
+ };
16761
+ Update: {
16762
+ connection_id?: string;
16763
+ data?: import("../integrations/supabase/types").Json;
16764
+ fetched_at?: string;
16765
+ floriday_id?: string;
16766
+ id?: string;
16767
+ is_deleted?: boolean;
16768
+ sequence_number?: number;
16769
+ updated_at?: string;
16770
+ };
16771
+ Relationships: [{
16772
+ foreignKeyName: "floriday_trade_settings_customers_cache_connection_id_fkey";
16773
+ columns: ["connection_id"];
16774
+ isOneToOne: false;
16775
+ referencedRelation: "floriday_connections";
16776
+ referencedColumns: ["id"];
16777
+ }];
16778
+ };
16552
16779
  floriday_trips_cache: {
16553
16780
  Row: {
16554
16781
  carrier_organization_id: string | null;
@@ -18721,6 +18948,105 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
18721
18948
  };
18722
18949
  Relationships: [];
18723
18950
  };
18951
+ order_shipment_items: {
18952
+ Row: {
18953
+ created_at: string;
18954
+ id: string;
18955
+ order_item_id: string;
18956
+ product_id: string | null;
18957
+ product_name: string;
18958
+ quantity: number;
18959
+ shipment_id: string;
18960
+ updated_at: string;
18961
+ };
18962
+ Insert: {
18963
+ created_at?: string;
18964
+ id?: string;
18965
+ order_item_id: string;
18966
+ product_id?: string | null;
18967
+ product_name: string;
18968
+ quantity: number;
18969
+ shipment_id: string;
18970
+ updated_at?: string;
18971
+ };
18972
+ Update: {
18973
+ created_at?: string;
18974
+ id?: string;
18975
+ order_item_id?: string;
18976
+ product_id?: string | null;
18977
+ product_name?: string;
18978
+ quantity?: number;
18979
+ shipment_id?: string;
18980
+ updated_at?: string;
18981
+ };
18982
+ Relationships: [{
18983
+ foreignKeyName: "order_shipment_items_order_item_id_fkey";
18984
+ columns: ["order_item_id"];
18985
+ isOneToOne: false;
18986
+ referencedRelation: "order_items";
18987
+ referencedColumns: ["id"];
18988
+ }, {
18989
+ foreignKeyName: "order_shipment_items_shipment_id_fkey";
18990
+ columns: ["shipment_id"];
18991
+ isOneToOne: false;
18992
+ referencedRelation: "order_shipments";
18993
+ referencedColumns: ["id"];
18994
+ }];
18995
+ };
18996
+ order_shipments: {
18997
+ Row: {
18998
+ carrier_id: string | null;
18999
+ created_at: string;
19000
+ delivery_date: string | null;
19001
+ delivery_location_id: string | null;
19002
+ id: string;
19003
+ notes: string | null;
19004
+ order_id: string;
19005
+ shipment_number: number;
19006
+ shipped_at: string | null;
19007
+ status: string;
19008
+ updated_at: string;
19009
+ };
19010
+ Insert: {
19011
+ carrier_id?: string | null;
19012
+ created_at?: string;
19013
+ delivery_date?: string | null;
19014
+ delivery_location_id?: string | null;
19015
+ id?: string;
19016
+ notes?: string | null;
19017
+ order_id: string;
19018
+ shipment_number: number;
19019
+ shipped_at?: string | null;
19020
+ status?: string;
19021
+ updated_at?: string;
19022
+ };
19023
+ Update: {
19024
+ carrier_id?: string | null;
19025
+ created_at?: string;
19026
+ delivery_date?: string | null;
19027
+ delivery_location_id?: string | null;
19028
+ id?: string;
19029
+ notes?: string | null;
19030
+ order_id?: string;
19031
+ shipment_number?: number;
19032
+ shipped_at?: string | null;
19033
+ status?: string;
19034
+ updated_at?: string;
19035
+ };
19036
+ Relationships: [{
19037
+ foreignKeyName: "order_shipments_carrier_id_fkey";
19038
+ columns: ["carrier_id"];
19039
+ isOneToOne: false;
19040
+ referencedRelation: "carriers";
19041
+ referencedColumns: ["id"];
19042
+ }, {
19043
+ foreignKeyName: "order_shipments_order_id_fkey";
19044
+ columns: ["order_id"];
19045
+ isOneToOne: false;
19046
+ referencedRelation: "orders";
19047
+ referencedColumns: ["id"];
19048
+ }];
19049
+ };
18724
19050
  orders: {
18725
19051
  Row: {
18726
19052
  created_at: string;
@@ -18728,8 +19054,9 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
18728
19054
  customer_id: string | null;
18729
19055
  customer_name: string;
18730
19056
  deleted_at: string | null;
18731
- delivery_date: string;
19057
+ delivery_date: string | null;
18732
19058
  id: string;
19059
+ is_reservation: boolean;
18733
19060
  notes: string | null;
18734
19061
  order_date: string;
18735
19062
  order_number: string;
@@ -18746,8 +19073,9 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
18746
19073
  customer_id?: string | null;
18747
19074
  customer_name?: string;
18748
19075
  deleted_at?: string | null;
18749
- delivery_date: string;
19076
+ delivery_date?: string | null;
18750
19077
  id?: string;
19078
+ is_reservation?: boolean;
18751
19079
  notes?: string | null;
18752
19080
  order_date?: string;
18753
19081
  order_number: string;
@@ -18764,8 +19092,9 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
18764
19092
  customer_id?: string | null;
18765
19093
  customer_name?: string;
18766
19094
  deleted_at?: string | null;
18767
- delivery_date?: string;
19095
+ delivery_date?: string | null;
18768
19096
  id?: string;
19097
+ is_reservation?: boolean;
18769
19098
  notes?: string | null;
18770
19099
  order_date?: string;
18771
19100
  order_number?: string;
@@ -18907,6 +19236,63 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
18907
19236
  };
18908
19237
  Relationships: [];
18909
19238
  };
19239
+ product_bom_items: {
19240
+ Row: {
19241
+ component_product_id: string | null;
19242
+ component_trade_item_floriday_id: string | null;
19243
+ created_at: string;
19244
+ id: string;
19245
+ notes: string | null;
19246
+ parent_product_id: string | null;
19247
+ parent_trade_item_floriday_id: string | null;
19248
+ quantity: number;
19249
+ sort_order: number;
19250
+ tenant_id: string;
19251
+ unit: string;
19252
+ updated_at: string;
19253
+ };
19254
+ Insert: {
19255
+ component_product_id?: string | null;
19256
+ component_trade_item_floriday_id?: string | null;
19257
+ created_at?: string;
19258
+ id?: string;
19259
+ notes?: string | null;
19260
+ parent_product_id?: string | null;
19261
+ parent_trade_item_floriday_id?: string | null;
19262
+ quantity?: number;
19263
+ sort_order?: number;
19264
+ tenant_id: string;
19265
+ unit?: string;
19266
+ updated_at?: string;
19267
+ };
19268
+ Update: {
19269
+ component_product_id?: string | null;
19270
+ component_trade_item_floriday_id?: string | null;
19271
+ created_at?: string;
19272
+ id?: string;
19273
+ notes?: string | null;
19274
+ parent_product_id?: string | null;
19275
+ parent_trade_item_floriday_id?: string | null;
19276
+ quantity?: number;
19277
+ sort_order?: number;
19278
+ tenant_id?: string;
19279
+ unit?: string;
19280
+ updated_at?: string;
19281
+ };
19282
+ Relationships: [{
19283
+ foreignKeyName: "product_bom_items_component_product_id_fkey";
19284
+ columns: ["component_product_id"];
19285
+ isOneToOne: false;
19286
+ referencedRelation: "products";
19287
+ referencedColumns: ["id"];
19288
+ }, {
19289
+ foreignKeyName: "product_bom_items_parent_product_id_fkey";
19290
+ columns: ["parent_product_id"];
19291
+ isOneToOne: false;
19292
+ referencedRelation: "products";
19293
+ referencedColumns: ["id"];
19294
+ }];
19295
+ };
18910
19296
  product_categories: {
18911
19297
  Row: {
18912
19298
  color: string;
@@ -19012,6 +19398,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19012
19398
  id: string;
19013
19399
  product_group_id: string;
19014
19400
  quantity: number;
19401
+ sort_order: number;
19015
19402
  trade_item_id: string;
19016
19403
  };
19017
19404
  Insert: {
@@ -19019,6 +19406,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19019
19406
  id?: string;
19020
19407
  product_group_id: string;
19021
19408
  quantity?: number;
19409
+ sort_order?: number;
19022
19410
  trade_item_id: string;
19023
19411
  };
19024
19412
  Update: {
@@ -19026,6 +19414,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19026
19414
  id?: string;
19027
19415
  product_group_id?: string;
19028
19416
  quantity?: number;
19417
+ sort_order?: number;
19029
19418
  trade_item_id?: string;
19030
19419
  };
19031
19420
  Relationships: [{
@@ -19040,6 +19429,8 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19040
19429
  Row: {
19041
19430
  created_at: string;
19042
19431
  description: string | null;
19432
+ head_product_id: string | null;
19433
+ head_trade_item_floriday_id: string | null;
19043
19434
  id: string;
19044
19435
  is_active: boolean;
19045
19436
  name: string;
@@ -19049,6 +19440,8 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19049
19440
  Insert: {
19050
19441
  created_at?: string;
19051
19442
  description?: string | null;
19443
+ head_product_id?: string | null;
19444
+ head_trade_item_floriday_id?: string | null;
19052
19445
  id?: string;
19053
19446
  is_active?: boolean;
19054
19447
  name: string;
@@ -19058,21 +19451,126 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19058
19451
  Update: {
19059
19452
  created_at?: string;
19060
19453
  description?: string | null;
19454
+ head_product_id?: string | null;
19455
+ head_trade_item_floriday_id?: string | null;
19061
19456
  id?: string;
19062
19457
  is_active?: boolean;
19063
19458
  name?: string;
19064
19459
  tenant_id?: string;
19065
19460
  updated_at?: string;
19066
19461
  };
19462
+ Relationships: [{
19463
+ foreignKeyName: "product_groups_head_product_id_fkey";
19464
+ columns: ["head_product_id"];
19465
+ isOneToOne: false;
19466
+ referencedRelation: "products";
19467
+ referencedColumns: ["id"];
19468
+ }];
19469
+ };
19470
+ product_load_settings: {
19471
+ Row: {
19472
+ created_at: string;
19473
+ id: string;
19474
+ is_package: boolean;
19475
+ layers_per_load_carrier: number | null;
19476
+ load_carrier: string | null;
19477
+ package_id: string | null;
19478
+ package_label: string | null;
19479
+ packages_per_layer: number | null;
19480
+ product_id: string | null;
19481
+ tenant_id: string;
19482
+ trade_item_floriday_id: string | null;
19483
+ units_per_package: number | null;
19484
+ updated_at: string;
19485
+ };
19486
+ Insert: {
19487
+ created_at?: string;
19488
+ id?: string;
19489
+ is_package?: boolean;
19490
+ layers_per_load_carrier?: number | null;
19491
+ load_carrier?: string | null;
19492
+ package_id?: string | null;
19493
+ package_label?: string | null;
19494
+ packages_per_layer?: number | null;
19495
+ product_id?: string | null;
19496
+ tenant_id: string;
19497
+ trade_item_floriday_id?: string | null;
19498
+ units_per_package?: number | null;
19499
+ updated_at?: string;
19500
+ };
19501
+ Update: {
19502
+ created_at?: string;
19503
+ id?: string;
19504
+ is_package?: boolean;
19505
+ layers_per_load_carrier?: number | null;
19506
+ load_carrier?: string | null;
19507
+ package_id?: string | null;
19508
+ package_label?: string | null;
19509
+ packages_per_layer?: number | null;
19510
+ product_id?: string | null;
19511
+ tenant_id?: string;
19512
+ trade_item_floriday_id?: string | null;
19513
+ units_per_package?: number | null;
19514
+ updated_at?: string;
19515
+ };
19516
+ Relationships: [{
19517
+ foreignKeyName: "product_load_settings_package_id_fkey";
19518
+ columns: ["package_id"];
19519
+ isOneToOne: false;
19520
+ referencedRelation: "packages";
19521
+ referencedColumns: ["id"];
19522
+ }, {
19523
+ foreignKeyName: "product_load_settings_product_id_fkey";
19524
+ columns: ["product_id"];
19525
+ isOneToOne: false;
19526
+ referencedRelation: "products";
19527
+ referencedColumns: ["id"];
19528
+ }];
19529
+ };
19530
+ product_merge_log: {
19531
+ Row: {
19532
+ canonical_product_id: string | null;
19533
+ id: string;
19534
+ merged_at: string;
19535
+ merged_from_id: string;
19536
+ notes: string | null;
19537
+ snapshot: import("../integrations/supabase/types").Json;
19538
+ source_table: string;
19539
+ status: string;
19540
+ };
19541
+ Insert: {
19542
+ canonical_product_id?: string | null;
19543
+ id?: string;
19544
+ merged_at?: string;
19545
+ merged_from_id: string;
19546
+ notes?: string | null;
19547
+ snapshot?: import("../integrations/supabase/types").Json;
19548
+ source_table: string;
19549
+ status?: string;
19550
+ };
19551
+ Update: {
19552
+ canonical_product_id?: string | null;
19553
+ id?: string;
19554
+ merged_at?: string;
19555
+ merged_from_id?: string;
19556
+ notes?: string | null;
19557
+ snapshot?: import("../integrations/supabase/types").Json;
19558
+ source_table?: string;
19559
+ status?: string;
19560
+ };
19067
19561
  Relationships: [];
19068
19562
  };
19069
19563
  products: {
19070
19564
  Row: {
19565
+ article_number: string | null;
19071
19566
  barcode: string | null;
19072
19567
  batch: string;
19073
19568
  crates_per_layer: number;
19074
19569
  created_at: string;
19075
19570
  custom_fields: import("../integrations/supabase/types").Json;
19571
+ floriday_active: boolean;
19572
+ floriday_payload: import("../integrations/supabase/types").Json;
19573
+ floriday_trade_item_id: string | null;
19076
19574
  id: string;
19077
19575
  image_url: string | null;
19078
19576
  incoming_quantity: number;
@@ -19091,11 +19589,15 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19091
19589
  weight: string | null;
19092
19590
  };
19093
19591
  Insert: {
19592
+ article_number?: string | null;
19094
19593
  barcode?: string | null;
19095
19594
  batch: string;
19096
19595
  crates_per_layer?: number;
19097
19596
  created_at?: string;
19098
19597
  custom_fields?: import("../integrations/supabase/types").Json;
19598
+ floriday_active?: boolean;
19599
+ floriday_payload?: import("../integrations/supabase/types").Json;
19600
+ floriday_trade_item_id?: string | null;
19099
19601
  id?: string;
19100
19602
  image_url?: string | null;
19101
19603
  incoming_quantity?: number;
@@ -19114,11 +19616,15 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
19114
19616
  weight?: string | null;
19115
19617
  };
19116
19618
  Update: {
19619
+ article_number?: string | null;
19117
19620
  barcode?: string | null;
19118
19621
  batch?: string;
19119
19622
  crates_per_layer?: number;
19120
19623
  created_at?: string;
19121
19624
  custom_fields?: import("../integrations/supabase/types").Json;
19625
+ floriday_active?: boolean;
19626
+ floriday_payload?: import("../integrations/supabase/types").Json;
19627
+ floriday_trade_item_id?: string | null;
19122
19628
  id?: string;
19123
19629
  image_url?: string | null;
19124
19630
  incoming_quantity?: number;
@@ -20027,8 +20533,10 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20027
20533
  order_id: string | null;
20028
20534
  order_item_id: string | null;
20029
20535
  order_source: string | null;
20536
+ parent_trade_item_key: string | null;
20030
20537
  physical_after: number | null;
20031
20538
  physical_before: number | null;
20539
+ production_batch_id: string | null;
20032
20540
  qty_delta: number;
20033
20541
  reason: string | null;
20034
20542
  reserved_after: number | null;
@@ -20044,8 +20552,10 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20044
20552
  order_id?: string | null;
20045
20553
  order_item_id?: string | null;
20046
20554
  order_source?: string | null;
20555
+ parent_trade_item_key?: string | null;
20047
20556
  physical_after?: number | null;
20048
20557
  physical_before?: number | null;
20558
+ production_batch_id?: string | null;
20049
20559
  qty_delta: number;
20050
20560
  reason?: string | null;
20051
20561
  reserved_after?: number | null;
@@ -20061,8 +20571,10 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20061
20571
  order_id?: string | null;
20062
20572
  order_item_id?: string | null;
20063
20573
  order_source?: string | null;
20574
+ parent_trade_item_key?: string | null;
20064
20575
  physical_after?: number | null;
20065
20576
  physical_before?: number | null;
20577
+ production_batch_id?: string | null;
20066
20578
  qty_delta?: number;
20067
20579
  reason?: string | null;
20068
20580
  reserved_after?: number | null;
@@ -20521,7 +21033,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20521
21033
  twinfield_connections: {
20522
21034
  Row: {
20523
21035
  access_token: string | null;
20524
- client_id: string;
21036
+ client_id: string | null;
20525
21037
  client_secret: string | null;
20526
21038
  cluster_uri: string | null;
20527
21039
  company_code: string | null;
@@ -20533,7 +21045,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20533
21045
  is_active: boolean;
20534
21046
  label: string | null;
20535
21047
  office_code: string | null;
20536
- redirect_uri: string;
21048
+ redirect_uri: string | null;
20537
21049
  refresh_token: string | null;
20538
21050
  token_expires_at: string | null;
20539
21051
  updated_at: string;
@@ -20541,7 +21053,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20541
21053
  };
20542
21054
  Insert: {
20543
21055
  access_token?: string | null;
20544
- client_id: string;
21056
+ client_id?: string | null;
20545
21057
  client_secret?: string | null;
20546
21058
  cluster_uri?: string | null;
20547
21059
  company_code?: string | null;
@@ -20553,7 +21065,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20553
21065
  is_active?: boolean;
20554
21066
  label?: string | null;
20555
21067
  office_code?: string | null;
20556
- redirect_uri: string;
21068
+ redirect_uri?: string | null;
20557
21069
  refresh_token?: string | null;
20558
21070
  token_expires_at?: string | null;
20559
21071
  updated_at?: string;
@@ -20561,7 +21073,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20561
21073
  };
20562
21074
  Update: {
20563
21075
  access_token?: string | null;
20564
- client_id?: string;
21076
+ client_id?: string | null;
20565
21077
  client_secret?: string | null;
20566
21078
  cluster_uri?: string | null;
20567
21079
  company_code?: string | null;
@@ -20573,7 +21085,7 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
20573
21085
  is_active?: boolean;
20574
21086
  label?: string | null;
20575
21087
  office_code?: string | null;
20576
- redirect_uri?: string;
21088
+ redirect_uri?: string | null;
20577
21089
  refresh_token?: string | null;
20578
21090
  token_expires_at?: string | null;
20579
21091
  updated_at?: string;
@@ -21768,25 +22280,6 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
21768
22280
  };
21769
22281
  Relationships: [];
21770
22282
  };
21771
- floriday_customer_discounts: {
21772
- Row: {
21773
- base_price: number | null;
21774
- buyer_organization_id: string | null;
21775
- currency: string | null;
21776
- discount_type: string | null;
21777
- discount_value: number | null;
21778
- min_quantity: number | null;
21779
- net_price: number | null;
21780
- product_group_id: string | null;
21781
- raw: import("../integrations/supabase/types").Json | null;
21782
- source: string | null;
21783
- source_id: string | null;
21784
- trade_item_id: string | null;
21785
- valid_from: string | null;
21786
- valid_until: string | null;
21787
- };
21788
- Relationships: [];
21789
- };
21790
22283
  local_customer_discounts: {
21791
22284
  Row: {
21792
22285
  base_price: number | null;
@@ -22090,6 +22583,13 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22090
22583
  };
22091
22584
  Returns: number;
22092
22585
  };
22586
+ _migrate_rewrite_stock_key: {
22587
+ Args: {
22588
+ _from_key: string;
22589
+ _to_key: string;
22590
+ };
22591
+ Returns: undefined;
22592
+ };
22093
22593
  afh_city_code: {
22094
22594
  Args: {
22095
22595
  _city: string;
@@ -22205,6 +22705,28 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22205
22705
  Args: never;
22206
22706
  Returns: undefined;
22207
22707
  };
22708
+ consume_bom_for_production: {
22709
+ Args: {
22710
+ p_connection_id: string;
22711
+ p_parent_id: string;
22712
+ p_parent_key: string;
22713
+ p_parent_kind: string;
22714
+ p_quantity: number;
22715
+ p_user_id: string;
22716
+ };
22717
+ Returns: import("../integrations/supabase/types").Json;
22718
+ } | {
22719
+ Args: {
22720
+ p_batch_id?: string;
22721
+ p_connection_id: string;
22722
+ p_parent_id: string;
22723
+ p_parent_key: string;
22724
+ p_parent_kind: string;
22725
+ p_quantity: number;
22726
+ p_user_id: string;
22727
+ };
22728
+ Returns: import("../integrations/supabase/types").Json;
22729
+ };
22208
22730
  consume_floriday_rate_limit: {
22209
22731
  Args: {
22210
22732
  p_bucket: string;
@@ -22256,6 +22778,13 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22256
22778
  table_name: string;
22257
22779
  }[];
22258
22780
  };
22781
+ delete_samenstelling: {
22782
+ Args: {
22783
+ p_parent_id: string;
22784
+ p_parent_kind: string;
22785
+ };
22786
+ Returns: import("../integrations/supabase/types").Json;
22787
+ };
22259
22788
  dispatch_carrier_signups_sql: {
22260
22789
  Args: {
22261
22790
  _catchup?: string;
@@ -22416,19 +22945,6 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22416
22945
  resource: string;
22417
22946
  }[];
22418
22947
  };
22419
- get_floriday_agreements_active: {
22420
- Args: {
22421
- p_on_date?: string;
22422
- };
22423
- Returns: {
22424
- buyer_organization_id: string;
22425
- data: import("../integrations/supabase/types").Json;
22426
- floriday_id: string;
22427
- status: string;
22428
- valid_from: string;
22429
- valid_until: string;
22430
- }[];
22431
- };
22432
22948
  get_floriday_clock_supplies_window: {
22433
22949
  Args: {
22434
22950
  p_from: string;
@@ -22501,6 +23017,21 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22501
23017
  minutes_since_success: number;
22502
23018
  }[];
22503
23019
  };
23020
+ get_group_allocation_keys: {
23021
+ Args: {
23022
+ p_product_id: string;
23023
+ };
23024
+ Returns: {
23025
+ k: string;
23026
+ ord: number;
23027
+ }[];
23028
+ };
23029
+ get_group_head_key: {
23030
+ Args: {
23031
+ p_group_id: string;
23032
+ };
23033
+ Returns: string;
23034
+ };
22504
23035
  get_offer_by_link_code: {
22505
23036
  Args: {
22506
23037
  p_code: string;
@@ -22611,6 +23142,19 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22611
23142
  };
22612
23143
  Returns: undefined;
22613
23144
  };
23145
+ mark_shipment_shipped: {
23146
+ Args: {
23147
+ p_shipment_id: string;
23148
+ };
23149
+ Returns: undefined;
23150
+ };
23151
+ merge_products: {
23152
+ Args: {
23153
+ _canonical: string;
23154
+ _loser: string;
23155
+ };
23156
+ Returns: undefined;
23157
+ };
22614
23158
  next_manufacture_partij: {
22615
23159
  Args: {
22616
23160
  _tenant_id: string;
@@ -22695,6 +23239,14 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22695
23239
  };
22696
23240
  Returns: undefined;
22697
23241
  };
23242
+ produce_designed_product: {
23243
+ Args: {
23244
+ p_parent_id: string;
23245
+ p_parent_kind: string;
23246
+ p_quantity: number;
23247
+ };
23248
+ Returns: import("../integrations/supabase/types").Json;
23249
+ };
22698
23250
  promote_trade_item_key: {
22699
23251
  Args: {
22700
23252
  p_new: string;
@@ -22702,6 +23254,10 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22702
23254
  };
22703
23255
  Returns: undefined;
22704
23256
  };
23257
+ recompute_all_reserved_stock: {
23258
+ Args: never;
23259
+ Returns: undefined;
23260
+ };
22705
23261
  recompute_order_status: {
22706
23262
  Args: {
22707
23263
  p_order_id: string;
@@ -22751,27 +23307,45 @@ export declare const getAutoFulfillmentStatus: import("@tanstack/start-client-co
22751
23307
  };
22752
23308
  Returns: undefined;
22753
23309
  };
23310
+ resolve_group_allocation: {
23311
+ Args: {
23312
+ _needed: number;
23313
+ _product_group_id: string;
23314
+ };
23315
+ Returns: {
23316
+ allocated: number;
23317
+ trade_item_id: string;
23318
+ }[];
23319
+ };
23320
+ resolve_group_member_stock_key: {
23321
+ Args: {
23322
+ p_trade_item_id: string;
23323
+ };
23324
+ Returns: string;
23325
+ };
22754
23326
  resolve_product_id_for_item: {
22755
23327
  Args: {
22756
23328
  p_product_name: string;
22757
23329
  };
22758
23330
  Returns: string;
22759
23331
  };
22760
- schedule_floriday_additional_services_sync: {
23332
+ resolve_stock_trade_item_key: {
22761
23333
  Args: {
22762
- p_apikey: string;
22763
- p_url: string;
23334
+ p_product_id: string;
22764
23335
  };
22765
- Returns: number;
23336
+ Returns: string;
22766
23337
  };
22767
- schedule_floriday_agreement_calloffs_sync: {
23338
+ reverse_production: {
22768
23339
  Args: {
22769
- p_apikey: string;
22770
- p_url: string;
23340
+ p_connection_id?: string;
23341
+ p_parent_key: string;
23342
+ p_quantity: number;
23343
+ p_reason?: string;
23344
+ p_user_id?: string;
22771
23345
  };
22772
- Returns: number;
23346
+ Returns: import("../integrations/supabase/types").Json;
22773
23347
  };
22774
- schedule_floriday_agreements_sync: {
23348
+ schedule_floriday_additional_services_sync: {
22775
23349
  Args: {
22776
23350
  p_apikey: string;
22777
23351
  p_url: string;
@@ -26509,105 +27083,6 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
26509
27083
  referencedColumns: ["id"];
26510
27084
  }];
26511
27085
  };
26512
- floriday_agreement_calloffs_cache: {
26513
- Row: {
26514
- agreement_id: string | null;
26515
- connection_id: string;
26516
- data: import("../integrations/supabase/types").Json;
26517
- delivery_date: string | null;
26518
- fetched_at: string;
26519
- floriday_id: string;
26520
- id: string;
26521
- is_deleted: boolean;
26522
- sequence_number: number;
26523
- status: string | null;
26524
- updated_at: string;
26525
- };
26526
- Insert: {
26527
- agreement_id?: string | null;
26528
- connection_id: string;
26529
- data?: import("../integrations/supabase/types").Json;
26530
- delivery_date?: string | null;
26531
- fetched_at?: string;
26532
- floriday_id: string;
26533
- id?: string;
26534
- is_deleted?: boolean;
26535
- sequence_number?: number;
26536
- status?: string | null;
26537
- updated_at?: string;
26538
- };
26539
- Update: {
26540
- agreement_id?: string | null;
26541
- connection_id?: string;
26542
- data?: import("../integrations/supabase/types").Json;
26543
- delivery_date?: string | null;
26544
- fetched_at?: string;
26545
- floriday_id?: string;
26546
- id?: string;
26547
- is_deleted?: boolean;
26548
- sequence_number?: number;
26549
- status?: string | null;
26550
- updated_at?: string;
26551
- };
26552
- Relationships: [{
26553
- foreignKeyName: "floriday_agreement_calloffs_cache_connection_id_fkey";
26554
- columns: ["connection_id"];
26555
- isOneToOne: false;
26556
- referencedRelation: "floriday_connections";
26557
- referencedColumns: ["id"];
26558
- }];
26559
- };
26560
- floriday_agreements_cache: {
26561
- Row: {
26562
- buyer_organization_id: string | null;
26563
- connection_id: string;
26564
- data: import("../integrations/supabase/types").Json;
26565
- fetched_at: string;
26566
- floriday_id: string;
26567
- id: string;
26568
- is_deleted: boolean;
26569
- sequence_number: number;
26570
- status: string | null;
26571
- updated_at: string;
26572
- valid_from: string | null;
26573
- valid_until: string | null;
26574
- };
26575
- Insert: {
26576
- buyer_organization_id?: string | null;
26577
- connection_id: string;
26578
- data?: import("../integrations/supabase/types").Json;
26579
- fetched_at?: string;
26580
- floriday_id: string;
26581
- id?: string;
26582
- is_deleted?: boolean;
26583
- sequence_number?: number;
26584
- status?: string | null;
26585
- updated_at?: string;
26586
- valid_from?: string | null;
26587
- valid_until?: string | null;
26588
- };
26589
- Update: {
26590
- buyer_organization_id?: string | null;
26591
- connection_id?: string;
26592
- data?: import("../integrations/supabase/types").Json;
26593
- fetched_at?: string;
26594
- floriday_id?: string;
26595
- id?: string;
26596
- is_deleted?: boolean;
26597
- sequence_number?: number;
26598
- status?: string | null;
26599
- updated_at?: string;
26600
- valid_from?: string | null;
26601
- valid_until?: string | null;
26602
- };
26603
- Relationships: [{
26604
- foreignKeyName: "floriday_agreements_cache_connection_id_fkey";
26605
- columns: ["connection_id"];
26606
- isOneToOne: false;
26607
- referencedRelation: "floriday_connections";
26608
- referencedColumns: ["id"];
26609
- }];
26610
- };
26611
27086
  floriday_auction_letters_cache: {
26612
27087
  Row: {
26613
27088
  auction_letter_code: string;
@@ -28105,6 +28580,45 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
28105
28580
  referencedColumns: ["id"];
28106
28581
  }];
28107
28582
  };
28583
+ floriday_trade_settings_customers_cache: {
28584
+ Row: {
28585
+ connection_id: string;
28586
+ data: import("../integrations/supabase/types").Json;
28587
+ fetched_at: string;
28588
+ floriday_id: string;
28589
+ id: string;
28590
+ is_deleted: boolean;
28591
+ sequence_number: number;
28592
+ updated_at: string;
28593
+ };
28594
+ Insert: {
28595
+ connection_id: string;
28596
+ data: import("../integrations/supabase/types").Json;
28597
+ fetched_at?: string;
28598
+ floriday_id: string;
28599
+ id?: string;
28600
+ is_deleted?: boolean;
28601
+ sequence_number?: number;
28602
+ updated_at?: string;
28603
+ };
28604
+ Update: {
28605
+ connection_id?: string;
28606
+ data?: import("../integrations/supabase/types").Json;
28607
+ fetched_at?: string;
28608
+ floriday_id?: string;
28609
+ id?: string;
28610
+ is_deleted?: boolean;
28611
+ sequence_number?: number;
28612
+ updated_at?: string;
28613
+ };
28614
+ Relationships: [{
28615
+ foreignKeyName: "floriday_trade_settings_customers_cache_connection_id_fkey";
28616
+ columns: ["connection_id"];
28617
+ isOneToOne: false;
28618
+ referencedRelation: "floriday_connections";
28619
+ referencedColumns: ["id"];
28620
+ }];
28621
+ };
28108
28622
  floriday_trips_cache: {
28109
28623
  Row: {
28110
28624
  carrier_organization_id: string | null;
@@ -30249,33 +30763,132 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30249
30763
  foreignKeyName: "order_items_order_id_fkey";
30250
30764
  columns: ["order_id"];
30251
30765
  isOneToOne: false;
30252
- referencedRelation: "orders";
30766
+ referencedRelation: "orders";
30767
+ referencedColumns: ["id"];
30768
+ }, {
30769
+ foreignKeyName: "order_items_product_id_fkey";
30770
+ columns: ["product_id"];
30771
+ isOneToOne: false;
30772
+ referencedRelation: "products";
30773
+ referencedColumns: ["id"];
30774
+ }];
30775
+ };
30776
+ order_number_counters: {
30777
+ Row: {
30778
+ last_value: number;
30779
+ updated_at: string;
30780
+ year: number;
30781
+ };
30782
+ Insert: {
30783
+ last_value?: number;
30784
+ updated_at?: string;
30785
+ year: number;
30786
+ };
30787
+ Update: {
30788
+ last_value?: number;
30789
+ updated_at?: string;
30790
+ year?: number;
30791
+ };
30792
+ Relationships: [];
30793
+ };
30794
+ order_shipment_items: {
30795
+ Row: {
30796
+ created_at: string;
30797
+ id: string;
30798
+ order_item_id: string;
30799
+ product_id: string | null;
30800
+ product_name: string;
30801
+ quantity: number;
30802
+ shipment_id: string;
30803
+ updated_at: string;
30804
+ };
30805
+ Insert: {
30806
+ created_at?: string;
30807
+ id?: string;
30808
+ order_item_id: string;
30809
+ product_id?: string | null;
30810
+ product_name: string;
30811
+ quantity: number;
30812
+ shipment_id: string;
30813
+ updated_at?: string;
30814
+ };
30815
+ Update: {
30816
+ created_at?: string;
30817
+ id?: string;
30818
+ order_item_id?: string;
30819
+ product_id?: string | null;
30820
+ product_name?: string;
30821
+ quantity?: number;
30822
+ shipment_id?: string;
30823
+ updated_at?: string;
30824
+ };
30825
+ Relationships: [{
30826
+ foreignKeyName: "order_shipment_items_order_item_id_fkey";
30827
+ columns: ["order_item_id"];
30828
+ isOneToOne: false;
30829
+ referencedRelation: "order_items";
30253
30830
  referencedColumns: ["id"];
30254
30831
  }, {
30255
- foreignKeyName: "order_items_product_id_fkey";
30256
- columns: ["product_id"];
30832
+ foreignKeyName: "order_shipment_items_shipment_id_fkey";
30833
+ columns: ["shipment_id"];
30257
30834
  isOneToOne: false;
30258
- referencedRelation: "products";
30835
+ referencedRelation: "order_shipments";
30259
30836
  referencedColumns: ["id"];
30260
30837
  }];
30261
30838
  };
30262
- order_number_counters: {
30839
+ order_shipments: {
30263
30840
  Row: {
30264
- last_value: number;
30841
+ carrier_id: string | null;
30842
+ created_at: string;
30843
+ delivery_date: string | null;
30844
+ delivery_location_id: string | null;
30845
+ id: string;
30846
+ notes: string | null;
30847
+ order_id: string;
30848
+ shipment_number: number;
30849
+ shipped_at: string | null;
30850
+ status: string;
30265
30851
  updated_at: string;
30266
- year: number;
30267
30852
  };
30268
30853
  Insert: {
30269
- last_value?: number;
30854
+ carrier_id?: string | null;
30855
+ created_at?: string;
30856
+ delivery_date?: string | null;
30857
+ delivery_location_id?: string | null;
30858
+ id?: string;
30859
+ notes?: string | null;
30860
+ order_id: string;
30861
+ shipment_number: number;
30862
+ shipped_at?: string | null;
30863
+ status?: string;
30270
30864
  updated_at?: string;
30271
- year: number;
30272
30865
  };
30273
30866
  Update: {
30274
- last_value?: number;
30867
+ carrier_id?: string | null;
30868
+ created_at?: string;
30869
+ delivery_date?: string | null;
30870
+ delivery_location_id?: string | null;
30871
+ id?: string;
30872
+ notes?: string | null;
30873
+ order_id?: string;
30874
+ shipment_number?: number;
30875
+ shipped_at?: string | null;
30876
+ status?: string;
30275
30877
  updated_at?: string;
30276
- year?: number;
30277
30878
  };
30278
- Relationships: [];
30879
+ Relationships: [{
30880
+ foreignKeyName: "order_shipments_carrier_id_fkey";
30881
+ columns: ["carrier_id"];
30882
+ isOneToOne: false;
30883
+ referencedRelation: "carriers";
30884
+ referencedColumns: ["id"];
30885
+ }, {
30886
+ foreignKeyName: "order_shipments_order_id_fkey";
30887
+ columns: ["order_id"];
30888
+ isOneToOne: false;
30889
+ referencedRelation: "orders";
30890
+ referencedColumns: ["id"];
30891
+ }];
30279
30892
  };
30280
30893
  orders: {
30281
30894
  Row: {
@@ -30284,8 +30897,9 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30284
30897
  customer_id: string | null;
30285
30898
  customer_name: string;
30286
30899
  deleted_at: string | null;
30287
- delivery_date: string;
30900
+ delivery_date: string | null;
30288
30901
  id: string;
30902
+ is_reservation: boolean;
30289
30903
  notes: string | null;
30290
30904
  order_date: string;
30291
30905
  order_number: string;
@@ -30302,8 +30916,9 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30302
30916
  customer_id?: string | null;
30303
30917
  customer_name?: string;
30304
30918
  deleted_at?: string | null;
30305
- delivery_date: string;
30919
+ delivery_date?: string | null;
30306
30920
  id?: string;
30921
+ is_reservation?: boolean;
30307
30922
  notes?: string | null;
30308
30923
  order_date?: string;
30309
30924
  order_number: string;
@@ -30320,8 +30935,9 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30320
30935
  customer_id?: string | null;
30321
30936
  customer_name?: string;
30322
30937
  deleted_at?: string | null;
30323
- delivery_date?: string;
30938
+ delivery_date?: string | null;
30324
30939
  id?: string;
30940
+ is_reservation?: boolean;
30325
30941
  notes?: string | null;
30326
30942
  order_date?: string;
30327
30943
  order_number?: string;
@@ -30463,6 +31079,63 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30463
31079
  };
30464
31080
  Relationships: [];
30465
31081
  };
31082
+ product_bom_items: {
31083
+ Row: {
31084
+ component_product_id: string | null;
31085
+ component_trade_item_floriday_id: string | null;
31086
+ created_at: string;
31087
+ id: string;
31088
+ notes: string | null;
31089
+ parent_product_id: string | null;
31090
+ parent_trade_item_floriday_id: string | null;
31091
+ quantity: number;
31092
+ sort_order: number;
31093
+ tenant_id: string;
31094
+ unit: string;
31095
+ updated_at: string;
31096
+ };
31097
+ Insert: {
31098
+ component_product_id?: string | null;
31099
+ component_trade_item_floriday_id?: string | null;
31100
+ created_at?: string;
31101
+ id?: string;
31102
+ notes?: string | null;
31103
+ parent_product_id?: string | null;
31104
+ parent_trade_item_floriday_id?: string | null;
31105
+ quantity?: number;
31106
+ sort_order?: number;
31107
+ tenant_id: string;
31108
+ unit?: string;
31109
+ updated_at?: string;
31110
+ };
31111
+ Update: {
31112
+ component_product_id?: string | null;
31113
+ component_trade_item_floriday_id?: string | null;
31114
+ created_at?: string;
31115
+ id?: string;
31116
+ notes?: string | null;
31117
+ parent_product_id?: string | null;
31118
+ parent_trade_item_floriday_id?: string | null;
31119
+ quantity?: number;
31120
+ sort_order?: number;
31121
+ tenant_id?: string;
31122
+ unit?: string;
31123
+ updated_at?: string;
31124
+ };
31125
+ Relationships: [{
31126
+ foreignKeyName: "product_bom_items_component_product_id_fkey";
31127
+ columns: ["component_product_id"];
31128
+ isOneToOne: false;
31129
+ referencedRelation: "products";
31130
+ referencedColumns: ["id"];
31131
+ }, {
31132
+ foreignKeyName: "product_bom_items_parent_product_id_fkey";
31133
+ columns: ["parent_product_id"];
31134
+ isOneToOne: false;
31135
+ referencedRelation: "products";
31136
+ referencedColumns: ["id"];
31137
+ }];
31138
+ };
30466
31139
  product_categories: {
30467
31140
  Row: {
30468
31141
  color: string;
@@ -30568,6 +31241,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30568
31241
  id: string;
30569
31242
  product_group_id: string;
30570
31243
  quantity: number;
31244
+ sort_order: number;
30571
31245
  trade_item_id: string;
30572
31246
  };
30573
31247
  Insert: {
@@ -30575,6 +31249,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30575
31249
  id?: string;
30576
31250
  product_group_id: string;
30577
31251
  quantity?: number;
31252
+ sort_order?: number;
30578
31253
  trade_item_id: string;
30579
31254
  };
30580
31255
  Update: {
@@ -30582,6 +31257,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30582
31257
  id?: string;
30583
31258
  product_group_id?: string;
30584
31259
  quantity?: number;
31260
+ sort_order?: number;
30585
31261
  trade_item_id?: string;
30586
31262
  };
30587
31263
  Relationships: [{
@@ -30596,6 +31272,8 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30596
31272
  Row: {
30597
31273
  created_at: string;
30598
31274
  description: string | null;
31275
+ head_product_id: string | null;
31276
+ head_trade_item_floriday_id: string | null;
30599
31277
  id: string;
30600
31278
  is_active: boolean;
30601
31279
  name: string;
@@ -30605,6 +31283,8 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30605
31283
  Insert: {
30606
31284
  created_at?: string;
30607
31285
  description?: string | null;
31286
+ head_product_id?: string | null;
31287
+ head_trade_item_floriday_id?: string | null;
30608
31288
  id?: string;
30609
31289
  is_active?: boolean;
30610
31290
  name: string;
@@ -30614,21 +31294,126 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30614
31294
  Update: {
30615
31295
  created_at?: string;
30616
31296
  description?: string | null;
31297
+ head_product_id?: string | null;
31298
+ head_trade_item_floriday_id?: string | null;
30617
31299
  id?: string;
30618
31300
  is_active?: boolean;
30619
31301
  name?: string;
30620
31302
  tenant_id?: string;
30621
31303
  updated_at?: string;
30622
31304
  };
31305
+ Relationships: [{
31306
+ foreignKeyName: "product_groups_head_product_id_fkey";
31307
+ columns: ["head_product_id"];
31308
+ isOneToOne: false;
31309
+ referencedRelation: "products";
31310
+ referencedColumns: ["id"];
31311
+ }];
31312
+ };
31313
+ product_load_settings: {
31314
+ Row: {
31315
+ created_at: string;
31316
+ id: string;
31317
+ is_package: boolean;
31318
+ layers_per_load_carrier: number | null;
31319
+ load_carrier: string | null;
31320
+ package_id: string | null;
31321
+ package_label: string | null;
31322
+ packages_per_layer: number | null;
31323
+ product_id: string | null;
31324
+ tenant_id: string;
31325
+ trade_item_floriday_id: string | null;
31326
+ units_per_package: number | null;
31327
+ updated_at: string;
31328
+ };
31329
+ Insert: {
31330
+ created_at?: string;
31331
+ id?: string;
31332
+ is_package?: boolean;
31333
+ layers_per_load_carrier?: number | null;
31334
+ load_carrier?: string | null;
31335
+ package_id?: string | null;
31336
+ package_label?: string | null;
31337
+ packages_per_layer?: number | null;
31338
+ product_id?: string | null;
31339
+ tenant_id: string;
31340
+ trade_item_floriday_id?: string | null;
31341
+ units_per_package?: number | null;
31342
+ updated_at?: string;
31343
+ };
31344
+ Update: {
31345
+ created_at?: string;
31346
+ id?: string;
31347
+ is_package?: boolean;
31348
+ layers_per_load_carrier?: number | null;
31349
+ load_carrier?: string | null;
31350
+ package_id?: string | null;
31351
+ package_label?: string | null;
31352
+ packages_per_layer?: number | null;
31353
+ product_id?: string | null;
31354
+ tenant_id?: string;
31355
+ trade_item_floriday_id?: string | null;
31356
+ units_per_package?: number | null;
31357
+ updated_at?: string;
31358
+ };
31359
+ Relationships: [{
31360
+ foreignKeyName: "product_load_settings_package_id_fkey";
31361
+ columns: ["package_id"];
31362
+ isOneToOne: false;
31363
+ referencedRelation: "packages";
31364
+ referencedColumns: ["id"];
31365
+ }, {
31366
+ foreignKeyName: "product_load_settings_product_id_fkey";
31367
+ columns: ["product_id"];
31368
+ isOneToOne: false;
31369
+ referencedRelation: "products";
31370
+ referencedColumns: ["id"];
31371
+ }];
31372
+ };
31373
+ product_merge_log: {
31374
+ Row: {
31375
+ canonical_product_id: string | null;
31376
+ id: string;
31377
+ merged_at: string;
31378
+ merged_from_id: string;
31379
+ notes: string | null;
31380
+ snapshot: import("../integrations/supabase/types").Json;
31381
+ source_table: string;
31382
+ status: string;
31383
+ };
31384
+ Insert: {
31385
+ canonical_product_id?: string | null;
31386
+ id?: string;
31387
+ merged_at?: string;
31388
+ merged_from_id: string;
31389
+ notes?: string | null;
31390
+ snapshot?: import("../integrations/supabase/types").Json;
31391
+ source_table: string;
31392
+ status?: string;
31393
+ };
31394
+ Update: {
31395
+ canonical_product_id?: string | null;
31396
+ id?: string;
31397
+ merged_at?: string;
31398
+ merged_from_id?: string;
31399
+ notes?: string | null;
31400
+ snapshot?: import("../integrations/supabase/types").Json;
31401
+ source_table?: string;
31402
+ status?: string;
31403
+ };
30623
31404
  Relationships: [];
30624
31405
  };
30625
31406
  products: {
30626
31407
  Row: {
31408
+ article_number: string | null;
30627
31409
  barcode: string | null;
30628
31410
  batch: string;
30629
31411
  crates_per_layer: number;
30630
31412
  created_at: string;
30631
31413
  custom_fields: import("../integrations/supabase/types").Json;
31414
+ floriday_active: boolean;
31415
+ floriday_payload: import("../integrations/supabase/types").Json;
31416
+ floriday_trade_item_id: string | null;
30632
31417
  id: string;
30633
31418
  image_url: string | null;
30634
31419
  incoming_quantity: number;
@@ -30647,11 +31432,15 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30647
31432
  weight: string | null;
30648
31433
  };
30649
31434
  Insert: {
31435
+ article_number?: string | null;
30650
31436
  barcode?: string | null;
30651
31437
  batch: string;
30652
31438
  crates_per_layer?: number;
30653
31439
  created_at?: string;
30654
31440
  custom_fields?: import("../integrations/supabase/types").Json;
31441
+ floriday_active?: boolean;
31442
+ floriday_payload?: import("../integrations/supabase/types").Json;
31443
+ floriday_trade_item_id?: string | null;
30655
31444
  id?: string;
30656
31445
  image_url?: string | null;
30657
31446
  incoming_quantity?: number;
@@ -30670,11 +31459,15 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
30670
31459
  weight?: string | null;
30671
31460
  };
30672
31461
  Update: {
31462
+ article_number?: string | null;
30673
31463
  barcode?: string | null;
30674
31464
  batch?: string;
30675
31465
  crates_per_layer?: number;
30676
31466
  created_at?: string;
30677
31467
  custom_fields?: import("../integrations/supabase/types").Json;
31468
+ floriday_active?: boolean;
31469
+ floriday_payload?: import("../integrations/supabase/types").Json;
31470
+ floriday_trade_item_id?: string | null;
30678
31471
  id?: string;
30679
31472
  image_url?: string | null;
30680
31473
  incoming_quantity?: number;
@@ -31583,8 +32376,10 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
31583
32376
  order_id: string | null;
31584
32377
  order_item_id: string | null;
31585
32378
  order_source: string | null;
32379
+ parent_trade_item_key: string | null;
31586
32380
  physical_after: number | null;
31587
32381
  physical_before: number | null;
32382
+ production_batch_id: string | null;
31588
32383
  qty_delta: number;
31589
32384
  reason: string | null;
31590
32385
  reserved_after: number | null;
@@ -31600,8 +32395,10 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
31600
32395
  order_id?: string | null;
31601
32396
  order_item_id?: string | null;
31602
32397
  order_source?: string | null;
32398
+ parent_trade_item_key?: string | null;
31603
32399
  physical_after?: number | null;
31604
32400
  physical_before?: number | null;
32401
+ production_batch_id?: string | null;
31605
32402
  qty_delta: number;
31606
32403
  reason?: string | null;
31607
32404
  reserved_after?: number | null;
@@ -31617,8 +32414,10 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
31617
32414
  order_id?: string | null;
31618
32415
  order_item_id?: string | null;
31619
32416
  order_source?: string | null;
32417
+ parent_trade_item_key?: string | null;
31620
32418
  physical_after?: number | null;
31621
32419
  physical_before?: number | null;
32420
+ production_batch_id?: string | null;
31622
32421
  qty_delta?: number;
31623
32422
  reason?: string | null;
31624
32423
  reserved_after?: number | null;
@@ -32077,7 +32876,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
32077
32876
  twinfield_connections: {
32078
32877
  Row: {
32079
32878
  access_token: string | null;
32080
- client_id: string;
32879
+ client_id: string | null;
32081
32880
  client_secret: string | null;
32082
32881
  cluster_uri: string | null;
32083
32882
  company_code: string | null;
@@ -32089,7 +32888,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
32089
32888
  is_active: boolean;
32090
32889
  label: string | null;
32091
32890
  office_code: string | null;
32092
- redirect_uri: string;
32891
+ redirect_uri: string | null;
32093
32892
  refresh_token: string | null;
32094
32893
  token_expires_at: string | null;
32095
32894
  updated_at: string;
@@ -32097,7 +32896,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
32097
32896
  };
32098
32897
  Insert: {
32099
32898
  access_token?: string | null;
32100
- client_id: string;
32899
+ client_id?: string | null;
32101
32900
  client_secret?: string | null;
32102
32901
  cluster_uri?: string | null;
32103
32902
  company_code?: string | null;
@@ -32109,7 +32908,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
32109
32908
  is_active?: boolean;
32110
32909
  label?: string | null;
32111
32910
  office_code?: string | null;
32112
- redirect_uri: string;
32911
+ redirect_uri?: string | null;
32113
32912
  refresh_token?: string | null;
32114
32913
  token_expires_at?: string | null;
32115
32914
  updated_at?: string;
@@ -32117,7 +32916,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
32117
32916
  };
32118
32917
  Update: {
32119
32918
  access_token?: string | null;
32120
- client_id?: string;
32919
+ client_id?: string | null;
32121
32920
  client_secret?: string | null;
32122
32921
  cluster_uri?: string | null;
32123
32922
  company_code?: string | null;
@@ -32129,7 +32928,7 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
32129
32928
  is_active?: boolean;
32130
32929
  label?: string | null;
32131
32930
  office_code?: string | null;
32132
- redirect_uri?: string;
32931
+ redirect_uri?: string | null;
32133
32932
  refresh_token?: string | null;
32134
32933
  token_expires_at?: string | null;
32135
32934
  updated_at?: string;
@@ -33324,25 +34123,6 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
33324
34123
  };
33325
34124
  Relationships: [];
33326
34125
  };
33327
- floriday_customer_discounts: {
33328
- Row: {
33329
- base_price: number | null;
33330
- buyer_organization_id: string | null;
33331
- currency: string | null;
33332
- discount_type: string | null;
33333
- discount_value: number | null;
33334
- min_quantity: number | null;
33335
- net_price: number | null;
33336
- product_group_id: string | null;
33337
- raw: import("../integrations/supabase/types").Json | null;
33338
- source: string | null;
33339
- source_id: string | null;
33340
- trade_item_id: string | null;
33341
- valid_from: string | null;
33342
- valid_until: string | null;
33343
- };
33344
- Relationships: [];
33345
- };
33346
34126
  local_customer_discounts: {
33347
34127
  Row: {
33348
34128
  base_price: number | null;
@@ -33646,6 +34426,13 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
33646
34426
  };
33647
34427
  Returns: number;
33648
34428
  };
34429
+ _migrate_rewrite_stock_key: {
34430
+ Args: {
34431
+ _from_key: string;
34432
+ _to_key: string;
34433
+ };
34434
+ Returns: undefined;
34435
+ };
33649
34436
  afh_city_code: {
33650
34437
  Args: {
33651
34438
  _city: string;
@@ -33761,6 +34548,28 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
33761
34548
  Args: never;
33762
34549
  Returns: undefined;
33763
34550
  };
34551
+ consume_bom_for_production: {
34552
+ Args: {
34553
+ p_connection_id: string;
34554
+ p_parent_id: string;
34555
+ p_parent_key: string;
34556
+ p_parent_kind: string;
34557
+ p_quantity: number;
34558
+ p_user_id: string;
34559
+ };
34560
+ Returns: import("../integrations/supabase/types").Json;
34561
+ } | {
34562
+ Args: {
34563
+ p_batch_id?: string;
34564
+ p_connection_id: string;
34565
+ p_parent_id: string;
34566
+ p_parent_key: string;
34567
+ p_parent_kind: string;
34568
+ p_quantity: number;
34569
+ p_user_id: string;
34570
+ };
34571
+ Returns: import("../integrations/supabase/types").Json;
34572
+ };
33764
34573
  consume_floriday_rate_limit: {
33765
34574
  Args: {
33766
34575
  p_bucket: string;
@@ -33812,6 +34621,13 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
33812
34621
  table_name: string;
33813
34622
  }[];
33814
34623
  };
34624
+ delete_samenstelling: {
34625
+ Args: {
34626
+ p_parent_id: string;
34627
+ p_parent_kind: string;
34628
+ };
34629
+ Returns: import("../integrations/supabase/types").Json;
34630
+ };
33815
34631
  dispatch_carrier_signups_sql: {
33816
34632
  Args: {
33817
34633
  _catchup?: string;
@@ -33972,19 +34788,6 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
33972
34788
  resource: string;
33973
34789
  }[];
33974
34790
  };
33975
- get_floriday_agreements_active: {
33976
- Args: {
33977
- p_on_date?: string;
33978
- };
33979
- Returns: {
33980
- buyer_organization_id: string;
33981
- data: import("../integrations/supabase/types").Json;
33982
- floriday_id: string;
33983
- status: string;
33984
- valid_from: string;
33985
- valid_until: string;
33986
- }[];
33987
- };
33988
34791
  get_floriday_clock_supplies_window: {
33989
34792
  Args: {
33990
34793
  p_from: string;
@@ -34057,6 +34860,21 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
34057
34860
  minutes_since_success: number;
34058
34861
  }[];
34059
34862
  };
34863
+ get_group_allocation_keys: {
34864
+ Args: {
34865
+ p_product_id: string;
34866
+ };
34867
+ Returns: {
34868
+ k: string;
34869
+ ord: number;
34870
+ }[];
34871
+ };
34872
+ get_group_head_key: {
34873
+ Args: {
34874
+ p_group_id: string;
34875
+ };
34876
+ Returns: string;
34877
+ };
34060
34878
  get_offer_by_link_code: {
34061
34879
  Args: {
34062
34880
  p_code: string;
@@ -34167,6 +34985,19 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
34167
34985
  };
34168
34986
  Returns: undefined;
34169
34987
  };
34988
+ mark_shipment_shipped: {
34989
+ Args: {
34990
+ p_shipment_id: string;
34991
+ };
34992
+ Returns: undefined;
34993
+ };
34994
+ merge_products: {
34995
+ Args: {
34996
+ _canonical: string;
34997
+ _loser: string;
34998
+ };
34999
+ Returns: undefined;
35000
+ };
34170
35001
  next_manufacture_partij: {
34171
35002
  Args: {
34172
35003
  _tenant_id: string;
@@ -34251,6 +35082,14 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
34251
35082
  };
34252
35083
  Returns: undefined;
34253
35084
  };
35085
+ produce_designed_product: {
35086
+ Args: {
35087
+ p_parent_id: string;
35088
+ p_parent_kind: string;
35089
+ p_quantity: number;
35090
+ };
35091
+ Returns: import("../integrations/supabase/types").Json;
35092
+ };
34254
35093
  promote_trade_item_key: {
34255
35094
  Args: {
34256
35095
  p_new: string;
@@ -34258,6 +35097,10 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
34258
35097
  };
34259
35098
  Returns: undefined;
34260
35099
  };
35100
+ recompute_all_reserved_stock: {
35101
+ Args: never;
35102
+ Returns: undefined;
35103
+ };
34261
35104
  recompute_order_status: {
34262
35105
  Args: {
34263
35106
  p_order_id: string;
@@ -34307,27 +35150,45 @@ export declare const retryAutoFulfillment: import("@tanstack/start-client-core")
34307
35150
  };
34308
35151
  Returns: undefined;
34309
35152
  };
35153
+ resolve_group_allocation: {
35154
+ Args: {
35155
+ _needed: number;
35156
+ _product_group_id: string;
35157
+ };
35158
+ Returns: {
35159
+ allocated: number;
35160
+ trade_item_id: string;
35161
+ }[];
35162
+ };
35163
+ resolve_group_member_stock_key: {
35164
+ Args: {
35165
+ p_trade_item_id: string;
35166
+ };
35167
+ Returns: string;
35168
+ };
34310
35169
  resolve_product_id_for_item: {
34311
35170
  Args: {
34312
35171
  p_product_name: string;
34313
35172
  };
34314
35173
  Returns: string;
34315
35174
  };
34316
- schedule_floriday_additional_services_sync: {
35175
+ resolve_stock_trade_item_key: {
34317
35176
  Args: {
34318
- p_apikey: string;
34319
- p_url: string;
35177
+ p_product_id: string;
34320
35178
  };
34321
- Returns: number;
35179
+ Returns: string;
34322
35180
  };
34323
- schedule_floriday_agreement_calloffs_sync: {
35181
+ reverse_production: {
34324
35182
  Args: {
34325
- p_apikey: string;
34326
- p_url: string;
35183
+ p_connection_id?: string;
35184
+ p_parent_key: string;
35185
+ p_quantity: number;
35186
+ p_reason?: string;
35187
+ p_user_id?: string;
34327
35188
  };
34328
- Returns: number;
35189
+ Returns: import("../integrations/supabase/types").Json;
34329
35190
  };
34330
- schedule_floriday_agreements_sync: {
35191
+ schedule_floriday_additional_services_sync: {
34331
35192
  Args: {
34332
35193
  p_apikey: string;
34333
35194
  p_url: string;