@flowselections/floriday-verkoop-module 1.0.12 → 1.0.13

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 (64) hide show
  1. package/dist-lib/components/verkoop/AutoFulfillmentStatusCard.d.ts +4 -0
  2. package/dist-lib/components/verkoop/AutoFulfillmentStatusCard.d.ts.map +1 -0
  3. package/dist-lib/components/verkoop/AutoFulfillmentStatusCard.js +95 -0
  4. package/dist-lib/components/verkoop/CartAssignmentWizard.d.ts +6 -0
  5. package/dist-lib/components/verkoop/CartAssignmentWizard.d.ts.map +1 -0
  6. package/dist-lib/components/verkoop/CartAssignmentWizard.js +194 -0
  7. package/dist-lib/components/verkoop/CreateOrderPage.d.ts.map +1 -1
  8. package/dist-lib/components/verkoop/CreateOrderPage.js +14 -4
  9. package/dist-lib/components/verkoop/OrderAfleverbrievenCard.d.ts +4 -0
  10. package/dist-lib/components/verkoop/OrderAfleverbrievenCard.d.ts.map +1 -0
  11. package/dist-lib/components/verkoop/OrderAfleverbrievenCard.js +44 -0
  12. package/dist-lib/components/verkoop/OrderKarindelingCard.d.ts +5 -0
  13. package/dist-lib/components/verkoop/OrderKarindelingCard.d.ts.map +1 -0
  14. package/dist-lib/components/verkoop/OrderKarindelingCard.js +160 -0
  15. package/dist-lib/components/verkoop/SalesOrderDetailView.d.ts.map +1 -1
  16. package/dist-lib/components/verkoop/SalesOrderDetailView.js +6 -3
  17. package/dist-lib/components/verkoop/VerkoopOrdersPage.d.ts.map +1 -1
  18. package/dist-lib/components/verkoop/VerkoopOrdersPage.js +39 -3
  19. package/dist-lib/integrations/supabase/auth-middleware.d.ts +473 -3
  20. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  21. package/dist-lib/integrations/supabase/client.d.ts +473 -3
  22. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  23. package/dist-lib/integrations/supabase/client.server.d.ts +473 -3
  24. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  25. package/dist-lib/integrations/supabase/types.d.ts +481 -3
  26. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  27. package/dist-lib/lib/cart-lock.functions.d.ts +11225 -0
  28. package/dist-lib/lib/cart-lock.functions.d.ts.map +1 -0
  29. package/dist-lib/lib/cart-lock.functions.js +47 -0
  30. package/dist-lib/lib/cart-planner.d.ts +38 -0
  31. package/dist-lib/lib/cart-planner.d.ts.map +1 -0
  32. package/dist-lib/lib/cart-planner.js +217 -0
  33. package/dist-lib/lib/cart-replan.functions.d.ts +22467 -0
  34. package/dist-lib/lib/cart-replan.functions.d.ts.map +1 -0
  35. package/dist-lib/lib/cart-replan.functions.js +203 -0
  36. package/dist-lib/lib/create-order.functions.d.ts +25821 -77
  37. package/dist-lib/lib/create-order.functions.d.ts.map +1 -1
  38. package/dist-lib/lib/create-order.functions.js +158 -3
  39. package/dist-lib/lib/floriday-auto-fulfillment.functions.d.ts +33640 -0
  40. package/dist-lib/lib/floriday-auto-fulfillment.functions.d.ts.map +1 -0
  41. package/dist-lib/lib/floriday-auto-fulfillment.functions.js +65 -0
  42. package/dist-lib/lib/floriday-auto-fulfillment.server.d.ts +21 -0
  43. package/dist-lib/lib/floriday-auto-fulfillment.server.d.ts.map +1 -0
  44. package/dist-lib/lib/floriday-auto-fulfillment.server.js +352 -0
  45. package/dist-lib/lib/floriday-logistic-labels.functions.d.ts +11220 -0
  46. package/dist-lib/lib/floriday-logistic-labels.functions.d.ts.map +1 -0
  47. package/dist-lib/lib/floriday-logistic-labels.functions.js +171 -0
  48. package/dist-lib/lib/floriday-public.functions.d.ts +3313 -37
  49. package/dist-lib/lib/floriday-public.functions.d.ts.map +1 -1
  50. package/dist-lib/lib/floriday-public.functions.js +45 -47
  51. package/dist-lib/lib/floriday-writes.functions.d.ts +2365 -15
  52. package/dist-lib/lib/floriday-writes.functions.d.ts.map +1 -1
  53. package/dist-lib/lib/salesorders-mapping.d.ts +2 -0
  54. package/dist-lib/lib/salesorders-mapping.d.ts.map +1 -1
  55. package/dist-lib/lib/salesorders-mapping.js +46 -20
  56. package/dist-lib/lib/salesorders.functions.d.ts +1420 -10
  57. package/dist-lib/lib/salesorders.functions.d.ts.map +1 -1
  58. package/dist-lib/lib/salesorders.functions.js +8 -0
  59. package/dist-lib/lib/tradeitems.functions.d.ts +473 -3
  60. package/dist-lib/lib/tradeitems.functions.d.ts.map +1 -1
  61. package/dist-lib/lib/useSalesOrdersQuery.d.ts +1 -0
  62. package/dist-lib/lib/useSalesOrdersQuery.d.ts.map +1 -1
  63. package/dist-lib/lib/useSalesOrdersQuery.js +121 -39
  64. package/package.json +1 -1
@@ -4,7 +4,10 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
4
4
  Tables: {
5
5
  afhandeling_settings: {
6
6
  Row: {
7
+ auto_print_delivery_note: boolean;
8
+ auto_process_paused: boolean;
7
9
  created_at: string;
10
+ extra_pick_days_with_stickers: number;
8
11
  id: string;
9
12
  max_workdays_earlier_pick: number;
10
13
  pick_days_before_transport: number;
@@ -18,7 +21,10 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
18
21
  user_id: string;
19
22
  };
20
23
  Insert: {
24
+ auto_print_delivery_note?: boolean;
25
+ auto_process_paused?: boolean;
21
26
  created_at?: string;
27
+ extra_pick_days_with_stickers?: number;
22
28
  id?: string;
23
29
  max_workdays_earlier_pick?: number;
24
30
  pick_days_before_transport?: number;
@@ -32,7 +38,10 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
32
38
  user_id: string;
33
39
  };
34
40
  Update: {
41
+ auto_print_delivery_note?: boolean;
42
+ auto_process_paused?: boolean;
35
43
  created_at?: string;
44
+ extra_pick_days_with_stickers?: number;
36
45
  id?: string;
37
46
  max_workdays_earlier_pick?: number;
38
47
  pick_days_before_transport?: number;
@@ -824,6 +833,36 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
824
833
  };
825
834
  Relationships: [];
826
835
  };
836
+ cart_replan_queue: {
837
+ Row: {
838
+ attempts: number;
839
+ last_error: string | null;
840
+ order_id: string;
841
+ processed_at: string | null;
842
+ requested_at: string;
843
+ };
844
+ Insert: {
845
+ attempts?: number;
846
+ last_error?: string | null;
847
+ order_id: string;
848
+ processed_at?: string | null;
849
+ requested_at?: string;
850
+ };
851
+ Update: {
852
+ attempts?: number;
853
+ last_error?: string | null;
854
+ order_id?: string;
855
+ processed_at?: string | null;
856
+ requested_at?: string;
857
+ };
858
+ Relationships: [{
859
+ foreignKeyName: "cart_replan_queue_order_id_fkey";
860
+ columns: ["order_id"];
861
+ isOneToOne: true;
862
+ referencedRelation: "orders";
863
+ referencedColumns: ["id"];
864
+ }];
865
+ };
827
866
  collections: {
828
867
  Row: {
829
868
  created_at: string;
@@ -2949,34 +2988,52 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
2949
2988
  Row: {
2950
2989
  catalog_key: string | null;
2951
2990
  catalog_url: string;
2991
+ client_id: string | null;
2992
+ client_secret_ciphertext: string | null;
2993
+ client_secret_last4: string | null;
2952
2994
  created_at: string;
2953
2995
  id: number;
2954
2996
  last_meta: import("../integrations/supabase/types").Json | null;
2955
2997
  last_test_at: string | null;
2956
2998
  last_test_error: string | null;
2957
2999
  last_test_ok: boolean | null;
3000
+ last_token_test_at: string | null;
3001
+ last_token_test_error: string | null;
3002
+ last_token_test_ok: boolean | null;
2958
3003
  updated_at: string;
2959
3004
  };
2960
3005
  Insert: {
2961
3006
  catalog_key?: string | null;
2962
3007
  catalog_url?: string;
3008
+ client_id?: string | null;
3009
+ client_secret_ciphertext?: string | null;
3010
+ client_secret_last4?: string | null;
2963
3011
  created_at?: string;
2964
3012
  id?: number;
2965
3013
  last_meta?: import("../integrations/supabase/types").Json | null;
2966
3014
  last_test_at?: string | null;
2967
3015
  last_test_error?: string | null;
2968
3016
  last_test_ok?: boolean | null;
3017
+ last_token_test_at?: string | null;
3018
+ last_token_test_error?: string | null;
3019
+ last_token_test_ok?: boolean | null;
2969
3020
  updated_at?: string;
2970
3021
  };
2971
3022
  Update: {
2972
3023
  catalog_key?: string | null;
2973
3024
  catalog_url?: string;
3025
+ client_id?: string | null;
3026
+ client_secret_ciphertext?: string | null;
3027
+ client_secret_last4?: string | null;
2974
3028
  created_at?: string;
2975
3029
  id?: number;
2976
3030
  last_meta?: import("../integrations/supabase/types").Json | null;
2977
3031
  last_test_at?: string | null;
2978
3032
  last_test_error?: string | null;
2979
3033
  last_test_ok?: boolean | null;
3034
+ last_token_test_at?: string | null;
3035
+ last_token_test_error?: string | null;
3036
+ last_token_test_ok?: boolean | null;
2980
3037
  updated_at?: string;
2981
3038
  };
2982
3039
  Relationships: [];
@@ -3209,6 +3266,54 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
3209
3266
  referencedColumns: ["id"];
3210
3267
  }];
3211
3268
  };
3269
+ floriday_auto_fulfillment_log: {
3270
+ Row: {
3271
+ attempts: number;
3272
+ connection_id: string;
3273
+ created_at: string;
3274
+ error: string | null;
3275
+ fulfillment_order_id: string | null;
3276
+ id: string;
3277
+ last_attempt_at: string | null;
3278
+ reason: string | null;
3279
+ sales_order_id: string;
3280
+ status: string;
3281
+ updated_at: string;
3282
+ };
3283
+ Insert: {
3284
+ attempts?: number;
3285
+ connection_id: string;
3286
+ created_at?: string;
3287
+ error?: string | null;
3288
+ fulfillment_order_id?: string | null;
3289
+ id?: string;
3290
+ last_attempt_at?: string | null;
3291
+ reason?: string | null;
3292
+ sales_order_id: string;
3293
+ status?: string;
3294
+ updated_at?: string;
3295
+ };
3296
+ Update: {
3297
+ attempts?: number;
3298
+ connection_id?: string;
3299
+ created_at?: string;
3300
+ error?: string | null;
3301
+ fulfillment_order_id?: string | null;
3302
+ id?: string;
3303
+ last_attempt_at?: string | null;
3304
+ reason?: string | null;
3305
+ sales_order_id?: string;
3306
+ status?: string;
3307
+ updated_at?: string;
3308
+ };
3309
+ Relationships: [{
3310
+ foreignKeyName: "floriday_auto_fulfillment_log_connection_id_fkey";
3311
+ columns: ["connection_id"];
3312
+ isOneToOne: false;
3313
+ referencedRelation: "floriday_connections";
3314
+ referencedColumns: ["id"];
3315
+ }];
3316
+ };
3212
3317
  floriday_base_items_cache: {
3213
3318
  Row: {
3214
3319
  connection_id: string;
@@ -4313,6 +4418,24 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
4313
4418
  referencedColumns: ["id"];
4314
4419
  }];
4315
4420
  };
4421
+ floriday_rate_limit_state: {
4422
+ Row: {
4423
+ bucket: string;
4424
+ last_refill_at: string;
4425
+ tokens: number;
4426
+ };
4427
+ Insert: {
4428
+ bucket: string;
4429
+ last_refill_at?: string;
4430
+ tokens: number;
4431
+ };
4432
+ Update: {
4433
+ bucket?: string;
4434
+ last_refill_at?: string;
4435
+ tokens?: number;
4436
+ };
4437
+ Relationships: [];
4438
+ };
4316
4439
  floriday_resource_schemas: {
4317
4440
  Row: {
4318
4441
  enums: import("../integrations/supabase/types").Json;
@@ -4736,6 +4859,60 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
4736
4859
  referencedColumns: ["id"];
4737
4860
  }];
4738
4861
  };
4862
+ flow_role_assignments: {
4863
+ Row: {
4864
+ created_at: string;
4865
+ id: string;
4866
+ role_id: string;
4867
+ user_id: string;
4868
+ };
4869
+ Insert: {
4870
+ created_at?: string;
4871
+ id?: string;
4872
+ role_id: string;
4873
+ user_id: string;
4874
+ };
4875
+ Update: {
4876
+ created_at?: string;
4877
+ id?: string;
4878
+ role_id?: string;
4879
+ user_id?: string;
4880
+ };
4881
+ Relationships: [{
4882
+ foreignKeyName: "flow_role_assignments_role_id_fkey";
4883
+ columns: ["role_id"];
4884
+ isOneToOne: false;
4885
+ referencedRelation: "flow_roles";
4886
+ referencedColumns: ["id"];
4887
+ }];
4888
+ };
4889
+ flow_roles: {
4890
+ Row: {
4891
+ created_at: string;
4892
+ description: string | null;
4893
+ id: string;
4894
+ module_access: string[];
4895
+ name: string;
4896
+ updated_at: string;
4897
+ };
4898
+ Insert: {
4899
+ created_at?: string;
4900
+ description?: string | null;
4901
+ id?: string;
4902
+ module_access?: string[];
4903
+ name: string;
4904
+ updated_at?: string;
4905
+ };
4906
+ Update: {
4907
+ created_at?: string;
4908
+ description?: string | null;
4909
+ id?: string;
4910
+ module_access?: string[];
4911
+ name?: string;
4912
+ updated_at?: string;
4913
+ };
4914
+ Relationships: [];
4915
+ };
4739
4916
  imap_accounts: {
4740
4917
  Row: {
4741
4918
  created_at: string;
@@ -5367,6 +5544,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
5367
5544
  matched_customer_id: string | null;
5368
5545
  message_id: string;
5369
5546
  notes: string | null;
5547
+ order_number: string | null;
5370
5548
  parsed_payload: import("../integrations/supabase/types").Json | null;
5371
5549
  reviewed_at: string | null;
5372
5550
  reviewed_by: string | null;
@@ -5382,6 +5560,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
5382
5560
  matched_customer_id?: string | null;
5383
5561
  message_id: string;
5384
5562
  notes?: string | null;
5563
+ order_number?: string | null;
5385
5564
  parsed_payload?: import("../integrations/supabase/types").Json | null;
5386
5565
  reviewed_at?: string | null;
5387
5566
  reviewed_by?: string | null;
@@ -5397,6 +5576,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
5397
5576
  matched_customer_id?: string | null;
5398
5577
  message_id?: string;
5399
5578
  notes?: string | null;
5579
+ order_number?: string | null;
5400
5580
  parsed_payload?: import("../integrations/supabase/types").Json | null;
5401
5581
  reviewed_at?: string | null;
5402
5582
  reviewed_by?: string | null;
@@ -6253,6 +6433,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6253
6433
  id: string;
6254
6434
  items: import("../integrations/supabase/types").Json;
6255
6435
  notes: string | null;
6436
+ order_number: string | null;
6256
6437
  recipient_id: string;
6257
6438
  total_amount: number;
6258
6439
  };
@@ -6266,6 +6447,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6266
6447
  id?: string;
6267
6448
  items?: import("../integrations/supabase/types").Json;
6268
6449
  notes?: string | null;
6450
+ order_number?: string | null;
6269
6451
  recipient_id: string;
6270
6452
  total_amount?: number;
6271
6453
  };
@@ -6279,6 +6461,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6279
6461
  id?: string;
6280
6462
  items?: import("../integrations/supabase/types").Json;
6281
6463
  notes?: string | null;
6464
+ order_number?: string | null;
6282
6465
  recipient_id?: string;
6283
6466
  total_amount?: number;
6284
6467
  };
@@ -6438,6 +6621,9 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6438
6621
  crates_per_layer: number;
6439
6622
  created_at: string;
6440
6623
  id: string;
6624
+ layer_fraction: number;
6625
+ layer_share_pct: number;
6626
+ layers_per_cart: number;
6441
6627
  order_item_id: string | null;
6442
6628
  plants_per_crate: number;
6443
6629
  product_id: string | null;
@@ -6449,6 +6635,9 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6449
6635
  crates_per_layer?: number;
6450
6636
  created_at?: string;
6451
6637
  id?: string;
6638
+ layer_fraction?: number;
6639
+ layer_share_pct?: number;
6640
+ layers_per_cart?: number;
6452
6641
  order_item_id?: string | null;
6453
6642
  plants_per_crate?: number;
6454
6643
  product_id?: string | null;
@@ -6460,6 +6649,9 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6460
6649
  crates_per_layer?: number;
6461
6650
  created_at?: string;
6462
6651
  id?: string;
6652
+ layer_fraction?: number;
6653
+ layer_share_pct?: number;
6654
+ layers_per_cart?: number;
6463
6655
  order_item_id?: string | null;
6464
6656
  plants_per_crate?: number;
6465
6657
  product_id?: string | null;
@@ -6487,33 +6679,45 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6487
6679
  };
6488
6680
  order_carts: {
6489
6681
  Row: {
6682
+ algorithm_version: number;
6490
6683
  cart_number: number;
6491
6684
  created_at: string;
6492
6685
  id: string;
6493
6686
  is_auto: boolean;
6494
6687
  is_complete: boolean;
6495
6688
  notes: string | null;
6689
+ occupancy_pct: number;
6496
6690
  order_id: string;
6691
+ source: string;
6692
+ total_layers_used: number;
6497
6693
  updated_at: string;
6498
6694
  };
6499
6695
  Insert: {
6696
+ algorithm_version?: number;
6500
6697
  cart_number: number;
6501
6698
  created_at?: string;
6502
6699
  id?: string;
6503
6700
  is_auto?: boolean;
6504
6701
  is_complete?: boolean;
6505
6702
  notes?: string | null;
6703
+ occupancy_pct?: number;
6506
6704
  order_id: string;
6705
+ source?: string;
6706
+ total_layers_used?: number;
6507
6707
  updated_at?: string;
6508
6708
  };
6509
6709
  Update: {
6710
+ algorithm_version?: number;
6510
6711
  cart_number?: number;
6511
6712
  created_at?: string;
6512
6713
  id?: string;
6513
6714
  is_auto?: boolean;
6514
6715
  is_complete?: boolean;
6515
6716
  notes?: string | null;
6717
+ occupancy_pct?: number;
6516
6718
  order_id?: string;
6719
+ source?: string;
6720
+ total_layers_used?: number;
6517
6721
  updated_at?: string;
6518
6722
  };
6519
6723
  Relationships: [{
@@ -6666,6 +6870,8 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6666
6870
  order_date: string;
6667
6871
  order_number: string;
6668
6872
  order_source: string;
6873
+ plan_locked_at: string | null;
6874
+ plan_locked_ref: string | null;
6669
6875
  status: string;
6670
6876
  total: string;
6671
6877
  updated_at: string;
@@ -6682,6 +6888,8 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6682
6888
  order_date?: string;
6683
6889
  order_number: string;
6684
6890
  order_source?: string;
6891
+ plan_locked_at?: string | null;
6892
+ plan_locked_ref?: string | null;
6685
6893
  status?: string;
6686
6894
  total?: string;
6687
6895
  updated_at?: string;
@@ -6698,6 +6906,8 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
6698
6906
  order_date?: string;
6699
6907
  order_number?: string;
6700
6908
  order_source?: string;
6909
+ plan_locked_at?: string | null;
6910
+ plan_locked_ref?: string | null;
6701
6911
  status?: string;
6702
6912
  total?: string;
6703
6913
  updated_at?: string;
@@ -7070,6 +7280,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7070
7280
  display_name: string | null;
7071
7281
  email: string | null;
7072
7282
  id: string;
7283
+ is_superadmin: boolean;
7073
7284
  notification_preferences: import("../integrations/supabase/types").Json;
7074
7285
  tenant_id: string | null;
7075
7286
  updated_at: string;
@@ -7079,6 +7290,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7079
7290
  display_name?: string | null;
7080
7291
  email?: string | null;
7081
7292
  id: string;
7293
+ is_superadmin?: boolean;
7082
7294
  notification_preferences?: import("../integrations/supabase/types").Json;
7083
7295
  tenant_id?: string | null;
7084
7296
  updated_at?: string;
@@ -7088,6 +7300,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7088
7300
  display_name?: string | null;
7089
7301
  email?: string | null;
7090
7302
  id?: string;
7303
+ is_superadmin?: boolean;
7091
7304
  notification_preferences?: import("../integrations/supabase/types").Json;
7092
7305
  tenant_id?: string | null;
7093
7306
  updated_at?: string;
@@ -7877,6 +8090,24 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7877
8090
  };
7878
8091
  Relationships: [];
7879
8092
  };
8093
+ sidebar_config: {
8094
+ Row: {
8095
+ id: string;
8096
+ module_order: string[];
8097
+ updated_at: string;
8098
+ };
8099
+ Insert: {
8100
+ id?: string;
8101
+ module_order?: string[];
8102
+ updated_at?: string;
8103
+ };
8104
+ Update: {
8105
+ id?: string;
8106
+ module_order?: string[];
8107
+ updated_at?: string;
8108
+ };
8109
+ Relationships: [];
8110
+ };
7880
8111
  stock_import_runs: {
7881
8112
  Row: {
7882
8113
  connection_id: string | null;
@@ -7935,7 +8166,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7935
8166
  reason: string | null;
7936
8167
  reserved_after: number | null;
7937
8168
  reserved_before: number | null;
7938
- trade_item_key: string;
8169
+ trade_item_key: string | null;
7939
8170
  };
7940
8171
  Insert: {
7941
8172
  connection_id?: string | null;
@@ -7952,7 +8183,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7952
8183
  reason?: string | null;
7953
8184
  reserved_after?: number | null;
7954
8185
  reserved_before?: number | null;
7955
- trade_item_key: string;
8186
+ trade_item_key?: string | null;
7956
8187
  };
7957
8188
  Update: {
7958
8189
  connection_id?: string | null;
@@ -7969,7 +8200,7 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
7969
8200
  reason?: string | null;
7970
8201
  reserved_after?: number | null;
7971
8202
  reserved_before?: number | null;
7972
- trade_item_key?: string;
8203
+ trade_item_key?: string | null;
7973
8204
  };
7974
8205
  Relationships: [];
7975
8206
  };
@@ -8312,6 +8543,114 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
8312
8543
  };
8313
8544
  Relationships: [];
8314
8545
  };
8546
+ trade_item_supply_lines: {
8547
+ Row: {
8548
+ available_quantity: number | null;
8549
+ connection_id: string;
8550
+ created_at: string;
8551
+ currency: string | null;
8552
+ endpoint_family: string | null;
8553
+ environment: string | null;
8554
+ id: string;
8555
+ last_error: string | null;
8556
+ last_status: number | null;
8557
+ packing_configuration_id: string | null;
8558
+ period_end: string | null;
8559
+ period_start: string | null;
8560
+ price_per_piece: number | null;
8561
+ sales_unit: string | null;
8562
+ supply_line_id: string | null;
8563
+ supply_type: string;
8564
+ trade_item_id: string;
8565
+ updated_at: string;
8566
+ user_id: string;
8567
+ week: number | null;
8568
+ year: number | null;
8569
+ };
8570
+ Insert: {
8571
+ available_quantity?: number | null;
8572
+ connection_id: string;
8573
+ created_at?: string;
8574
+ currency?: string | null;
8575
+ endpoint_family?: string | null;
8576
+ environment?: string | null;
8577
+ id?: string;
8578
+ last_error?: string | null;
8579
+ last_status?: number | null;
8580
+ packing_configuration_id?: string | null;
8581
+ period_end?: string | null;
8582
+ period_start?: string | null;
8583
+ price_per_piece?: number | null;
8584
+ sales_unit?: string | null;
8585
+ supply_line_id?: string | null;
8586
+ supply_type?: string;
8587
+ trade_item_id: string;
8588
+ updated_at?: string;
8589
+ user_id: string;
8590
+ week?: number | null;
8591
+ year?: number | null;
8592
+ };
8593
+ Update: {
8594
+ available_quantity?: number | null;
8595
+ connection_id?: string;
8596
+ created_at?: string;
8597
+ currency?: string | null;
8598
+ endpoint_family?: string | null;
8599
+ environment?: string | null;
8600
+ id?: string;
8601
+ last_error?: string | null;
8602
+ last_status?: number | null;
8603
+ packing_configuration_id?: string | null;
8604
+ period_end?: string | null;
8605
+ period_start?: string | null;
8606
+ price_per_piece?: number | null;
8607
+ sales_unit?: string | null;
8608
+ supply_line_id?: string | null;
8609
+ supply_type?: string;
8610
+ trade_item_id?: string;
8611
+ updated_at?: string;
8612
+ user_id?: string;
8613
+ week?: number | null;
8614
+ year?: number | null;
8615
+ };
8616
+ Relationships: [];
8617
+ };
8618
+ trade_item_warehouse_preferences: {
8619
+ Row: {
8620
+ connection_id: string;
8621
+ created_at: string;
8622
+ id: string;
8623
+ trade_item_id: string;
8624
+ updated_at: string;
8625
+ warehouse_id: string;
8626
+ warehouse_name: string | null;
8627
+ };
8628
+ Insert: {
8629
+ connection_id: string;
8630
+ created_at?: string;
8631
+ id?: string;
8632
+ trade_item_id: string;
8633
+ updated_at?: string;
8634
+ warehouse_id: string;
8635
+ warehouse_name?: string | null;
8636
+ };
8637
+ Update: {
8638
+ connection_id?: string;
8639
+ created_at?: string;
8640
+ id?: string;
8641
+ trade_item_id?: string;
8642
+ updated_at?: string;
8643
+ warehouse_id?: string;
8644
+ warehouse_name?: string | null;
8645
+ };
8646
+ Relationships: [{
8647
+ foreignKeyName: "trade_item_warehouse_preferences_connection_id_fkey";
8648
+ columns: ["connection_id"];
8649
+ isOneToOne: false;
8650
+ referencedRelation: "floriday_connections";
8651
+ referencedColumns: ["id"];
8652
+ }];
8653
+ };
8315
8654
  twinfield_connections: {
8316
8655
  Row: {
8317
8656
  access_token: string | null;
@@ -8631,6 +8970,10 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
8631
8970
  default_invoice_type: string;
8632
8971
  default_payment_term_days: number;
8633
8972
  default_vat_code: string;
8973
+ invoice_enabled_ao: boolean;
8974
+ invoice_enabled_fo: boolean;
8975
+ invoice_enabled_ho: boolean;
8976
+ invoice_enabled_mo: boolean;
8634
8977
  updated_at: string;
8635
8978
  user_id: string;
8636
8979
  };
@@ -8640,6 +8983,10 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
8640
8983
  default_invoice_type?: string;
8641
8984
  default_payment_term_days?: number;
8642
8985
  default_vat_code?: string;
8986
+ invoice_enabled_ao?: boolean;
8987
+ invoice_enabled_fo?: boolean;
8988
+ invoice_enabled_ho?: boolean;
8989
+ invoice_enabled_mo?: boolean;
8643
8990
  updated_at?: string;
8644
8991
  user_id: string;
8645
8992
  };
@@ -8649,6 +8996,10 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
8649
8996
  default_invoice_type?: string;
8650
8997
  default_payment_term_days?: number;
8651
8998
  default_vat_code?: string;
8999
+ invoice_enabled_ao?: boolean;
9000
+ invoice_enabled_fo?: boolean;
9001
+ invoice_enabled_ho?: boolean;
9002
+ invoice_enabled_mo?: boolean;
8652
9003
  updated_at?: string;
8653
9004
  user_id?: string;
8654
9005
  };
@@ -9943,6 +10294,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
9943
10294
  order_number: string;
9944
10295
  }[];
9945
10296
  };
10297
+ autolink_product_to_floriday: {
10298
+ Args: {
10299
+ p_product_id: string;
10300
+ };
10301
+ Returns: string;
10302
+ };
9946
10303
  backfill_open_order_reservations: {
9947
10304
  Args: never;
9948
10305
  Returns: {
@@ -9981,6 +10338,18 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
9981
10338
  Args: never;
9982
10339
  Returns: number;
9983
10340
  };
10341
+ consume_floriday_rate_limit: {
10342
+ Args: {
10343
+ p_bucket: string;
10344
+ p_capacity: number;
10345
+ p_cost?: number;
10346
+ p_refill_per_sec: number;
10347
+ };
10348
+ Returns: {
10349
+ granted: boolean;
10350
+ wait_ms: number;
10351
+ }[];
10352
+ };
9984
10353
  control_get_todays_carts: {
9985
10354
  Args: never;
9986
10355
  Returns: {
@@ -10061,6 +10430,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10061
10430
  status: string;
10062
10431
  }[];
10063
10432
  };
10433
+ enqueue_cart_replan_if_unlocked: {
10434
+ Args: {
10435
+ p_order_id: string;
10436
+ };
10437
+ Returns: undefined;
10438
+ };
10064
10439
  ensure_trade_item_stock_row: {
10065
10440
  Args: {
10066
10441
  p_key: string;
@@ -10167,6 +10542,13 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10167
10542
  office_code: string;
10168
10543
  }[];
10169
10544
  };
10545
+ get_floricode_record_counts: {
10546
+ Args: never;
10547
+ Returns: {
10548
+ count: number;
10549
+ resource: string;
10550
+ }[];
10551
+ };
10170
10552
  get_floriday_agreements_active: {
10171
10553
  Args: {
10172
10554
  p_on_date?: string;
@@ -10258,6 +10640,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10258
10640
  };
10259
10641
  Returns: import("../integrations/supabase/types").Json;
10260
10642
  };
10643
+ get_offer_delivery_options: {
10644
+ Args: {
10645
+ p_code: string;
10646
+ };
10647
+ Returns: import("../integrations/supabase/types").Json;
10648
+ };
10261
10649
  get_offer_recipient_by_code: {
10262
10650
  Args: {
10263
10651
  p_code: string;
@@ -10322,6 +10710,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10322
10710
  Args: never;
10323
10711
  Returns: boolean;
10324
10712
  };
10713
+ is_superadmin: {
10714
+ Args: {
10715
+ _user_id: string;
10716
+ };
10717
+ Returns: boolean;
10718
+ };
10325
10719
  local_effective_price: {
10326
10720
  Args: {
10327
10721
  _customer_id: string;
@@ -10356,6 +10750,13 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10356
10750
  };
10357
10751
  Returns: string;
10358
10752
  };
10753
+ next_order_number_for_date: {
10754
+ Args: {
10755
+ p_created_at?: string;
10756
+ p_prefix: string;
10757
+ };
10758
+ Returns: string;
10759
+ };
10359
10760
  next_work_order_number: {
10360
10761
  Args: {
10361
10762
  p_parent_work_order_id?: string;
@@ -10363,6 +10764,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10363
10764
  };
10364
10765
  Returns: string;
10365
10766
  };
10767
+ normalize_order_source: {
10768
+ Args: {
10769
+ p_src: string;
10770
+ };
10771
+ Returns: string;
10772
+ };
10366
10773
  normalize_vat: {
10367
10774
  Args: {
10368
10775
  v: string;
@@ -10377,10 +10784,21 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10377
10784
  };
10378
10785
  Returns: boolean;
10379
10786
  };
10787
+ order_number_prefix: {
10788
+ Args: {
10789
+ p_custom_fields?: import("../integrations/supabase/types").Json;
10790
+ p_order_source: string;
10791
+ };
10792
+ Returns: string;
10793
+ };
10380
10794
  pickstation_get_orders_raw: {
10381
10795
  Args: never;
10382
10796
  Returns: import("../integrations/supabase/types").Json;
10383
10797
  };
10798
+ pickstation_get_planning_context: {
10799
+ Args: never;
10800
+ Returns: import("../integrations/supabase/types").Json;
10801
+ };
10384
10802
  pickstation_get_settings: {
10385
10803
  Args: never;
10386
10804
  Returns: import("../integrations/supabase/types").Json;
@@ -10411,6 +10829,28 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10411
10829
  };
10412
10830
  Returns: undefined;
10413
10831
  };
10832
+ recompute_order_status: {
10833
+ Args: {
10834
+ p_order_id: string;
10835
+ };
10836
+ Returns: undefined;
10837
+ };
10838
+ recompute_reserved_for_order: {
10839
+ Args: {
10840
+ p_order_id: string;
10841
+ };
10842
+ Returns: undefined;
10843
+ };
10844
+ recompute_reserved_stock: {
10845
+ Args: {
10846
+ p_trade_item_key: string;
10847
+ };
10848
+ Returns: undefined;
10849
+ };
10850
+ refresh_external_customers_grouped: {
10851
+ Args: never;
10852
+ Returns: undefined;
10853
+ };
10414
10854
  refresh_floricode_derived_code_lists: {
10415
10855
  Args: never;
10416
10856
  Returns: {
@@ -10425,6 +10865,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10425
10865
  };
10426
10866
  Returns: number;
10427
10867
  };
10868
+ refresh_floricode_derived_for_products: {
10869
+ Args: {
10870
+ _product_ids: string[];
10871
+ };
10872
+ Returns: number;
10873
+ };
10428
10874
  reset_floriday_sync_cursor: {
10429
10875
  Args: {
10430
10876
  p_connection_id: string;
@@ -10432,6 +10878,12 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10432
10878
  };
10433
10879
  Returns: undefined;
10434
10880
  };
10881
+ resolve_product_id_for_item: {
10882
+ Args: {
10883
+ p_product_name: string;
10884
+ };
10885
+ Returns: string;
10886
+ };
10435
10887
  schedule_floriday_additional_services_sync: {
10436
10888
  Args: {
10437
10889
  p_apikey: string;
@@ -10709,6 +11161,24 @@ export declare const acknowledgeSalesOrder: import("@tanstack/start-client-core"
10709
11161
  };
10710
11162
  Returns: string[];
10711
11163
  };
11164
+ sync_cached_packing_from_product: {
11165
+ Args: {
11166
+ p_product_id: string;
11167
+ };
11168
+ Returns: undefined;
11169
+ };
11170
+ sync_order_cart_item_packing_from_product: {
11171
+ Args: {
11172
+ p_product_id: string;
11173
+ };
11174
+ Returns: undefined;
11175
+ };
11176
+ sync_product_packing_from_floriday_cache: {
11177
+ Args: {
11178
+ p_floriday_id: string;
11179
+ };
11180
+ Returns: undefined;
11181
+ };
10712
11182
  twinfield_decrypt: {
10713
11183
  Args: {
10714
11184
  cipher: string;
@@ -10747,7 +11217,10 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
10747
11217
  Tables: {
10748
11218
  afhandeling_settings: {
10749
11219
  Row: {
11220
+ auto_print_delivery_note: boolean;
11221
+ auto_process_paused: boolean;
10750
11222
  created_at: string;
11223
+ extra_pick_days_with_stickers: number;
10751
11224
  id: string;
10752
11225
  max_workdays_earlier_pick: number;
10753
11226
  pick_days_before_transport: number;
@@ -10761,7 +11234,10 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
10761
11234
  user_id: string;
10762
11235
  };
10763
11236
  Insert: {
11237
+ auto_print_delivery_note?: boolean;
11238
+ auto_process_paused?: boolean;
10764
11239
  created_at?: string;
11240
+ extra_pick_days_with_stickers?: number;
10765
11241
  id?: string;
10766
11242
  max_workdays_earlier_pick?: number;
10767
11243
  pick_days_before_transport?: number;
@@ -10775,7 +11251,10 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
10775
11251
  user_id: string;
10776
11252
  };
10777
11253
  Update: {
11254
+ auto_print_delivery_note?: boolean;
11255
+ auto_process_paused?: boolean;
10778
11256
  created_at?: string;
11257
+ extra_pick_days_with_stickers?: number;
10779
11258
  id?: string;
10780
11259
  max_workdays_earlier_pick?: number;
10781
11260
  pick_days_before_transport?: number;
@@ -11567,6 +12046,36 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
11567
12046
  };
11568
12047
  Relationships: [];
11569
12048
  };
12049
+ cart_replan_queue: {
12050
+ Row: {
12051
+ attempts: number;
12052
+ last_error: string | null;
12053
+ order_id: string;
12054
+ processed_at: string | null;
12055
+ requested_at: string;
12056
+ };
12057
+ Insert: {
12058
+ attempts?: number;
12059
+ last_error?: string | null;
12060
+ order_id: string;
12061
+ processed_at?: string | null;
12062
+ requested_at?: string;
12063
+ };
12064
+ Update: {
12065
+ attempts?: number;
12066
+ last_error?: string | null;
12067
+ order_id?: string;
12068
+ processed_at?: string | null;
12069
+ requested_at?: string;
12070
+ };
12071
+ Relationships: [{
12072
+ foreignKeyName: "cart_replan_queue_order_id_fkey";
12073
+ columns: ["order_id"];
12074
+ isOneToOne: true;
12075
+ referencedRelation: "orders";
12076
+ referencedColumns: ["id"];
12077
+ }];
12078
+ };
11570
12079
  collections: {
11571
12080
  Row: {
11572
12081
  created_at: string;
@@ -13692,34 +14201,52 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
13692
14201
  Row: {
13693
14202
  catalog_key: string | null;
13694
14203
  catalog_url: string;
14204
+ client_id: string | null;
14205
+ client_secret_ciphertext: string | null;
14206
+ client_secret_last4: string | null;
13695
14207
  created_at: string;
13696
14208
  id: number;
13697
14209
  last_meta: import("../integrations/supabase/types").Json | null;
13698
14210
  last_test_at: string | null;
13699
14211
  last_test_error: string | null;
13700
14212
  last_test_ok: boolean | null;
14213
+ last_token_test_at: string | null;
14214
+ last_token_test_error: string | null;
14215
+ last_token_test_ok: boolean | null;
13701
14216
  updated_at: string;
13702
14217
  };
13703
14218
  Insert: {
13704
14219
  catalog_key?: string | null;
13705
14220
  catalog_url?: string;
14221
+ client_id?: string | null;
14222
+ client_secret_ciphertext?: string | null;
14223
+ client_secret_last4?: string | null;
13706
14224
  created_at?: string;
13707
14225
  id?: number;
13708
14226
  last_meta?: import("../integrations/supabase/types").Json | null;
13709
14227
  last_test_at?: string | null;
13710
14228
  last_test_error?: string | null;
13711
14229
  last_test_ok?: boolean | null;
14230
+ last_token_test_at?: string | null;
14231
+ last_token_test_error?: string | null;
14232
+ last_token_test_ok?: boolean | null;
13712
14233
  updated_at?: string;
13713
14234
  };
13714
14235
  Update: {
13715
14236
  catalog_key?: string | null;
13716
14237
  catalog_url?: string;
14238
+ client_id?: string | null;
14239
+ client_secret_ciphertext?: string | null;
14240
+ client_secret_last4?: string | null;
13717
14241
  created_at?: string;
13718
14242
  id?: number;
13719
14243
  last_meta?: import("../integrations/supabase/types").Json | null;
13720
14244
  last_test_at?: string | null;
13721
14245
  last_test_error?: string | null;
13722
14246
  last_test_ok?: boolean | null;
14247
+ last_token_test_at?: string | null;
14248
+ last_token_test_error?: string | null;
14249
+ last_token_test_ok?: boolean | null;
13723
14250
  updated_at?: string;
13724
14251
  };
13725
14252
  Relationships: [];
@@ -13952,6 +14479,54 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
13952
14479
  referencedColumns: ["id"];
13953
14480
  }];
13954
14481
  };
14482
+ floriday_auto_fulfillment_log: {
14483
+ Row: {
14484
+ attempts: number;
14485
+ connection_id: string;
14486
+ created_at: string;
14487
+ error: string | null;
14488
+ fulfillment_order_id: string | null;
14489
+ id: string;
14490
+ last_attempt_at: string | null;
14491
+ reason: string | null;
14492
+ sales_order_id: string;
14493
+ status: string;
14494
+ updated_at: string;
14495
+ };
14496
+ Insert: {
14497
+ attempts?: number;
14498
+ connection_id: string;
14499
+ created_at?: string;
14500
+ error?: string | null;
14501
+ fulfillment_order_id?: string | null;
14502
+ id?: string;
14503
+ last_attempt_at?: string | null;
14504
+ reason?: string | null;
14505
+ sales_order_id: string;
14506
+ status?: string;
14507
+ updated_at?: string;
14508
+ };
14509
+ Update: {
14510
+ attempts?: number;
14511
+ connection_id?: string;
14512
+ created_at?: string;
14513
+ error?: string | null;
14514
+ fulfillment_order_id?: string | null;
14515
+ id?: string;
14516
+ last_attempt_at?: string | null;
14517
+ reason?: string | null;
14518
+ sales_order_id?: string;
14519
+ status?: string;
14520
+ updated_at?: string;
14521
+ };
14522
+ Relationships: [{
14523
+ foreignKeyName: "floriday_auto_fulfillment_log_connection_id_fkey";
14524
+ columns: ["connection_id"];
14525
+ isOneToOne: false;
14526
+ referencedRelation: "floriday_connections";
14527
+ referencedColumns: ["id"];
14528
+ }];
14529
+ };
13955
14530
  floriday_base_items_cache: {
13956
14531
  Row: {
13957
14532
  connection_id: string;
@@ -15056,6 +15631,24 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
15056
15631
  referencedColumns: ["id"];
15057
15632
  }];
15058
15633
  };
15634
+ floriday_rate_limit_state: {
15635
+ Row: {
15636
+ bucket: string;
15637
+ last_refill_at: string;
15638
+ tokens: number;
15639
+ };
15640
+ Insert: {
15641
+ bucket: string;
15642
+ last_refill_at?: string;
15643
+ tokens: number;
15644
+ };
15645
+ Update: {
15646
+ bucket?: string;
15647
+ last_refill_at?: string;
15648
+ tokens?: number;
15649
+ };
15650
+ Relationships: [];
15651
+ };
15059
15652
  floriday_resource_schemas: {
15060
15653
  Row: {
15061
15654
  enums: import("../integrations/supabase/types").Json;
@@ -15479,6 +16072,60 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
15479
16072
  referencedColumns: ["id"];
15480
16073
  }];
15481
16074
  };
16075
+ flow_role_assignments: {
16076
+ Row: {
16077
+ created_at: string;
16078
+ id: string;
16079
+ role_id: string;
16080
+ user_id: string;
16081
+ };
16082
+ Insert: {
16083
+ created_at?: string;
16084
+ id?: string;
16085
+ role_id: string;
16086
+ user_id: string;
16087
+ };
16088
+ Update: {
16089
+ created_at?: string;
16090
+ id?: string;
16091
+ role_id?: string;
16092
+ user_id?: string;
16093
+ };
16094
+ Relationships: [{
16095
+ foreignKeyName: "flow_role_assignments_role_id_fkey";
16096
+ columns: ["role_id"];
16097
+ isOneToOne: false;
16098
+ referencedRelation: "flow_roles";
16099
+ referencedColumns: ["id"];
16100
+ }];
16101
+ };
16102
+ flow_roles: {
16103
+ Row: {
16104
+ created_at: string;
16105
+ description: string | null;
16106
+ id: string;
16107
+ module_access: string[];
16108
+ name: string;
16109
+ updated_at: string;
16110
+ };
16111
+ Insert: {
16112
+ created_at?: string;
16113
+ description?: string | null;
16114
+ id?: string;
16115
+ module_access?: string[];
16116
+ name: string;
16117
+ updated_at?: string;
16118
+ };
16119
+ Update: {
16120
+ created_at?: string;
16121
+ description?: string | null;
16122
+ id?: string;
16123
+ module_access?: string[];
16124
+ name?: string;
16125
+ updated_at?: string;
16126
+ };
16127
+ Relationships: [];
16128
+ };
15482
16129
  imap_accounts: {
15483
16130
  Row: {
15484
16131
  created_at: string;
@@ -16110,6 +16757,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
16110
16757
  matched_customer_id: string | null;
16111
16758
  message_id: string;
16112
16759
  notes: string | null;
16760
+ order_number: string | null;
16113
16761
  parsed_payload: import("../integrations/supabase/types").Json | null;
16114
16762
  reviewed_at: string | null;
16115
16763
  reviewed_by: string | null;
@@ -16125,6 +16773,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
16125
16773
  matched_customer_id?: string | null;
16126
16774
  message_id: string;
16127
16775
  notes?: string | null;
16776
+ order_number?: string | null;
16128
16777
  parsed_payload?: import("../integrations/supabase/types").Json | null;
16129
16778
  reviewed_at?: string | null;
16130
16779
  reviewed_by?: string | null;
@@ -16140,6 +16789,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
16140
16789
  matched_customer_id?: string | null;
16141
16790
  message_id?: string;
16142
16791
  notes?: string | null;
16792
+ order_number?: string | null;
16143
16793
  parsed_payload?: import("../integrations/supabase/types").Json | null;
16144
16794
  reviewed_at?: string | null;
16145
16795
  reviewed_by?: string | null;
@@ -16996,6 +17646,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
16996
17646
  id: string;
16997
17647
  items: import("../integrations/supabase/types").Json;
16998
17648
  notes: string | null;
17649
+ order_number: string | null;
16999
17650
  recipient_id: string;
17000
17651
  total_amount: number;
17001
17652
  };
@@ -17009,6 +17660,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17009
17660
  id?: string;
17010
17661
  items?: import("../integrations/supabase/types").Json;
17011
17662
  notes?: string | null;
17663
+ order_number?: string | null;
17012
17664
  recipient_id: string;
17013
17665
  total_amount?: number;
17014
17666
  };
@@ -17022,6 +17674,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17022
17674
  id?: string;
17023
17675
  items?: import("../integrations/supabase/types").Json;
17024
17676
  notes?: string | null;
17677
+ order_number?: string | null;
17025
17678
  recipient_id?: string;
17026
17679
  total_amount?: number;
17027
17680
  };
@@ -17181,6 +17834,9 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17181
17834
  crates_per_layer: number;
17182
17835
  created_at: string;
17183
17836
  id: string;
17837
+ layer_fraction: number;
17838
+ layer_share_pct: number;
17839
+ layers_per_cart: number;
17184
17840
  order_item_id: string | null;
17185
17841
  plants_per_crate: number;
17186
17842
  product_id: string | null;
@@ -17192,6 +17848,9 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17192
17848
  crates_per_layer?: number;
17193
17849
  created_at?: string;
17194
17850
  id?: string;
17851
+ layer_fraction?: number;
17852
+ layer_share_pct?: number;
17853
+ layers_per_cart?: number;
17195
17854
  order_item_id?: string | null;
17196
17855
  plants_per_crate?: number;
17197
17856
  product_id?: string | null;
@@ -17203,6 +17862,9 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17203
17862
  crates_per_layer?: number;
17204
17863
  created_at?: string;
17205
17864
  id?: string;
17865
+ layer_fraction?: number;
17866
+ layer_share_pct?: number;
17867
+ layers_per_cart?: number;
17206
17868
  order_item_id?: string | null;
17207
17869
  plants_per_crate?: number;
17208
17870
  product_id?: string | null;
@@ -17230,33 +17892,45 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17230
17892
  };
17231
17893
  order_carts: {
17232
17894
  Row: {
17895
+ algorithm_version: number;
17233
17896
  cart_number: number;
17234
17897
  created_at: string;
17235
17898
  id: string;
17236
17899
  is_auto: boolean;
17237
17900
  is_complete: boolean;
17238
17901
  notes: string | null;
17902
+ occupancy_pct: number;
17239
17903
  order_id: string;
17904
+ source: string;
17905
+ total_layers_used: number;
17240
17906
  updated_at: string;
17241
17907
  };
17242
17908
  Insert: {
17909
+ algorithm_version?: number;
17243
17910
  cart_number: number;
17244
17911
  created_at?: string;
17245
17912
  id?: string;
17246
17913
  is_auto?: boolean;
17247
17914
  is_complete?: boolean;
17248
17915
  notes?: string | null;
17916
+ occupancy_pct?: number;
17249
17917
  order_id: string;
17918
+ source?: string;
17919
+ total_layers_used?: number;
17250
17920
  updated_at?: string;
17251
17921
  };
17252
17922
  Update: {
17923
+ algorithm_version?: number;
17253
17924
  cart_number?: number;
17254
17925
  created_at?: string;
17255
17926
  id?: string;
17256
17927
  is_auto?: boolean;
17257
17928
  is_complete?: boolean;
17258
17929
  notes?: string | null;
17930
+ occupancy_pct?: number;
17259
17931
  order_id?: string;
17932
+ source?: string;
17933
+ total_layers_used?: number;
17260
17934
  updated_at?: string;
17261
17935
  };
17262
17936
  Relationships: [{
@@ -17409,6 +18083,8 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17409
18083
  order_date: string;
17410
18084
  order_number: string;
17411
18085
  order_source: string;
18086
+ plan_locked_at: string | null;
18087
+ plan_locked_ref: string | null;
17412
18088
  status: string;
17413
18089
  total: string;
17414
18090
  updated_at: string;
@@ -17425,6 +18101,8 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17425
18101
  order_date?: string;
17426
18102
  order_number: string;
17427
18103
  order_source?: string;
18104
+ plan_locked_at?: string | null;
18105
+ plan_locked_ref?: string | null;
17428
18106
  status?: string;
17429
18107
  total?: string;
17430
18108
  updated_at?: string;
@@ -17441,6 +18119,8 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17441
18119
  order_date?: string;
17442
18120
  order_number?: string;
17443
18121
  order_source?: string;
18122
+ plan_locked_at?: string | null;
18123
+ plan_locked_ref?: string | null;
17444
18124
  status?: string;
17445
18125
  total?: string;
17446
18126
  updated_at?: string;
@@ -17813,6 +18493,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17813
18493
  display_name: string | null;
17814
18494
  email: string | null;
17815
18495
  id: string;
18496
+ is_superadmin: boolean;
17816
18497
  notification_preferences: import("../integrations/supabase/types").Json;
17817
18498
  tenant_id: string | null;
17818
18499
  updated_at: string;
@@ -17822,6 +18503,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17822
18503
  display_name?: string | null;
17823
18504
  email?: string | null;
17824
18505
  id: string;
18506
+ is_superadmin?: boolean;
17825
18507
  notification_preferences?: import("../integrations/supabase/types").Json;
17826
18508
  tenant_id?: string | null;
17827
18509
  updated_at?: string;
@@ -17831,6 +18513,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
17831
18513
  display_name?: string | null;
17832
18514
  email?: string | null;
17833
18515
  id?: string;
18516
+ is_superadmin?: boolean;
17834
18517
  notification_preferences?: import("../integrations/supabase/types").Json;
17835
18518
  tenant_id?: string | null;
17836
18519
  updated_at?: string;
@@ -18620,6 +19303,24 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
18620
19303
  };
18621
19304
  Relationships: [];
18622
19305
  };
19306
+ sidebar_config: {
19307
+ Row: {
19308
+ id: string;
19309
+ module_order: string[];
19310
+ updated_at: string;
19311
+ };
19312
+ Insert: {
19313
+ id?: string;
19314
+ module_order?: string[];
19315
+ updated_at?: string;
19316
+ };
19317
+ Update: {
19318
+ id?: string;
19319
+ module_order?: string[];
19320
+ updated_at?: string;
19321
+ };
19322
+ Relationships: [];
19323
+ };
18623
19324
  stock_import_runs: {
18624
19325
  Row: {
18625
19326
  connection_id: string | null;
@@ -18678,7 +19379,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
18678
19379
  reason: string | null;
18679
19380
  reserved_after: number | null;
18680
19381
  reserved_before: number | null;
18681
- trade_item_key: string;
19382
+ trade_item_key: string | null;
18682
19383
  };
18683
19384
  Insert: {
18684
19385
  connection_id?: string | null;
@@ -18695,7 +19396,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
18695
19396
  reason?: string | null;
18696
19397
  reserved_after?: number | null;
18697
19398
  reserved_before?: number | null;
18698
- trade_item_key: string;
19399
+ trade_item_key?: string | null;
18699
19400
  };
18700
19401
  Update: {
18701
19402
  connection_id?: string | null;
@@ -18712,7 +19413,7 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
18712
19413
  reason?: string | null;
18713
19414
  reserved_after?: number | null;
18714
19415
  reserved_before?: number | null;
18715
- trade_item_key?: string;
19416
+ trade_item_key?: string | null;
18716
19417
  };
18717
19418
  Relationships: [];
18718
19419
  };
@@ -19055,6 +19756,114 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
19055
19756
  };
19056
19757
  Relationships: [];
19057
19758
  };
19759
+ trade_item_supply_lines: {
19760
+ Row: {
19761
+ available_quantity: number | null;
19762
+ connection_id: string;
19763
+ created_at: string;
19764
+ currency: string | null;
19765
+ endpoint_family: string | null;
19766
+ environment: string | null;
19767
+ id: string;
19768
+ last_error: string | null;
19769
+ last_status: number | null;
19770
+ packing_configuration_id: string | null;
19771
+ period_end: string | null;
19772
+ period_start: string | null;
19773
+ price_per_piece: number | null;
19774
+ sales_unit: string | null;
19775
+ supply_line_id: string | null;
19776
+ supply_type: string;
19777
+ trade_item_id: string;
19778
+ updated_at: string;
19779
+ user_id: string;
19780
+ week: number | null;
19781
+ year: number | null;
19782
+ };
19783
+ Insert: {
19784
+ available_quantity?: number | null;
19785
+ connection_id: string;
19786
+ created_at?: string;
19787
+ currency?: string | null;
19788
+ endpoint_family?: string | null;
19789
+ environment?: string | null;
19790
+ id?: string;
19791
+ last_error?: string | null;
19792
+ last_status?: number | null;
19793
+ packing_configuration_id?: string | null;
19794
+ period_end?: string | null;
19795
+ period_start?: string | null;
19796
+ price_per_piece?: number | null;
19797
+ sales_unit?: string | null;
19798
+ supply_line_id?: string | null;
19799
+ supply_type?: string;
19800
+ trade_item_id: string;
19801
+ updated_at?: string;
19802
+ user_id: string;
19803
+ week?: number | null;
19804
+ year?: number | null;
19805
+ };
19806
+ Update: {
19807
+ available_quantity?: number | null;
19808
+ connection_id?: string;
19809
+ created_at?: string;
19810
+ currency?: string | null;
19811
+ endpoint_family?: string | null;
19812
+ environment?: string | null;
19813
+ id?: string;
19814
+ last_error?: string | null;
19815
+ last_status?: number | null;
19816
+ packing_configuration_id?: string | null;
19817
+ period_end?: string | null;
19818
+ period_start?: string | null;
19819
+ price_per_piece?: number | null;
19820
+ sales_unit?: string | null;
19821
+ supply_line_id?: string | null;
19822
+ supply_type?: string;
19823
+ trade_item_id?: string;
19824
+ updated_at?: string;
19825
+ user_id?: string;
19826
+ week?: number | null;
19827
+ year?: number | null;
19828
+ };
19829
+ Relationships: [];
19830
+ };
19831
+ trade_item_warehouse_preferences: {
19832
+ Row: {
19833
+ connection_id: string;
19834
+ created_at: string;
19835
+ id: string;
19836
+ trade_item_id: string;
19837
+ updated_at: string;
19838
+ warehouse_id: string;
19839
+ warehouse_name: string | null;
19840
+ };
19841
+ Insert: {
19842
+ connection_id: string;
19843
+ created_at?: string;
19844
+ id?: string;
19845
+ trade_item_id: string;
19846
+ updated_at?: string;
19847
+ warehouse_id: string;
19848
+ warehouse_name?: string | null;
19849
+ };
19850
+ Update: {
19851
+ connection_id?: string;
19852
+ created_at?: string;
19853
+ id?: string;
19854
+ trade_item_id?: string;
19855
+ updated_at?: string;
19856
+ warehouse_id?: string;
19857
+ warehouse_name?: string | null;
19858
+ };
19859
+ Relationships: [{
19860
+ foreignKeyName: "trade_item_warehouse_preferences_connection_id_fkey";
19861
+ columns: ["connection_id"];
19862
+ isOneToOne: false;
19863
+ referencedRelation: "floriday_connections";
19864
+ referencedColumns: ["id"];
19865
+ }];
19866
+ };
19058
19867
  twinfield_connections: {
19059
19868
  Row: {
19060
19869
  access_token: string | null;
@@ -19374,6 +20183,10 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
19374
20183
  default_invoice_type: string;
19375
20184
  default_payment_term_days: number;
19376
20185
  default_vat_code: string;
20186
+ invoice_enabled_ao: boolean;
20187
+ invoice_enabled_fo: boolean;
20188
+ invoice_enabled_ho: boolean;
20189
+ invoice_enabled_mo: boolean;
19377
20190
  updated_at: string;
19378
20191
  user_id: string;
19379
20192
  };
@@ -19383,6 +20196,10 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
19383
20196
  default_invoice_type?: string;
19384
20197
  default_payment_term_days?: number;
19385
20198
  default_vat_code?: string;
20199
+ invoice_enabled_ao?: boolean;
20200
+ invoice_enabled_fo?: boolean;
20201
+ invoice_enabled_ho?: boolean;
20202
+ invoice_enabled_mo?: boolean;
19386
20203
  updated_at?: string;
19387
20204
  user_id: string;
19388
20205
  };
@@ -19392,6 +20209,10 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
19392
20209
  default_invoice_type?: string;
19393
20210
  default_payment_term_days?: number;
19394
20211
  default_vat_code?: string;
20212
+ invoice_enabled_ao?: boolean;
20213
+ invoice_enabled_fo?: boolean;
20214
+ invoice_enabled_ho?: boolean;
20215
+ invoice_enabled_mo?: boolean;
19395
20216
  updated_at?: string;
19396
20217
  user_id?: string;
19397
20218
  };
@@ -20686,6 +21507,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
20686
21507
  order_number: string;
20687
21508
  }[];
20688
21509
  };
21510
+ autolink_product_to_floriday: {
21511
+ Args: {
21512
+ p_product_id: string;
21513
+ };
21514
+ Returns: string;
21515
+ };
20689
21516
  backfill_open_order_reservations: {
20690
21517
  Args: never;
20691
21518
  Returns: {
@@ -20724,6 +21551,18 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
20724
21551
  Args: never;
20725
21552
  Returns: number;
20726
21553
  };
21554
+ consume_floriday_rate_limit: {
21555
+ Args: {
21556
+ p_bucket: string;
21557
+ p_capacity: number;
21558
+ p_cost?: number;
21559
+ p_refill_per_sec: number;
21560
+ };
21561
+ Returns: {
21562
+ granted: boolean;
21563
+ wait_ms: number;
21564
+ }[];
21565
+ };
20727
21566
  control_get_todays_carts: {
20728
21567
  Args: never;
20729
21568
  Returns: {
@@ -20804,6 +21643,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
20804
21643
  status: string;
20805
21644
  }[];
20806
21645
  };
21646
+ enqueue_cart_replan_if_unlocked: {
21647
+ Args: {
21648
+ p_order_id: string;
21649
+ };
21650
+ Returns: undefined;
21651
+ };
20807
21652
  ensure_trade_item_stock_row: {
20808
21653
  Args: {
20809
21654
  p_key: string;
@@ -20910,6 +21755,13 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
20910
21755
  office_code: string;
20911
21756
  }[];
20912
21757
  };
21758
+ get_floricode_record_counts: {
21759
+ Args: never;
21760
+ Returns: {
21761
+ count: number;
21762
+ resource: string;
21763
+ }[];
21764
+ };
20913
21765
  get_floriday_agreements_active: {
20914
21766
  Args: {
20915
21767
  p_on_date?: string;
@@ -21001,6 +21853,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21001
21853
  };
21002
21854
  Returns: import("../integrations/supabase/types").Json;
21003
21855
  };
21856
+ get_offer_delivery_options: {
21857
+ Args: {
21858
+ p_code: string;
21859
+ };
21860
+ Returns: import("../integrations/supabase/types").Json;
21861
+ };
21004
21862
  get_offer_recipient_by_code: {
21005
21863
  Args: {
21006
21864
  p_code: string;
@@ -21065,6 +21923,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21065
21923
  Args: never;
21066
21924
  Returns: boolean;
21067
21925
  };
21926
+ is_superadmin: {
21927
+ Args: {
21928
+ _user_id: string;
21929
+ };
21930
+ Returns: boolean;
21931
+ };
21068
21932
  local_effective_price: {
21069
21933
  Args: {
21070
21934
  _customer_id: string;
@@ -21099,6 +21963,13 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21099
21963
  };
21100
21964
  Returns: string;
21101
21965
  };
21966
+ next_order_number_for_date: {
21967
+ Args: {
21968
+ p_created_at?: string;
21969
+ p_prefix: string;
21970
+ };
21971
+ Returns: string;
21972
+ };
21102
21973
  next_work_order_number: {
21103
21974
  Args: {
21104
21975
  p_parent_work_order_id?: string;
@@ -21106,6 +21977,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21106
21977
  };
21107
21978
  Returns: string;
21108
21979
  };
21980
+ normalize_order_source: {
21981
+ Args: {
21982
+ p_src: string;
21983
+ };
21984
+ Returns: string;
21985
+ };
21109
21986
  normalize_vat: {
21110
21987
  Args: {
21111
21988
  v: string;
@@ -21120,10 +21997,21 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21120
21997
  };
21121
21998
  Returns: boolean;
21122
21999
  };
22000
+ order_number_prefix: {
22001
+ Args: {
22002
+ p_custom_fields?: import("../integrations/supabase/types").Json;
22003
+ p_order_source: string;
22004
+ };
22005
+ Returns: string;
22006
+ };
21123
22007
  pickstation_get_orders_raw: {
21124
22008
  Args: never;
21125
22009
  Returns: import("../integrations/supabase/types").Json;
21126
22010
  };
22011
+ pickstation_get_planning_context: {
22012
+ Args: never;
22013
+ Returns: import("../integrations/supabase/types").Json;
22014
+ };
21127
22015
  pickstation_get_settings: {
21128
22016
  Args: never;
21129
22017
  Returns: import("../integrations/supabase/types").Json;
@@ -21154,6 +22042,28 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21154
22042
  };
21155
22043
  Returns: undefined;
21156
22044
  };
22045
+ recompute_order_status: {
22046
+ Args: {
22047
+ p_order_id: string;
22048
+ };
22049
+ Returns: undefined;
22050
+ };
22051
+ recompute_reserved_for_order: {
22052
+ Args: {
22053
+ p_order_id: string;
22054
+ };
22055
+ Returns: undefined;
22056
+ };
22057
+ recompute_reserved_stock: {
22058
+ Args: {
22059
+ p_trade_item_key: string;
22060
+ };
22061
+ Returns: undefined;
22062
+ };
22063
+ refresh_external_customers_grouped: {
22064
+ Args: never;
22065
+ Returns: undefined;
22066
+ };
21157
22067
  refresh_floricode_derived_code_lists: {
21158
22068
  Args: never;
21159
22069
  Returns: {
@@ -21168,6 +22078,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21168
22078
  };
21169
22079
  Returns: number;
21170
22080
  };
22081
+ refresh_floricode_derived_for_products: {
22082
+ Args: {
22083
+ _product_ids: string[];
22084
+ };
22085
+ Returns: number;
22086
+ };
21171
22087
  reset_floriday_sync_cursor: {
21172
22088
  Args: {
21173
22089
  p_connection_id: string;
@@ -21175,6 +22091,12 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21175
22091
  };
21176
22092
  Returns: undefined;
21177
22093
  };
22094
+ resolve_product_id_for_item: {
22095
+ Args: {
22096
+ p_product_name: string;
22097
+ };
22098
+ Returns: string;
22099
+ };
21178
22100
  schedule_floriday_additional_services_sync: {
21179
22101
  Args: {
21180
22102
  p_apikey: string;
@@ -21452,6 +22374,24 @@ export declare const rejectSalesOrder: import("@tanstack/start-client-core").Opt
21452
22374
  };
21453
22375
  Returns: string[];
21454
22376
  };
22377
+ sync_cached_packing_from_product: {
22378
+ Args: {
22379
+ p_product_id: string;
22380
+ };
22381
+ Returns: undefined;
22382
+ };
22383
+ sync_order_cart_item_packing_from_product: {
22384
+ Args: {
22385
+ p_product_id: string;
22386
+ };
22387
+ Returns: undefined;
22388
+ };
22389
+ sync_product_packing_from_floriday_cache: {
22390
+ Args: {
22391
+ p_floriday_id: string;
22392
+ };
22393
+ Returns: undefined;
22394
+ };
21455
22395
  twinfield_decrypt: {
21456
22396
  Args: {
21457
22397
  cipher: string;
@@ -21487,7 +22427,10 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
21487
22427
  Tables: {
21488
22428
  afhandeling_settings: {
21489
22429
  Row: {
22430
+ auto_print_delivery_note: boolean;
22431
+ auto_process_paused: boolean;
21490
22432
  created_at: string;
22433
+ extra_pick_days_with_stickers: number;
21491
22434
  id: string;
21492
22435
  max_workdays_earlier_pick: number;
21493
22436
  pick_days_before_transport: number;
@@ -21501,7 +22444,10 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
21501
22444
  user_id: string;
21502
22445
  };
21503
22446
  Insert: {
22447
+ auto_print_delivery_note?: boolean;
22448
+ auto_process_paused?: boolean;
21504
22449
  created_at?: string;
22450
+ extra_pick_days_with_stickers?: number;
21505
22451
  id?: string;
21506
22452
  max_workdays_earlier_pick?: number;
21507
22453
  pick_days_before_transport?: number;
@@ -21515,7 +22461,10 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
21515
22461
  user_id: string;
21516
22462
  };
21517
22463
  Update: {
22464
+ auto_print_delivery_note?: boolean;
22465
+ auto_process_paused?: boolean;
21518
22466
  created_at?: string;
22467
+ extra_pick_days_with_stickers?: number;
21519
22468
  id?: string;
21520
22469
  max_workdays_earlier_pick?: number;
21521
22470
  pick_days_before_transport?: number;
@@ -22307,6 +23256,36 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
22307
23256
  };
22308
23257
  Relationships: [];
22309
23258
  };
23259
+ cart_replan_queue: {
23260
+ Row: {
23261
+ attempts: number;
23262
+ last_error: string | null;
23263
+ order_id: string;
23264
+ processed_at: string | null;
23265
+ requested_at: string;
23266
+ };
23267
+ Insert: {
23268
+ attempts?: number;
23269
+ last_error?: string | null;
23270
+ order_id: string;
23271
+ processed_at?: string | null;
23272
+ requested_at?: string;
23273
+ };
23274
+ Update: {
23275
+ attempts?: number;
23276
+ last_error?: string | null;
23277
+ order_id?: string;
23278
+ processed_at?: string | null;
23279
+ requested_at?: string;
23280
+ };
23281
+ Relationships: [{
23282
+ foreignKeyName: "cart_replan_queue_order_id_fkey";
23283
+ columns: ["order_id"];
23284
+ isOneToOne: true;
23285
+ referencedRelation: "orders";
23286
+ referencedColumns: ["id"];
23287
+ }];
23288
+ };
22310
23289
  collections: {
22311
23290
  Row: {
22312
23291
  created_at: string;
@@ -24432,34 +25411,52 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
24432
25411
  Row: {
24433
25412
  catalog_key: string | null;
24434
25413
  catalog_url: string;
25414
+ client_id: string | null;
25415
+ client_secret_ciphertext: string | null;
25416
+ client_secret_last4: string | null;
24435
25417
  created_at: string;
24436
25418
  id: number;
24437
25419
  last_meta: import("../integrations/supabase/types").Json | null;
24438
25420
  last_test_at: string | null;
24439
25421
  last_test_error: string | null;
24440
25422
  last_test_ok: boolean | null;
25423
+ last_token_test_at: string | null;
25424
+ last_token_test_error: string | null;
25425
+ last_token_test_ok: boolean | null;
24441
25426
  updated_at: string;
24442
25427
  };
24443
25428
  Insert: {
24444
25429
  catalog_key?: string | null;
24445
25430
  catalog_url?: string;
25431
+ client_id?: string | null;
25432
+ client_secret_ciphertext?: string | null;
25433
+ client_secret_last4?: string | null;
24446
25434
  created_at?: string;
24447
25435
  id?: number;
24448
25436
  last_meta?: import("../integrations/supabase/types").Json | null;
24449
25437
  last_test_at?: string | null;
24450
25438
  last_test_error?: string | null;
24451
25439
  last_test_ok?: boolean | null;
25440
+ last_token_test_at?: string | null;
25441
+ last_token_test_error?: string | null;
25442
+ last_token_test_ok?: boolean | null;
24452
25443
  updated_at?: string;
24453
25444
  };
24454
25445
  Update: {
24455
25446
  catalog_key?: string | null;
24456
25447
  catalog_url?: string;
25448
+ client_id?: string | null;
25449
+ client_secret_ciphertext?: string | null;
25450
+ client_secret_last4?: string | null;
24457
25451
  created_at?: string;
24458
25452
  id?: number;
24459
25453
  last_meta?: import("../integrations/supabase/types").Json | null;
24460
25454
  last_test_at?: string | null;
24461
25455
  last_test_error?: string | null;
24462
25456
  last_test_ok?: boolean | null;
25457
+ last_token_test_at?: string | null;
25458
+ last_token_test_error?: string | null;
25459
+ last_token_test_ok?: boolean | null;
24463
25460
  updated_at?: string;
24464
25461
  };
24465
25462
  Relationships: [];
@@ -24692,6 +25689,54 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
24692
25689
  referencedColumns: ["id"];
24693
25690
  }];
24694
25691
  };
25692
+ floriday_auto_fulfillment_log: {
25693
+ Row: {
25694
+ attempts: number;
25695
+ connection_id: string;
25696
+ created_at: string;
25697
+ error: string | null;
25698
+ fulfillment_order_id: string | null;
25699
+ id: string;
25700
+ last_attempt_at: string | null;
25701
+ reason: string | null;
25702
+ sales_order_id: string;
25703
+ status: string;
25704
+ updated_at: string;
25705
+ };
25706
+ Insert: {
25707
+ attempts?: number;
25708
+ connection_id: string;
25709
+ created_at?: string;
25710
+ error?: string | null;
25711
+ fulfillment_order_id?: string | null;
25712
+ id?: string;
25713
+ last_attempt_at?: string | null;
25714
+ reason?: string | null;
25715
+ sales_order_id: string;
25716
+ status?: string;
25717
+ updated_at?: string;
25718
+ };
25719
+ Update: {
25720
+ attempts?: number;
25721
+ connection_id?: string;
25722
+ created_at?: string;
25723
+ error?: string | null;
25724
+ fulfillment_order_id?: string | null;
25725
+ id?: string;
25726
+ last_attempt_at?: string | null;
25727
+ reason?: string | null;
25728
+ sales_order_id?: string;
25729
+ status?: string;
25730
+ updated_at?: string;
25731
+ };
25732
+ Relationships: [{
25733
+ foreignKeyName: "floriday_auto_fulfillment_log_connection_id_fkey";
25734
+ columns: ["connection_id"];
25735
+ isOneToOne: false;
25736
+ referencedRelation: "floriday_connections";
25737
+ referencedColumns: ["id"];
25738
+ }];
25739
+ };
24695
25740
  floriday_base_items_cache: {
24696
25741
  Row: {
24697
25742
  connection_id: string;
@@ -25796,6 +26841,24 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
25796
26841
  referencedColumns: ["id"];
25797
26842
  }];
25798
26843
  };
26844
+ floriday_rate_limit_state: {
26845
+ Row: {
26846
+ bucket: string;
26847
+ last_refill_at: string;
26848
+ tokens: number;
26849
+ };
26850
+ Insert: {
26851
+ bucket: string;
26852
+ last_refill_at?: string;
26853
+ tokens: number;
26854
+ };
26855
+ Update: {
26856
+ bucket?: string;
26857
+ last_refill_at?: string;
26858
+ tokens?: number;
26859
+ };
26860
+ Relationships: [];
26861
+ };
25799
26862
  floriday_resource_schemas: {
25800
26863
  Row: {
25801
26864
  enums: import("../integrations/supabase/types").Json;
@@ -26219,6 +27282,60 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
26219
27282
  referencedColumns: ["id"];
26220
27283
  }];
26221
27284
  };
27285
+ flow_role_assignments: {
27286
+ Row: {
27287
+ created_at: string;
27288
+ id: string;
27289
+ role_id: string;
27290
+ user_id: string;
27291
+ };
27292
+ Insert: {
27293
+ created_at?: string;
27294
+ id?: string;
27295
+ role_id: string;
27296
+ user_id: string;
27297
+ };
27298
+ Update: {
27299
+ created_at?: string;
27300
+ id?: string;
27301
+ role_id?: string;
27302
+ user_id?: string;
27303
+ };
27304
+ Relationships: [{
27305
+ foreignKeyName: "flow_role_assignments_role_id_fkey";
27306
+ columns: ["role_id"];
27307
+ isOneToOne: false;
27308
+ referencedRelation: "flow_roles";
27309
+ referencedColumns: ["id"];
27310
+ }];
27311
+ };
27312
+ flow_roles: {
27313
+ Row: {
27314
+ created_at: string;
27315
+ description: string | null;
27316
+ id: string;
27317
+ module_access: string[];
27318
+ name: string;
27319
+ updated_at: string;
27320
+ };
27321
+ Insert: {
27322
+ created_at?: string;
27323
+ description?: string | null;
27324
+ id?: string;
27325
+ module_access?: string[];
27326
+ name: string;
27327
+ updated_at?: string;
27328
+ };
27329
+ Update: {
27330
+ created_at?: string;
27331
+ description?: string | null;
27332
+ id?: string;
27333
+ module_access?: string[];
27334
+ name?: string;
27335
+ updated_at?: string;
27336
+ };
27337
+ Relationships: [];
27338
+ };
26222
27339
  imap_accounts: {
26223
27340
  Row: {
26224
27341
  created_at: string;
@@ -26850,6 +27967,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
26850
27967
  matched_customer_id: string | null;
26851
27968
  message_id: string;
26852
27969
  notes: string | null;
27970
+ order_number: string | null;
26853
27971
  parsed_payload: import("../integrations/supabase/types").Json | null;
26854
27972
  reviewed_at: string | null;
26855
27973
  reviewed_by: string | null;
@@ -26865,6 +27983,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
26865
27983
  matched_customer_id?: string | null;
26866
27984
  message_id: string;
26867
27985
  notes?: string | null;
27986
+ order_number?: string | null;
26868
27987
  parsed_payload?: import("../integrations/supabase/types").Json | null;
26869
27988
  reviewed_at?: string | null;
26870
27989
  reviewed_by?: string | null;
@@ -26880,6 +27999,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
26880
27999
  matched_customer_id?: string | null;
26881
28000
  message_id?: string;
26882
28001
  notes?: string | null;
28002
+ order_number?: string | null;
26883
28003
  parsed_payload?: import("../integrations/supabase/types").Json | null;
26884
28004
  reviewed_at?: string | null;
26885
28005
  reviewed_by?: string | null;
@@ -27736,6 +28856,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27736
28856
  id: string;
27737
28857
  items: import("../integrations/supabase/types").Json;
27738
28858
  notes: string | null;
28859
+ order_number: string | null;
27739
28860
  recipient_id: string;
27740
28861
  total_amount: number;
27741
28862
  };
@@ -27749,6 +28870,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27749
28870
  id?: string;
27750
28871
  items?: import("../integrations/supabase/types").Json;
27751
28872
  notes?: string | null;
28873
+ order_number?: string | null;
27752
28874
  recipient_id: string;
27753
28875
  total_amount?: number;
27754
28876
  };
@@ -27762,6 +28884,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27762
28884
  id?: string;
27763
28885
  items?: import("../integrations/supabase/types").Json;
27764
28886
  notes?: string | null;
28887
+ order_number?: string | null;
27765
28888
  recipient_id?: string;
27766
28889
  total_amount?: number;
27767
28890
  };
@@ -27921,6 +29044,9 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27921
29044
  crates_per_layer: number;
27922
29045
  created_at: string;
27923
29046
  id: string;
29047
+ layer_fraction: number;
29048
+ layer_share_pct: number;
29049
+ layers_per_cart: number;
27924
29050
  order_item_id: string | null;
27925
29051
  plants_per_crate: number;
27926
29052
  product_id: string | null;
@@ -27932,6 +29058,9 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27932
29058
  crates_per_layer?: number;
27933
29059
  created_at?: string;
27934
29060
  id?: string;
29061
+ layer_fraction?: number;
29062
+ layer_share_pct?: number;
29063
+ layers_per_cart?: number;
27935
29064
  order_item_id?: string | null;
27936
29065
  plants_per_crate?: number;
27937
29066
  product_id?: string | null;
@@ -27943,6 +29072,9 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27943
29072
  crates_per_layer?: number;
27944
29073
  created_at?: string;
27945
29074
  id?: string;
29075
+ layer_fraction?: number;
29076
+ layer_share_pct?: number;
29077
+ layers_per_cart?: number;
27946
29078
  order_item_id?: string | null;
27947
29079
  plants_per_crate?: number;
27948
29080
  product_id?: string | null;
@@ -27970,33 +29102,45 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
27970
29102
  };
27971
29103
  order_carts: {
27972
29104
  Row: {
29105
+ algorithm_version: number;
27973
29106
  cart_number: number;
27974
29107
  created_at: string;
27975
29108
  id: string;
27976
29109
  is_auto: boolean;
27977
29110
  is_complete: boolean;
27978
29111
  notes: string | null;
29112
+ occupancy_pct: number;
27979
29113
  order_id: string;
29114
+ source: string;
29115
+ total_layers_used: number;
27980
29116
  updated_at: string;
27981
29117
  };
27982
29118
  Insert: {
29119
+ algorithm_version?: number;
27983
29120
  cart_number: number;
27984
29121
  created_at?: string;
27985
29122
  id?: string;
27986
29123
  is_auto?: boolean;
27987
29124
  is_complete?: boolean;
27988
29125
  notes?: string | null;
29126
+ occupancy_pct?: number;
27989
29127
  order_id: string;
29128
+ source?: string;
29129
+ total_layers_used?: number;
27990
29130
  updated_at?: string;
27991
29131
  };
27992
29132
  Update: {
29133
+ algorithm_version?: number;
27993
29134
  cart_number?: number;
27994
29135
  created_at?: string;
27995
29136
  id?: string;
27996
29137
  is_auto?: boolean;
27997
29138
  is_complete?: boolean;
27998
29139
  notes?: string | null;
29140
+ occupancy_pct?: number;
27999
29141
  order_id?: string;
29142
+ source?: string;
29143
+ total_layers_used?: number;
28000
29144
  updated_at?: string;
28001
29145
  };
28002
29146
  Relationships: [{
@@ -28149,6 +29293,8 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
28149
29293
  order_date: string;
28150
29294
  order_number: string;
28151
29295
  order_source: string;
29296
+ plan_locked_at: string | null;
29297
+ plan_locked_ref: string | null;
28152
29298
  status: string;
28153
29299
  total: string;
28154
29300
  updated_at: string;
@@ -28165,6 +29311,8 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
28165
29311
  order_date?: string;
28166
29312
  order_number: string;
28167
29313
  order_source?: string;
29314
+ plan_locked_at?: string | null;
29315
+ plan_locked_ref?: string | null;
28168
29316
  status?: string;
28169
29317
  total?: string;
28170
29318
  updated_at?: string;
@@ -28181,6 +29329,8 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
28181
29329
  order_date?: string;
28182
29330
  order_number?: string;
28183
29331
  order_source?: string;
29332
+ plan_locked_at?: string | null;
29333
+ plan_locked_ref?: string | null;
28184
29334
  status?: string;
28185
29335
  total?: string;
28186
29336
  updated_at?: string;
@@ -28553,6 +29703,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
28553
29703
  display_name: string | null;
28554
29704
  email: string | null;
28555
29705
  id: string;
29706
+ is_superadmin: boolean;
28556
29707
  notification_preferences: import("../integrations/supabase/types").Json;
28557
29708
  tenant_id: string | null;
28558
29709
  updated_at: string;
@@ -28562,6 +29713,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
28562
29713
  display_name?: string | null;
28563
29714
  email?: string | null;
28564
29715
  id: string;
29716
+ is_superadmin?: boolean;
28565
29717
  notification_preferences?: import("../integrations/supabase/types").Json;
28566
29718
  tenant_id?: string | null;
28567
29719
  updated_at?: string;
@@ -28571,6 +29723,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
28571
29723
  display_name?: string | null;
28572
29724
  email?: string | null;
28573
29725
  id?: string;
29726
+ is_superadmin?: boolean;
28574
29727
  notification_preferences?: import("../integrations/supabase/types").Json;
28575
29728
  tenant_id?: string | null;
28576
29729
  updated_at?: string;
@@ -29360,6 +30513,24 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
29360
30513
  };
29361
30514
  Relationships: [];
29362
30515
  };
30516
+ sidebar_config: {
30517
+ Row: {
30518
+ id: string;
30519
+ module_order: string[];
30520
+ updated_at: string;
30521
+ };
30522
+ Insert: {
30523
+ id?: string;
30524
+ module_order?: string[];
30525
+ updated_at?: string;
30526
+ };
30527
+ Update: {
30528
+ id?: string;
30529
+ module_order?: string[];
30530
+ updated_at?: string;
30531
+ };
30532
+ Relationships: [];
30533
+ };
29363
30534
  stock_import_runs: {
29364
30535
  Row: {
29365
30536
  connection_id: string | null;
@@ -29418,7 +30589,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
29418
30589
  reason: string | null;
29419
30590
  reserved_after: number | null;
29420
30591
  reserved_before: number | null;
29421
- trade_item_key: string;
30592
+ trade_item_key: string | null;
29422
30593
  };
29423
30594
  Insert: {
29424
30595
  connection_id?: string | null;
@@ -29435,7 +30606,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
29435
30606
  reason?: string | null;
29436
30607
  reserved_after?: number | null;
29437
30608
  reserved_before?: number | null;
29438
- trade_item_key: string;
30609
+ trade_item_key?: string | null;
29439
30610
  };
29440
30611
  Update: {
29441
30612
  connection_id?: string | null;
@@ -29452,7 +30623,7 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
29452
30623
  reason?: string | null;
29453
30624
  reserved_after?: number | null;
29454
30625
  reserved_before?: number | null;
29455
- trade_item_key?: string;
30626
+ trade_item_key?: string | null;
29456
30627
  };
29457
30628
  Relationships: [];
29458
30629
  };
@@ -29795,6 +30966,114 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
29795
30966
  };
29796
30967
  Relationships: [];
29797
30968
  };
30969
+ trade_item_supply_lines: {
30970
+ Row: {
30971
+ available_quantity: number | null;
30972
+ connection_id: string;
30973
+ created_at: string;
30974
+ currency: string | null;
30975
+ endpoint_family: string | null;
30976
+ environment: string | null;
30977
+ id: string;
30978
+ last_error: string | null;
30979
+ last_status: number | null;
30980
+ packing_configuration_id: string | null;
30981
+ period_end: string | null;
30982
+ period_start: string | null;
30983
+ price_per_piece: number | null;
30984
+ sales_unit: string | null;
30985
+ supply_line_id: string | null;
30986
+ supply_type: string;
30987
+ trade_item_id: string;
30988
+ updated_at: string;
30989
+ user_id: string;
30990
+ week: number | null;
30991
+ year: number | null;
30992
+ };
30993
+ Insert: {
30994
+ available_quantity?: number | null;
30995
+ connection_id: string;
30996
+ created_at?: string;
30997
+ currency?: string | null;
30998
+ endpoint_family?: string | null;
30999
+ environment?: string | null;
31000
+ id?: string;
31001
+ last_error?: string | null;
31002
+ last_status?: number | null;
31003
+ packing_configuration_id?: string | null;
31004
+ period_end?: string | null;
31005
+ period_start?: string | null;
31006
+ price_per_piece?: number | null;
31007
+ sales_unit?: string | null;
31008
+ supply_line_id?: string | null;
31009
+ supply_type?: string;
31010
+ trade_item_id: string;
31011
+ updated_at?: string;
31012
+ user_id: string;
31013
+ week?: number | null;
31014
+ year?: number | null;
31015
+ };
31016
+ Update: {
31017
+ available_quantity?: number | null;
31018
+ connection_id?: string;
31019
+ created_at?: string;
31020
+ currency?: string | null;
31021
+ endpoint_family?: string | null;
31022
+ environment?: string | null;
31023
+ id?: string;
31024
+ last_error?: string | null;
31025
+ last_status?: number | null;
31026
+ packing_configuration_id?: string | null;
31027
+ period_end?: string | null;
31028
+ period_start?: string | null;
31029
+ price_per_piece?: number | null;
31030
+ sales_unit?: string | null;
31031
+ supply_line_id?: string | null;
31032
+ supply_type?: string;
31033
+ trade_item_id?: string;
31034
+ updated_at?: string;
31035
+ user_id?: string;
31036
+ week?: number | null;
31037
+ year?: number | null;
31038
+ };
31039
+ Relationships: [];
31040
+ };
31041
+ trade_item_warehouse_preferences: {
31042
+ Row: {
31043
+ connection_id: string;
31044
+ created_at: string;
31045
+ id: string;
31046
+ trade_item_id: string;
31047
+ updated_at: string;
31048
+ warehouse_id: string;
31049
+ warehouse_name: string | null;
31050
+ };
31051
+ Insert: {
31052
+ connection_id: string;
31053
+ created_at?: string;
31054
+ id?: string;
31055
+ trade_item_id: string;
31056
+ updated_at?: string;
31057
+ warehouse_id: string;
31058
+ warehouse_name?: string | null;
31059
+ };
31060
+ Update: {
31061
+ connection_id?: string;
31062
+ created_at?: string;
31063
+ id?: string;
31064
+ trade_item_id?: string;
31065
+ updated_at?: string;
31066
+ warehouse_id?: string;
31067
+ warehouse_name?: string | null;
31068
+ };
31069
+ Relationships: [{
31070
+ foreignKeyName: "trade_item_warehouse_preferences_connection_id_fkey";
31071
+ columns: ["connection_id"];
31072
+ isOneToOne: false;
31073
+ referencedRelation: "floriday_connections";
31074
+ referencedColumns: ["id"];
31075
+ }];
31076
+ };
29798
31077
  twinfield_connections: {
29799
31078
  Row: {
29800
31079
  access_token: string | null;
@@ -30114,6 +31393,10 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
30114
31393
  default_invoice_type: string;
30115
31394
  default_payment_term_days: number;
30116
31395
  default_vat_code: string;
31396
+ invoice_enabled_ao: boolean;
31397
+ invoice_enabled_fo: boolean;
31398
+ invoice_enabled_ho: boolean;
31399
+ invoice_enabled_mo: boolean;
30117
31400
  updated_at: string;
30118
31401
  user_id: string;
30119
31402
  };
@@ -30123,6 +31406,10 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
30123
31406
  default_invoice_type?: string;
30124
31407
  default_payment_term_days?: number;
30125
31408
  default_vat_code?: string;
31409
+ invoice_enabled_ao?: boolean;
31410
+ invoice_enabled_fo?: boolean;
31411
+ invoice_enabled_ho?: boolean;
31412
+ invoice_enabled_mo?: boolean;
30126
31413
  updated_at?: string;
30127
31414
  user_id: string;
30128
31415
  };
@@ -30132,6 +31419,10 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
30132
31419
  default_invoice_type?: string;
30133
31420
  default_payment_term_days?: number;
30134
31421
  default_vat_code?: string;
31422
+ invoice_enabled_ao?: boolean;
31423
+ invoice_enabled_fo?: boolean;
31424
+ invoice_enabled_ho?: boolean;
31425
+ invoice_enabled_mo?: boolean;
30135
31426
  updated_at?: string;
30136
31427
  user_id?: string;
30137
31428
  };
@@ -31426,6 +32717,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31426
32717
  order_number: string;
31427
32718
  }[];
31428
32719
  };
32720
+ autolink_product_to_floriday: {
32721
+ Args: {
32722
+ p_product_id: string;
32723
+ };
32724
+ Returns: string;
32725
+ };
31429
32726
  backfill_open_order_reservations: {
31430
32727
  Args: never;
31431
32728
  Returns: {
@@ -31464,6 +32761,18 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31464
32761
  Args: never;
31465
32762
  Returns: number;
31466
32763
  };
32764
+ consume_floriday_rate_limit: {
32765
+ Args: {
32766
+ p_bucket: string;
32767
+ p_capacity: number;
32768
+ p_cost?: number;
32769
+ p_refill_per_sec: number;
32770
+ };
32771
+ Returns: {
32772
+ granted: boolean;
32773
+ wait_ms: number;
32774
+ }[];
32775
+ };
31467
32776
  control_get_todays_carts: {
31468
32777
  Args: never;
31469
32778
  Returns: {
@@ -31544,6 +32853,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31544
32853
  status: string;
31545
32854
  }[];
31546
32855
  };
32856
+ enqueue_cart_replan_if_unlocked: {
32857
+ Args: {
32858
+ p_order_id: string;
32859
+ };
32860
+ Returns: undefined;
32861
+ };
31547
32862
  ensure_trade_item_stock_row: {
31548
32863
  Args: {
31549
32864
  p_key: string;
@@ -31650,6 +32965,13 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31650
32965
  office_code: string;
31651
32966
  }[];
31652
32967
  };
32968
+ get_floricode_record_counts: {
32969
+ Args: never;
32970
+ Returns: {
32971
+ count: number;
32972
+ resource: string;
32973
+ }[];
32974
+ };
31653
32975
  get_floriday_agreements_active: {
31654
32976
  Args: {
31655
32977
  p_on_date?: string;
@@ -31741,6 +33063,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31741
33063
  };
31742
33064
  Returns: import("../integrations/supabase/types").Json;
31743
33065
  };
33066
+ get_offer_delivery_options: {
33067
+ Args: {
33068
+ p_code: string;
33069
+ };
33070
+ Returns: import("../integrations/supabase/types").Json;
33071
+ };
31744
33072
  get_offer_recipient_by_code: {
31745
33073
  Args: {
31746
33074
  p_code: string;
@@ -31805,6 +33133,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31805
33133
  Args: never;
31806
33134
  Returns: boolean;
31807
33135
  };
33136
+ is_superadmin: {
33137
+ Args: {
33138
+ _user_id: string;
33139
+ };
33140
+ Returns: boolean;
33141
+ };
31808
33142
  local_effective_price: {
31809
33143
  Args: {
31810
33144
  _customer_id: string;
@@ -31839,6 +33173,13 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31839
33173
  };
31840
33174
  Returns: string;
31841
33175
  };
33176
+ next_order_number_for_date: {
33177
+ Args: {
33178
+ p_created_at?: string;
33179
+ p_prefix: string;
33180
+ };
33181
+ Returns: string;
33182
+ };
31842
33183
  next_work_order_number: {
31843
33184
  Args: {
31844
33185
  p_parent_work_order_id?: string;
@@ -31846,6 +33187,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31846
33187
  };
31847
33188
  Returns: string;
31848
33189
  };
33190
+ normalize_order_source: {
33191
+ Args: {
33192
+ p_src: string;
33193
+ };
33194
+ Returns: string;
33195
+ };
31849
33196
  normalize_vat: {
31850
33197
  Args: {
31851
33198
  v: string;
@@ -31860,10 +33207,21 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31860
33207
  };
31861
33208
  Returns: boolean;
31862
33209
  };
33210
+ order_number_prefix: {
33211
+ Args: {
33212
+ p_custom_fields?: import("../integrations/supabase/types").Json;
33213
+ p_order_source: string;
33214
+ };
33215
+ Returns: string;
33216
+ };
31863
33217
  pickstation_get_orders_raw: {
31864
33218
  Args: never;
31865
33219
  Returns: import("../integrations/supabase/types").Json;
31866
33220
  };
33221
+ pickstation_get_planning_context: {
33222
+ Args: never;
33223
+ Returns: import("../integrations/supabase/types").Json;
33224
+ };
31867
33225
  pickstation_get_settings: {
31868
33226
  Args: never;
31869
33227
  Returns: import("../integrations/supabase/types").Json;
@@ -31894,6 +33252,28 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31894
33252
  };
31895
33253
  Returns: undefined;
31896
33254
  };
33255
+ recompute_order_status: {
33256
+ Args: {
33257
+ p_order_id: string;
33258
+ };
33259
+ Returns: undefined;
33260
+ };
33261
+ recompute_reserved_for_order: {
33262
+ Args: {
33263
+ p_order_id: string;
33264
+ };
33265
+ Returns: undefined;
33266
+ };
33267
+ recompute_reserved_stock: {
33268
+ Args: {
33269
+ p_trade_item_key: string;
33270
+ };
33271
+ Returns: undefined;
33272
+ };
33273
+ refresh_external_customers_grouped: {
33274
+ Args: never;
33275
+ Returns: undefined;
33276
+ };
31897
33277
  refresh_floricode_derived_code_lists: {
31898
33278
  Args: never;
31899
33279
  Returns: {
@@ -31908,6 +33288,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31908
33288
  };
31909
33289
  Returns: number;
31910
33290
  };
33291
+ refresh_floricode_derived_for_products: {
33292
+ Args: {
33293
+ _product_ids: string[];
33294
+ };
33295
+ Returns: number;
33296
+ };
31911
33297
  reset_floriday_sync_cursor: {
31912
33298
  Args: {
31913
33299
  p_connection_id: string;
@@ -31915,6 +33301,12 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
31915
33301
  };
31916
33302
  Returns: undefined;
31917
33303
  };
33304
+ resolve_product_id_for_item: {
33305
+ Args: {
33306
+ p_product_name: string;
33307
+ };
33308
+ Returns: string;
33309
+ };
31918
33310
  schedule_floriday_additional_services_sync: {
31919
33311
  Args: {
31920
33312
  p_apikey: string;
@@ -32192,6 +33584,24 @@ export declare const confirmFulfillmentOrder: import("@tanstack/start-client-cor
32192
33584
  };
32193
33585
  Returns: string[];
32194
33586
  };
33587
+ sync_cached_packing_from_product: {
33588
+ Args: {
33589
+ p_product_id: string;
33590
+ };
33591
+ Returns: undefined;
33592
+ };
33593
+ sync_order_cart_item_packing_from_product: {
33594
+ Args: {
33595
+ p_product_id: string;
33596
+ };
33597
+ Returns: undefined;
33598
+ };
33599
+ sync_product_packing_from_floriday_cache: {
33600
+ Args: {
33601
+ p_floriday_id: string;
33602
+ };
33603
+ Returns: undefined;
33604
+ };
32195
33605
  twinfield_decrypt: {
32196
33606
  Args: {
32197
33607
  cipher: string;
@@ -32230,7 +33640,10 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
32230
33640
  Tables: {
32231
33641
  afhandeling_settings: {
32232
33642
  Row: {
33643
+ auto_print_delivery_note: boolean;
33644
+ auto_process_paused: boolean;
32233
33645
  created_at: string;
33646
+ extra_pick_days_with_stickers: number;
32234
33647
  id: string;
32235
33648
  max_workdays_earlier_pick: number;
32236
33649
  pick_days_before_transport: number;
@@ -32244,7 +33657,10 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
32244
33657
  user_id: string;
32245
33658
  };
32246
33659
  Insert: {
33660
+ auto_print_delivery_note?: boolean;
33661
+ auto_process_paused?: boolean;
32247
33662
  created_at?: string;
33663
+ extra_pick_days_with_stickers?: number;
32248
33664
  id?: string;
32249
33665
  max_workdays_earlier_pick?: number;
32250
33666
  pick_days_before_transport?: number;
@@ -32258,7 +33674,10 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
32258
33674
  user_id: string;
32259
33675
  };
32260
33676
  Update: {
33677
+ auto_print_delivery_note?: boolean;
33678
+ auto_process_paused?: boolean;
32261
33679
  created_at?: string;
33680
+ extra_pick_days_with_stickers?: number;
32262
33681
  id?: string;
32263
33682
  max_workdays_earlier_pick?: number;
32264
33683
  pick_days_before_transport?: number;
@@ -33050,6 +34469,36 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
33050
34469
  };
33051
34470
  Relationships: [];
33052
34471
  };
34472
+ cart_replan_queue: {
34473
+ Row: {
34474
+ attempts: number;
34475
+ last_error: string | null;
34476
+ order_id: string;
34477
+ processed_at: string | null;
34478
+ requested_at: string;
34479
+ };
34480
+ Insert: {
34481
+ attempts?: number;
34482
+ last_error?: string | null;
34483
+ order_id: string;
34484
+ processed_at?: string | null;
34485
+ requested_at?: string;
34486
+ };
34487
+ Update: {
34488
+ attempts?: number;
34489
+ last_error?: string | null;
34490
+ order_id?: string;
34491
+ processed_at?: string | null;
34492
+ requested_at?: string;
34493
+ };
34494
+ Relationships: [{
34495
+ foreignKeyName: "cart_replan_queue_order_id_fkey";
34496
+ columns: ["order_id"];
34497
+ isOneToOne: true;
34498
+ referencedRelation: "orders";
34499
+ referencedColumns: ["id"];
34500
+ }];
34501
+ };
33053
34502
  collections: {
33054
34503
  Row: {
33055
34504
  created_at: string;
@@ -35175,34 +36624,52 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
35175
36624
  Row: {
35176
36625
  catalog_key: string | null;
35177
36626
  catalog_url: string;
36627
+ client_id: string | null;
36628
+ client_secret_ciphertext: string | null;
36629
+ client_secret_last4: string | null;
35178
36630
  created_at: string;
35179
36631
  id: number;
35180
36632
  last_meta: import("../integrations/supabase/types").Json | null;
35181
36633
  last_test_at: string | null;
35182
36634
  last_test_error: string | null;
35183
36635
  last_test_ok: boolean | null;
36636
+ last_token_test_at: string | null;
36637
+ last_token_test_error: string | null;
36638
+ last_token_test_ok: boolean | null;
35184
36639
  updated_at: string;
35185
36640
  };
35186
36641
  Insert: {
35187
36642
  catalog_key?: string | null;
35188
36643
  catalog_url?: string;
36644
+ client_id?: string | null;
36645
+ client_secret_ciphertext?: string | null;
36646
+ client_secret_last4?: string | null;
35189
36647
  created_at?: string;
35190
36648
  id?: number;
35191
36649
  last_meta?: import("../integrations/supabase/types").Json | null;
35192
36650
  last_test_at?: string | null;
35193
36651
  last_test_error?: string | null;
35194
36652
  last_test_ok?: boolean | null;
36653
+ last_token_test_at?: string | null;
36654
+ last_token_test_error?: string | null;
36655
+ last_token_test_ok?: boolean | null;
35195
36656
  updated_at?: string;
35196
36657
  };
35197
36658
  Update: {
35198
36659
  catalog_key?: string | null;
35199
36660
  catalog_url?: string;
36661
+ client_id?: string | null;
36662
+ client_secret_ciphertext?: string | null;
36663
+ client_secret_last4?: string | null;
35200
36664
  created_at?: string;
35201
36665
  id?: number;
35202
36666
  last_meta?: import("../integrations/supabase/types").Json | null;
35203
36667
  last_test_at?: string | null;
35204
36668
  last_test_error?: string | null;
35205
36669
  last_test_ok?: boolean | null;
36670
+ last_token_test_at?: string | null;
36671
+ last_token_test_error?: string | null;
36672
+ last_token_test_ok?: boolean | null;
35206
36673
  updated_at?: string;
35207
36674
  };
35208
36675
  Relationships: [];
@@ -35435,6 +36902,54 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
35435
36902
  referencedColumns: ["id"];
35436
36903
  }];
35437
36904
  };
36905
+ floriday_auto_fulfillment_log: {
36906
+ Row: {
36907
+ attempts: number;
36908
+ connection_id: string;
36909
+ created_at: string;
36910
+ error: string | null;
36911
+ fulfillment_order_id: string | null;
36912
+ id: string;
36913
+ last_attempt_at: string | null;
36914
+ reason: string | null;
36915
+ sales_order_id: string;
36916
+ status: string;
36917
+ updated_at: string;
36918
+ };
36919
+ Insert: {
36920
+ attempts?: number;
36921
+ connection_id: string;
36922
+ created_at?: string;
36923
+ error?: string | null;
36924
+ fulfillment_order_id?: string | null;
36925
+ id?: string;
36926
+ last_attempt_at?: string | null;
36927
+ reason?: string | null;
36928
+ sales_order_id: string;
36929
+ status?: string;
36930
+ updated_at?: string;
36931
+ };
36932
+ Update: {
36933
+ attempts?: number;
36934
+ connection_id?: string;
36935
+ created_at?: string;
36936
+ error?: string | null;
36937
+ fulfillment_order_id?: string | null;
36938
+ id?: string;
36939
+ last_attempt_at?: string | null;
36940
+ reason?: string | null;
36941
+ sales_order_id?: string;
36942
+ status?: string;
36943
+ updated_at?: string;
36944
+ };
36945
+ Relationships: [{
36946
+ foreignKeyName: "floriday_auto_fulfillment_log_connection_id_fkey";
36947
+ columns: ["connection_id"];
36948
+ isOneToOne: false;
36949
+ referencedRelation: "floriday_connections";
36950
+ referencedColumns: ["id"];
36951
+ }];
36952
+ };
35438
36953
  floriday_base_items_cache: {
35439
36954
  Row: {
35440
36955
  connection_id: string;
@@ -36539,6 +38054,24 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
36539
38054
  referencedColumns: ["id"];
36540
38055
  }];
36541
38056
  };
38057
+ floriday_rate_limit_state: {
38058
+ Row: {
38059
+ bucket: string;
38060
+ last_refill_at: string;
38061
+ tokens: number;
38062
+ };
38063
+ Insert: {
38064
+ bucket: string;
38065
+ last_refill_at?: string;
38066
+ tokens: number;
38067
+ };
38068
+ Update: {
38069
+ bucket?: string;
38070
+ last_refill_at?: string;
38071
+ tokens?: number;
38072
+ };
38073
+ Relationships: [];
38074
+ };
36542
38075
  floriday_resource_schemas: {
36543
38076
  Row: {
36544
38077
  enums: import("../integrations/supabase/types").Json;
@@ -36962,6 +38495,60 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
36962
38495
  referencedColumns: ["id"];
36963
38496
  }];
36964
38497
  };
38498
+ flow_role_assignments: {
38499
+ Row: {
38500
+ created_at: string;
38501
+ id: string;
38502
+ role_id: string;
38503
+ user_id: string;
38504
+ };
38505
+ Insert: {
38506
+ created_at?: string;
38507
+ id?: string;
38508
+ role_id: string;
38509
+ user_id: string;
38510
+ };
38511
+ Update: {
38512
+ created_at?: string;
38513
+ id?: string;
38514
+ role_id?: string;
38515
+ user_id?: string;
38516
+ };
38517
+ Relationships: [{
38518
+ foreignKeyName: "flow_role_assignments_role_id_fkey";
38519
+ columns: ["role_id"];
38520
+ isOneToOne: false;
38521
+ referencedRelation: "flow_roles";
38522
+ referencedColumns: ["id"];
38523
+ }];
38524
+ };
38525
+ flow_roles: {
38526
+ Row: {
38527
+ created_at: string;
38528
+ description: string | null;
38529
+ id: string;
38530
+ module_access: string[];
38531
+ name: string;
38532
+ updated_at: string;
38533
+ };
38534
+ Insert: {
38535
+ created_at?: string;
38536
+ description?: string | null;
38537
+ id?: string;
38538
+ module_access?: string[];
38539
+ name: string;
38540
+ updated_at?: string;
38541
+ };
38542
+ Update: {
38543
+ created_at?: string;
38544
+ description?: string | null;
38545
+ id?: string;
38546
+ module_access?: string[];
38547
+ name?: string;
38548
+ updated_at?: string;
38549
+ };
38550
+ Relationships: [];
38551
+ };
36965
38552
  imap_accounts: {
36966
38553
  Row: {
36967
38554
  created_at: string;
@@ -37593,6 +39180,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
37593
39180
  matched_customer_id: string | null;
37594
39181
  message_id: string;
37595
39182
  notes: string | null;
39183
+ order_number: string | null;
37596
39184
  parsed_payload: import("../integrations/supabase/types").Json | null;
37597
39185
  reviewed_at: string | null;
37598
39186
  reviewed_by: string | null;
@@ -37608,6 +39196,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
37608
39196
  matched_customer_id?: string | null;
37609
39197
  message_id: string;
37610
39198
  notes?: string | null;
39199
+ order_number?: string | null;
37611
39200
  parsed_payload?: import("../integrations/supabase/types").Json | null;
37612
39201
  reviewed_at?: string | null;
37613
39202
  reviewed_by?: string | null;
@@ -37623,6 +39212,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
37623
39212
  matched_customer_id?: string | null;
37624
39213
  message_id?: string;
37625
39214
  notes?: string | null;
39215
+ order_number?: string | null;
37626
39216
  parsed_payload?: import("../integrations/supabase/types").Json | null;
37627
39217
  reviewed_at?: string | null;
37628
39218
  reviewed_by?: string | null;
@@ -38479,6 +40069,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38479
40069
  id: string;
38480
40070
  items: import("../integrations/supabase/types").Json;
38481
40071
  notes: string | null;
40072
+ order_number: string | null;
38482
40073
  recipient_id: string;
38483
40074
  total_amount: number;
38484
40075
  };
@@ -38492,6 +40083,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38492
40083
  id?: string;
38493
40084
  items?: import("../integrations/supabase/types").Json;
38494
40085
  notes?: string | null;
40086
+ order_number?: string | null;
38495
40087
  recipient_id: string;
38496
40088
  total_amount?: number;
38497
40089
  };
@@ -38505,6 +40097,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38505
40097
  id?: string;
38506
40098
  items?: import("../integrations/supabase/types").Json;
38507
40099
  notes?: string | null;
40100
+ order_number?: string | null;
38508
40101
  recipient_id?: string;
38509
40102
  total_amount?: number;
38510
40103
  };
@@ -38664,6 +40257,9 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38664
40257
  crates_per_layer: number;
38665
40258
  created_at: string;
38666
40259
  id: string;
40260
+ layer_fraction: number;
40261
+ layer_share_pct: number;
40262
+ layers_per_cart: number;
38667
40263
  order_item_id: string | null;
38668
40264
  plants_per_crate: number;
38669
40265
  product_id: string | null;
@@ -38675,6 +40271,9 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38675
40271
  crates_per_layer?: number;
38676
40272
  created_at?: string;
38677
40273
  id?: string;
40274
+ layer_fraction?: number;
40275
+ layer_share_pct?: number;
40276
+ layers_per_cart?: number;
38678
40277
  order_item_id?: string | null;
38679
40278
  plants_per_crate?: number;
38680
40279
  product_id?: string | null;
@@ -38686,6 +40285,9 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38686
40285
  crates_per_layer?: number;
38687
40286
  created_at?: string;
38688
40287
  id?: string;
40288
+ layer_fraction?: number;
40289
+ layer_share_pct?: number;
40290
+ layers_per_cart?: number;
38689
40291
  order_item_id?: string | null;
38690
40292
  plants_per_crate?: number;
38691
40293
  product_id?: string | null;
@@ -38713,33 +40315,45 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38713
40315
  };
38714
40316
  order_carts: {
38715
40317
  Row: {
40318
+ algorithm_version: number;
38716
40319
  cart_number: number;
38717
40320
  created_at: string;
38718
40321
  id: string;
38719
40322
  is_auto: boolean;
38720
40323
  is_complete: boolean;
38721
40324
  notes: string | null;
40325
+ occupancy_pct: number;
38722
40326
  order_id: string;
40327
+ source: string;
40328
+ total_layers_used: number;
38723
40329
  updated_at: string;
38724
40330
  };
38725
40331
  Insert: {
40332
+ algorithm_version?: number;
38726
40333
  cart_number: number;
38727
40334
  created_at?: string;
38728
40335
  id?: string;
38729
40336
  is_auto?: boolean;
38730
40337
  is_complete?: boolean;
38731
40338
  notes?: string | null;
40339
+ occupancy_pct?: number;
38732
40340
  order_id: string;
40341
+ source?: string;
40342
+ total_layers_used?: number;
38733
40343
  updated_at?: string;
38734
40344
  };
38735
40345
  Update: {
40346
+ algorithm_version?: number;
38736
40347
  cart_number?: number;
38737
40348
  created_at?: string;
38738
40349
  id?: string;
38739
40350
  is_auto?: boolean;
38740
40351
  is_complete?: boolean;
38741
40352
  notes?: string | null;
40353
+ occupancy_pct?: number;
38742
40354
  order_id?: string;
40355
+ source?: string;
40356
+ total_layers_used?: number;
38743
40357
  updated_at?: string;
38744
40358
  };
38745
40359
  Relationships: [{
@@ -38892,6 +40506,8 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38892
40506
  order_date: string;
38893
40507
  order_number: string;
38894
40508
  order_source: string;
40509
+ plan_locked_at: string | null;
40510
+ plan_locked_ref: string | null;
38895
40511
  status: string;
38896
40512
  total: string;
38897
40513
  updated_at: string;
@@ -38908,6 +40524,8 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38908
40524
  order_date?: string;
38909
40525
  order_number: string;
38910
40526
  order_source?: string;
40527
+ plan_locked_at?: string | null;
40528
+ plan_locked_ref?: string | null;
38911
40529
  status?: string;
38912
40530
  total?: string;
38913
40531
  updated_at?: string;
@@ -38924,6 +40542,8 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
38924
40542
  order_date?: string;
38925
40543
  order_number?: string;
38926
40544
  order_source?: string;
40545
+ plan_locked_at?: string | null;
40546
+ plan_locked_ref?: string | null;
38927
40547
  status?: string;
38928
40548
  total?: string;
38929
40549
  updated_at?: string;
@@ -39296,6 +40916,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
39296
40916
  display_name: string | null;
39297
40917
  email: string | null;
39298
40918
  id: string;
40919
+ is_superadmin: boolean;
39299
40920
  notification_preferences: import("../integrations/supabase/types").Json;
39300
40921
  tenant_id: string | null;
39301
40922
  updated_at: string;
@@ -39305,6 +40926,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
39305
40926
  display_name?: string | null;
39306
40927
  email?: string | null;
39307
40928
  id: string;
40929
+ is_superadmin?: boolean;
39308
40930
  notification_preferences?: import("../integrations/supabase/types").Json;
39309
40931
  tenant_id?: string | null;
39310
40932
  updated_at?: string;
@@ -39314,6 +40936,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
39314
40936
  display_name?: string | null;
39315
40937
  email?: string | null;
39316
40938
  id?: string;
40939
+ is_superadmin?: boolean;
39317
40940
  notification_preferences?: import("../integrations/supabase/types").Json;
39318
40941
  tenant_id?: string | null;
39319
40942
  updated_at?: string;
@@ -40103,6 +41726,24 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40103
41726
  };
40104
41727
  Relationships: [];
40105
41728
  };
41729
+ sidebar_config: {
41730
+ Row: {
41731
+ id: string;
41732
+ module_order: string[];
41733
+ updated_at: string;
41734
+ };
41735
+ Insert: {
41736
+ id?: string;
41737
+ module_order?: string[];
41738
+ updated_at?: string;
41739
+ };
41740
+ Update: {
41741
+ id?: string;
41742
+ module_order?: string[];
41743
+ updated_at?: string;
41744
+ };
41745
+ Relationships: [];
41746
+ };
40106
41747
  stock_import_runs: {
40107
41748
  Row: {
40108
41749
  connection_id: string | null;
@@ -40161,7 +41802,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40161
41802
  reason: string | null;
40162
41803
  reserved_after: number | null;
40163
41804
  reserved_before: number | null;
40164
- trade_item_key: string;
41805
+ trade_item_key: string | null;
40165
41806
  };
40166
41807
  Insert: {
40167
41808
  connection_id?: string | null;
@@ -40178,7 +41819,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40178
41819
  reason?: string | null;
40179
41820
  reserved_after?: number | null;
40180
41821
  reserved_before?: number | null;
40181
- trade_item_key: string;
41822
+ trade_item_key?: string | null;
40182
41823
  };
40183
41824
  Update: {
40184
41825
  connection_id?: string | null;
@@ -40195,7 +41836,7 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40195
41836
  reason?: string | null;
40196
41837
  reserved_after?: number | null;
40197
41838
  reserved_before?: number | null;
40198
- trade_item_key?: string;
41839
+ trade_item_key?: string | null;
40199
41840
  };
40200
41841
  Relationships: [];
40201
41842
  };
@@ -40538,6 +42179,114 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40538
42179
  };
40539
42180
  Relationships: [];
40540
42181
  };
42182
+ trade_item_supply_lines: {
42183
+ Row: {
42184
+ available_quantity: number | null;
42185
+ connection_id: string;
42186
+ created_at: string;
42187
+ currency: string | null;
42188
+ endpoint_family: string | null;
42189
+ environment: string | null;
42190
+ id: string;
42191
+ last_error: string | null;
42192
+ last_status: number | null;
42193
+ packing_configuration_id: string | null;
42194
+ period_end: string | null;
42195
+ period_start: string | null;
42196
+ price_per_piece: number | null;
42197
+ sales_unit: string | null;
42198
+ supply_line_id: string | null;
42199
+ supply_type: string;
42200
+ trade_item_id: string;
42201
+ updated_at: string;
42202
+ user_id: string;
42203
+ week: number | null;
42204
+ year: number | null;
42205
+ };
42206
+ Insert: {
42207
+ available_quantity?: number | null;
42208
+ connection_id: string;
42209
+ created_at?: string;
42210
+ currency?: string | null;
42211
+ endpoint_family?: string | null;
42212
+ environment?: string | null;
42213
+ id?: string;
42214
+ last_error?: string | null;
42215
+ last_status?: number | null;
42216
+ packing_configuration_id?: string | null;
42217
+ period_end?: string | null;
42218
+ period_start?: string | null;
42219
+ price_per_piece?: number | null;
42220
+ sales_unit?: string | null;
42221
+ supply_line_id?: string | null;
42222
+ supply_type?: string;
42223
+ trade_item_id: string;
42224
+ updated_at?: string;
42225
+ user_id: string;
42226
+ week?: number | null;
42227
+ year?: number | null;
42228
+ };
42229
+ Update: {
42230
+ available_quantity?: number | null;
42231
+ connection_id?: string;
42232
+ created_at?: string;
42233
+ currency?: string | null;
42234
+ endpoint_family?: string | null;
42235
+ environment?: string | null;
42236
+ id?: string;
42237
+ last_error?: string | null;
42238
+ last_status?: number | null;
42239
+ packing_configuration_id?: string | null;
42240
+ period_end?: string | null;
42241
+ period_start?: string | null;
42242
+ price_per_piece?: number | null;
42243
+ sales_unit?: string | null;
42244
+ supply_line_id?: string | null;
42245
+ supply_type?: string;
42246
+ trade_item_id?: string;
42247
+ updated_at?: string;
42248
+ user_id?: string;
42249
+ week?: number | null;
42250
+ year?: number | null;
42251
+ };
42252
+ Relationships: [];
42253
+ };
42254
+ trade_item_warehouse_preferences: {
42255
+ Row: {
42256
+ connection_id: string;
42257
+ created_at: string;
42258
+ id: string;
42259
+ trade_item_id: string;
42260
+ updated_at: string;
42261
+ warehouse_id: string;
42262
+ warehouse_name: string | null;
42263
+ };
42264
+ Insert: {
42265
+ connection_id: string;
42266
+ created_at?: string;
42267
+ id?: string;
42268
+ trade_item_id: string;
42269
+ updated_at?: string;
42270
+ warehouse_id: string;
42271
+ warehouse_name?: string | null;
42272
+ };
42273
+ Update: {
42274
+ connection_id?: string;
42275
+ created_at?: string;
42276
+ id?: string;
42277
+ trade_item_id?: string;
42278
+ updated_at?: string;
42279
+ warehouse_id?: string;
42280
+ warehouse_name?: string | null;
42281
+ };
42282
+ Relationships: [{
42283
+ foreignKeyName: "trade_item_warehouse_preferences_connection_id_fkey";
42284
+ columns: ["connection_id"];
42285
+ isOneToOne: false;
42286
+ referencedRelation: "floriday_connections";
42287
+ referencedColumns: ["id"];
42288
+ }];
42289
+ };
40541
42290
  twinfield_connections: {
40542
42291
  Row: {
40543
42292
  access_token: string | null;
@@ -40857,6 +42606,10 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40857
42606
  default_invoice_type: string;
40858
42607
  default_payment_term_days: number;
40859
42608
  default_vat_code: string;
42609
+ invoice_enabled_ao: boolean;
42610
+ invoice_enabled_fo: boolean;
42611
+ invoice_enabled_ho: boolean;
42612
+ invoice_enabled_mo: boolean;
40860
42613
  updated_at: string;
40861
42614
  user_id: string;
40862
42615
  };
@@ -40866,6 +42619,10 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40866
42619
  default_invoice_type?: string;
40867
42620
  default_payment_term_days?: number;
40868
42621
  default_vat_code?: string;
42622
+ invoice_enabled_ao?: boolean;
42623
+ invoice_enabled_fo?: boolean;
42624
+ invoice_enabled_ho?: boolean;
42625
+ invoice_enabled_mo?: boolean;
40869
42626
  updated_at?: string;
40870
42627
  user_id: string;
40871
42628
  };
@@ -40875,6 +42632,10 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
40875
42632
  default_invoice_type?: string;
40876
42633
  default_payment_term_days?: number;
40877
42634
  default_vat_code?: string;
42635
+ invoice_enabled_ao?: boolean;
42636
+ invoice_enabled_fo?: boolean;
42637
+ invoice_enabled_ho?: boolean;
42638
+ invoice_enabled_mo?: boolean;
40878
42639
  updated_at?: string;
40879
42640
  user_id?: string;
40880
42641
  };
@@ -42169,6 +43930,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42169
43930
  order_number: string;
42170
43931
  }[];
42171
43932
  };
43933
+ autolink_product_to_floriday: {
43934
+ Args: {
43935
+ p_product_id: string;
43936
+ };
43937
+ Returns: string;
43938
+ };
42172
43939
  backfill_open_order_reservations: {
42173
43940
  Args: never;
42174
43941
  Returns: {
@@ -42207,6 +43974,18 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42207
43974
  Args: never;
42208
43975
  Returns: number;
42209
43976
  };
43977
+ consume_floriday_rate_limit: {
43978
+ Args: {
43979
+ p_bucket: string;
43980
+ p_capacity: number;
43981
+ p_cost?: number;
43982
+ p_refill_per_sec: number;
43983
+ };
43984
+ Returns: {
43985
+ granted: boolean;
43986
+ wait_ms: number;
43987
+ }[];
43988
+ };
42210
43989
  control_get_todays_carts: {
42211
43990
  Args: never;
42212
43991
  Returns: {
@@ -42287,6 +44066,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42287
44066
  status: string;
42288
44067
  }[];
42289
44068
  };
44069
+ enqueue_cart_replan_if_unlocked: {
44070
+ Args: {
44071
+ p_order_id: string;
44072
+ };
44073
+ Returns: undefined;
44074
+ };
42290
44075
  ensure_trade_item_stock_row: {
42291
44076
  Args: {
42292
44077
  p_key: string;
@@ -42393,6 +44178,13 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42393
44178
  office_code: string;
42394
44179
  }[];
42395
44180
  };
44181
+ get_floricode_record_counts: {
44182
+ Args: never;
44183
+ Returns: {
44184
+ count: number;
44185
+ resource: string;
44186
+ }[];
44187
+ };
42396
44188
  get_floriday_agreements_active: {
42397
44189
  Args: {
42398
44190
  p_on_date?: string;
@@ -42484,6 +44276,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42484
44276
  };
42485
44277
  Returns: import("../integrations/supabase/types").Json;
42486
44278
  };
44279
+ get_offer_delivery_options: {
44280
+ Args: {
44281
+ p_code: string;
44282
+ };
44283
+ Returns: import("../integrations/supabase/types").Json;
44284
+ };
42487
44285
  get_offer_recipient_by_code: {
42488
44286
  Args: {
42489
44287
  p_code: string;
@@ -42548,6 +44346,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42548
44346
  Args: never;
42549
44347
  Returns: boolean;
42550
44348
  };
44349
+ is_superadmin: {
44350
+ Args: {
44351
+ _user_id: string;
44352
+ };
44353
+ Returns: boolean;
44354
+ };
42551
44355
  local_effective_price: {
42552
44356
  Args: {
42553
44357
  _customer_id: string;
@@ -42582,6 +44386,13 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42582
44386
  };
42583
44387
  Returns: string;
42584
44388
  };
44389
+ next_order_number_for_date: {
44390
+ Args: {
44391
+ p_created_at?: string;
44392
+ p_prefix: string;
44393
+ };
44394
+ Returns: string;
44395
+ };
42585
44396
  next_work_order_number: {
42586
44397
  Args: {
42587
44398
  p_parent_work_order_id?: string;
@@ -42589,6 +44400,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42589
44400
  };
42590
44401
  Returns: string;
42591
44402
  };
44403
+ normalize_order_source: {
44404
+ Args: {
44405
+ p_src: string;
44406
+ };
44407
+ Returns: string;
44408
+ };
42592
44409
  normalize_vat: {
42593
44410
  Args: {
42594
44411
  v: string;
@@ -42603,10 +44420,21 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42603
44420
  };
42604
44421
  Returns: boolean;
42605
44422
  };
44423
+ order_number_prefix: {
44424
+ Args: {
44425
+ p_custom_fields?: import("../integrations/supabase/types").Json;
44426
+ p_order_source: string;
44427
+ };
44428
+ Returns: string;
44429
+ };
42606
44430
  pickstation_get_orders_raw: {
42607
44431
  Args: never;
42608
44432
  Returns: import("../integrations/supabase/types").Json;
42609
44433
  };
44434
+ pickstation_get_planning_context: {
44435
+ Args: never;
44436
+ Returns: import("../integrations/supabase/types").Json;
44437
+ };
42610
44438
  pickstation_get_settings: {
42611
44439
  Args: never;
42612
44440
  Returns: import("../integrations/supabase/types").Json;
@@ -42637,6 +44465,28 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42637
44465
  };
42638
44466
  Returns: undefined;
42639
44467
  };
44468
+ recompute_order_status: {
44469
+ Args: {
44470
+ p_order_id: string;
44471
+ };
44472
+ Returns: undefined;
44473
+ };
44474
+ recompute_reserved_for_order: {
44475
+ Args: {
44476
+ p_order_id: string;
44477
+ };
44478
+ Returns: undefined;
44479
+ };
44480
+ recompute_reserved_stock: {
44481
+ Args: {
44482
+ p_trade_item_key: string;
44483
+ };
44484
+ Returns: undefined;
44485
+ };
44486
+ refresh_external_customers_grouped: {
44487
+ Args: never;
44488
+ Returns: undefined;
44489
+ };
42640
44490
  refresh_floricode_derived_code_lists: {
42641
44491
  Args: never;
42642
44492
  Returns: {
@@ -42651,6 +44501,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42651
44501
  };
42652
44502
  Returns: number;
42653
44503
  };
44504
+ refresh_floricode_derived_for_products: {
44505
+ Args: {
44506
+ _product_ids: string[];
44507
+ };
44508
+ Returns: number;
44509
+ };
42654
44510
  reset_floriday_sync_cursor: {
42655
44511
  Args: {
42656
44512
  p_connection_id: string;
@@ -42658,6 +44514,12 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42658
44514
  };
42659
44515
  Returns: undefined;
42660
44516
  };
44517
+ resolve_product_id_for_item: {
44518
+ Args: {
44519
+ p_product_name: string;
44520
+ };
44521
+ Returns: string;
44522
+ };
42661
44523
  schedule_floriday_additional_services_sync: {
42662
44524
  Args: {
42663
44525
  p_apikey: string;
@@ -42935,6 +44797,24 @@ export declare const publishTradeItem: import("@tanstack/start-client-core").Opt
42935
44797
  };
42936
44798
  Returns: string[];
42937
44799
  };
44800
+ sync_cached_packing_from_product: {
44801
+ Args: {
44802
+ p_product_id: string;
44803
+ };
44804
+ Returns: undefined;
44805
+ };
44806
+ sync_order_cart_item_packing_from_product: {
44807
+ Args: {
44808
+ p_product_id: string;
44809
+ };
44810
+ Returns: undefined;
44811
+ };
44812
+ sync_product_packing_from_floriday_cache: {
44813
+ Args: {
44814
+ p_floriday_id: string;
44815
+ };
44816
+ Returns: undefined;
44817
+ };
42938
44818
  twinfield_decrypt: {
42939
44819
  Args: {
42940
44820
  cipher: string;
@@ -42970,7 +44850,10 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
42970
44850
  Tables: {
42971
44851
  afhandeling_settings: {
42972
44852
  Row: {
44853
+ auto_print_delivery_note: boolean;
44854
+ auto_process_paused: boolean;
42973
44855
  created_at: string;
44856
+ extra_pick_days_with_stickers: number;
42974
44857
  id: string;
42975
44858
  max_workdays_earlier_pick: number;
42976
44859
  pick_days_before_transport: number;
@@ -42984,7 +44867,10 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
42984
44867
  user_id: string;
42985
44868
  };
42986
44869
  Insert: {
44870
+ auto_print_delivery_note?: boolean;
44871
+ auto_process_paused?: boolean;
42987
44872
  created_at?: string;
44873
+ extra_pick_days_with_stickers?: number;
42988
44874
  id?: string;
42989
44875
  max_workdays_earlier_pick?: number;
42990
44876
  pick_days_before_transport?: number;
@@ -42998,7 +44884,10 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
42998
44884
  user_id: string;
42999
44885
  };
43000
44886
  Update: {
44887
+ auto_print_delivery_note?: boolean;
44888
+ auto_process_paused?: boolean;
43001
44889
  created_at?: string;
44890
+ extra_pick_days_with_stickers?: number;
43002
44891
  id?: string;
43003
44892
  max_workdays_earlier_pick?: number;
43004
44893
  pick_days_before_transport?: number;
@@ -43790,6 +45679,36 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
43790
45679
  };
43791
45680
  Relationships: [];
43792
45681
  };
45682
+ cart_replan_queue: {
45683
+ Row: {
45684
+ attempts: number;
45685
+ last_error: string | null;
45686
+ order_id: string;
45687
+ processed_at: string | null;
45688
+ requested_at: string;
45689
+ };
45690
+ Insert: {
45691
+ attempts?: number;
45692
+ last_error?: string | null;
45693
+ order_id: string;
45694
+ processed_at?: string | null;
45695
+ requested_at?: string;
45696
+ };
45697
+ Update: {
45698
+ attempts?: number;
45699
+ last_error?: string | null;
45700
+ order_id?: string;
45701
+ processed_at?: string | null;
45702
+ requested_at?: string;
45703
+ };
45704
+ Relationships: [{
45705
+ foreignKeyName: "cart_replan_queue_order_id_fkey";
45706
+ columns: ["order_id"];
45707
+ isOneToOne: true;
45708
+ referencedRelation: "orders";
45709
+ referencedColumns: ["id"];
45710
+ }];
45711
+ };
43793
45712
  collections: {
43794
45713
  Row: {
43795
45714
  created_at: string;
@@ -45915,34 +47834,52 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
45915
47834
  Row: {
45916
47835
  catalog_key: string | null;
45917
47836
  catalog_url: string;
47837
+ client_id: string | null;
47838
+ client_secret_ciphertext: string | null;
47839
+ client_secret_last4: string | null;
45918
47840
  created_at: string;
45919
47841
  id: number;
45920
47842
  last_meta: import("../integrations/supabase/types").Json | null;
45921
47843
  last_test_at: string | null;
45922
47844
  last_test_error: string | null;
45923
47845
  last_test_ok: boolean | null;
47846
+ last_token_test_at: string | null;
47847
+ last_token_test_error: string | null;
47848
+ last_token_test_ok: boolean | null;
45924
47849
  updated_at: string;
45925
47850
  };
45926
47851
  Insert: {
45927
47852
  catalog_key?: string | null;
45928
47853
  catalog_url?: string;
47854
+ client_id?: string | null;
47855
+ client_secret_ciphertext?: string | null;
47856
+ client_secret_last4?: string | null;
45929
47857
  created_at?: string;
45930
47858
  id?: number;
45931
47859
  last_meta?: import("../integrations/supabase/types").Json | null;
45932
47860
  last_test_at?: string | null;
45933
47861
  last_test_error?: string | null;
45934
47862
  last_test_ok?: boolean | null;
47863
+ last_token_test_at?: string | null;
47864
+ last_token_test_error?: string | null;
47865
+ last_token_test_ok?: boolean | null;
45935
47866
  updated_at?: string;
45936
47867
  };
45937
47868
  Update: {
45938
47869
  catalog_key?: string | null;
45939
47870
  catalog_url?: string;
47871
+ client_id?: string | null;
47872
+ client_secret_ciphertext?: string | null;
47873
+ client_secret_last4?: string | null;
45940
47874
  created_at?: string;
45941
47875
  id?: number;
45942
47876
  last_meta?: import("../integrations/supabase/types").Json | null;
45943
47877
  last_test_at?: string | null;
45944
47878
  last_test_error?: string | null;
45945
47879
  last_test_ok?: boolean | null;
47880
+ last_token_test_at?: string | null;
47881
+ last_token_test_error?: string | null;
47882
+ last_token_test_ok?: boolean | null;
45946
47883
  updated_at?: string;
45947
47884
  };
45948
47885
  Relationships: [];
@@ -46175,6 +48112,54 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
46175
48112
  referencedColumns: ["id"];
46176
48113
  }];
46177
48114
  };
48115
+ floriday_auto_fulfillment_log: {
48116
+ Row: {
48117
+ attempts: number;
48118
+ connection_id: string;
48119
+ created_at: string;
48120
+ error: string | null;
48121
+ fulfillment_order_id: string | null;
48122
+ id: string;
48123
+ last_attempt_at: string | null;
48124
+ reason: string | null;
48125
+ sales_order_id: string;
48126
+ status: string;
48127
+ updated_at: string;
48128
+ };
48129
+ Insert: {
48130
+ attempts?: number;
48131
+ connection_id: string;
48132
+ created_at?: string;
48133
+ error?: string | null;
48134
+ fulfillment_order_id?: string | null;
48135
+ id?: string;
48136
+ last_attempt_at?: string | null;
48137
+ reason?: string | null;
48138
+ sales_order_id: string;
48139
+ status?: string;
48140
+ updated_at?: string;
48141
+ };
48142
+ Update: {
48143
+ attempts?: number;
48144
+ connection_id?: string;
48145
+ created_at?: string;
48146
+ error?: string | null;
48147
+ fulfillment_order_id?: string | null;
48148
+ id?: string;
48149
+ last_attempt_at?: string | null;
48150
+ reason?: string | null;
48151
+ sales_order_id?: string;
48152
+ status?: string;
48153
+ updated_at?: string;
48154
+ };
48155
+ Relationships: [{
48156
+ foreignKeyName: "floriday_auto_fulfillment_log_connection_id_fkey";
48157
+ columns: ["connection_id"];
48158
+ isOneToOne: false;
48159
+ referencedRelation: "floriday_connections";
48160
+ referencedColumns: ["id"];
48161
+ }];
48162
+ };
46178
48163
  floriday_base_items_cache: {
46179
48164
  Row: {
46180
48165
  connection_id: string;
@@ -47279,6 +49264,24 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
47279
49264
  referencedColumns: ["id"];
47280
49265
  }];
47281
49266
  };
49267
+ floriday_rate_limit_state: {
49268
+ Row: {
49269
+ bucket: string;
49270
+ last_refill_at: string;
49271
+ tokens: number;
49272
+ };
49273
+ Insert: {
49274
+ bucket: string;
49275
+ last_refill_at?: string;
49276
+ tokens: number;
49277
+ };
49278
+ Update: {
49279
+ bucket?: string;
49280
+ last_refill_at?: string;
49281
+ tokens?: number;
49282
+ };
49283
+ Relationships: [];
49284
+ };
47282
49285
  floriday_resource_schemas: {
47283
49286
  Row: {
47284
49287
  enums: import("../integrations/supabase/types").Json;
@@ -47702,6 +49705,60 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
47702
49705
  referencedColumns: ["id"];
47703
49706
  }];
47704
49707
  };
49708
+ flow_role_assignments: {
49709
+ Row: {
49710
+ created_at: string;
49711
+ id: string;
49712
+ role_id: string;
49713
+ user_id: string;
49714
+ };
49715
+ Insert: {
49716
+ created_at?: string;
49717
+ id?: string;
49718
+ role_id: string;
49719
+ user_id: string;
49720
+ };
49721
+ Update: {
49722
+ created_at?: string;
49723
+ id?: string;
49724
+ role_id?: string;
49725
+ user_id?: string;
49726
+ };
49727
+ Relationships: [{
49728
+ foreignKeyName: "flow_role_assignments_role_id_fkey";
49729
+ columns: ["role_id"];
49730
+ isOneToOne: false;
49731
+ referencedRelation: "flow_roles";
49732
+ referencedColumns: ["id"];
49733
+ }];
49734
+ };
49735
+ flow_roles: {
49736
+ Row: {
49737
+ created_at: string;
49738
+ description: string | null;
49739
+ id: string;
49740
+ module_access: string[];
49741
+ name: string;
49742
+ updated_at: string;
49743
+ };
49744
+ Insert: {
49745
+ created_at?: string;
49746
+ description?: string | null;
49747
+ id?: string;
49748
+ module_access?: string[];
49749
+ name: string;
49750
+ updated_at?: string;
49751
+ };
49752
+ Update: {
49753
+ created_at?: string;
49754
+ description?: string | null;
49755
+ id?: string;
49756
+ module_access?: string[];
49757
+ name?: string;
49758
+ updated_at?: string;
49759
+ };
49760
+ Relationships: [];
49761
+ };
47705
49762
  imap_accounts: {
47706
49763
  Row: {
47707
49764
  created_at: string;
@@ -48333,6 +50390,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
48333
50390
  matched_customer_id: string | null;
48334
50391
  message_id: string;
48335
50392
  notes: string | null;
50393
+ order_number: string | null;
48336
50394
  parsed_payload: import("../integrations/supabase/types").Json | null;
48337
50395
  reviewed_at: string | null;
48338
50396
  reviewed_by: string | null;
@@ -48348,6 +50406,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
48348
50406
  matched_customer_id?: string | null;
48349
50407
  message_id: string;
48350
50408
  notes?: string | null;
50409
+ order_number?: string | null;
48351
50410
  parsed_payload?: import("../integrations/supabase/types").Json | null;
48352
50411
  reviewed_at?: string | null;
48353
50412
  reviewed_by?: string | null;
@@ -48363,6 +50422,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
48363
50422
  matched_customer_id?: string | null;
48364
50423
  message_id?: string;
48365
50424
  notes?: string | null;
50425
+ order_number?: string | null;
48366
50426
  parsed_payload?: import("../integrations/supabase/types").Json | null;
48367
50427
  reviewed_at?: string | null;
48368
50428
  reviewed_by?: string | null;
@@ -49219,6 +51279,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49219
51279
  id: string;
49220
51280
  items: import("../integrations/supabase/types").Json;
49221
51281
  notes: string | null;
51282
+ order_number: string | null;
49222
51283
  recipient_id: string;
49223
51284
  total_amount: number;
49224
51285
  };
@@ -49232,6 +51293,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49232
51293
  id?: string;
49233
51294
  items?: import("../integrations/supabase/types").Json;
49234
51295
  notes?: string | null;
51296
+ order_number?: string | null;
49235
51297
  recipient_id: string;
49236
51298
  total_amount?: number;
49237
51299
  };
@@ -49245,6 +51307,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49245
51307
  id?: string;
49246
51308
  items?: import("../integrations/supabase/types").Json;
49247
51309
  notes?: string | null;
51310
+ order_number?: string | null;
49248
51311
  recipient_id?: string;
49249
51312
  total_amount?: number;
49250
51313
  };
@@ -49404,6 +51467,9 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49404
51467
  crates_per_layer: number;
49405
51468
  created_at: string;
49406
51469
  id: string;
51470
+ layer_fraction: number;
51471
+ layer_share_pct: number;
51472
+ layers_per_cart: number;
49407
51473
  order_item_id: string | null;
49408
51474
  plants_per_crate: number;
49409
51475
  product_id: string | null;
@@ -49415,6 +51481,9 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49415
51481
  crates_per_layer?: number;
49416
51482
  created_at?: string;
49417
51483
  id?: string;
51484
+ layer_fraction?: number;
51485
+ layer_share_pct?: number;
51486
+ layers_per_cart?: number;
49418
51487
  order_item_id?: string | null;
49419
51488
  plants_per_crate?: number;
49420
51489
  product_id?: string | null;
@@ -49426,6 +51495,9 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49426
51495
  crates_per_layer?: number;
49427
51496
  created_at?: string;
49428
51497
  id?: string;
51498
+ layer_fraction?: number;
51499
+ layer_share_pct?: number;
51500
+ layers_per_cart?: number;
49429
51501
  order_item_id?: string | null;
49430
51502
  plants_per_crate?: number;
49431
51503
  product_id?: string | null;
@@ -49453,33 +51525,45 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49453
51525
  };
49454
51526
  order_carts: {
49455
51527
  Row: {
51528
+ algorithm_version: number;
49456
51529
  cart_number: number;
49457
51530
  created_at: string;
49458
51531
  id: string;
49459
51532
  is_auto: boolean;
49460
51533
  is_complete: boolean;
49461
51534
  notes: string | null;
51535
+ occupancy_pct: number;
49462
51536
  order_id: string;
51537
+ source: string;
51538
+ total_layers_used: number;
49463
51539
  updated_at: string;
49464
51540
  };
49465
51541
  Insert: {
51542
+ algorithm_version?: number;
49466
51543
  cart_number: number;
49467
51544
  created_at?: string;
49468
51545
  id?: string;
49469
51546
  is_auto?: boolean;
49470
51547
  is_complete?: boolean;
49471
51548
  notes?: string | null;
51549
+ occupancy_pct?: number;
49472
51550
  order_id: string;
51551
+ source?: string;
51552
+ total_layers_used?: number;
49473
51553
  updated_at?: string;
49474
51554
  };
49475
51555
  Update: {
51556
+ algorithm_version?: number;
49476
51557
  cart_number?: number;
49477
51558
  created_at?: string;
49478
51559
  id?: string;
49479
51560
  is_auto?: boolean;
49480
51561
  is_complete?: boolean;
49481
51562
  notes?: string | null;
51563
+ occupancy_pct?: number;
49482
51564
  order_id?: string;
51565
+ source?: string;
51566
+ total_layers_used?: number;
49483
51567
  updated_at?: string;
49484
51568
  };
49485
51569
  Relationships: [{
@@ -49632,6 +51716,8 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49632
51716
  order_date: string;
49633
51717
  order_number: string;
49634
51718
  order_source: string;
51719
+ plan_locked_at: string | null;
51720
+ plan_locked_ref: string | null;
49635
51721
  status: string;
49636
51722
  total: string;
49637
51723
  updated_at: string;
@@ -49648,6 +51734,8 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49648
51734
  order_date?: string;
49649
51735
  order_number: string;
49650
51736
  order_source?: string;
51737
+ plan_locked_at?: string | null;
51738
+ plan_locked_ref?: string | null;
49651
51739
  status?: string;
49652
51740
  total?: string;
49653
51741
  updated_at?: string;
@@ -49664,6 +51752,8 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
49664
51752
  order_date?: string;
49665
51753
  order_number?: string;
49666
51754
  order_source?: string;
51755
+ plan_locked_at?: string | null;
51756
+ plan_locked_ref?: string | null;
49667
51757
  status?: string;
49668
51758
  total?: string;
49669
51759
  updated_at?: string;
@@ -50036,6 +52126,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50036
52126
  display_name: string | null;
50037
52127
  email: string | null;
50038
52128
  id: string;
52129
+ is_superadmin: boolean;
50039
52130
  notification_preferences: import("../integrations/supabase/types").Json;
50040
52131
  tenant_id: string | null;
50041
52132
  updated_at: string;
@@ -50045,6 +52136,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50045
52136
  display_name?: string | null;
50046
52137
  email?: string | null;
50047
52138
  id: string;
52139
+ is_superadmin?: boolean;
50048
52140
  notification_preferences?: import("../integrations/supabase/types").Json;
50049
52141
  tenant_id?: string | null;
50050
52142
  updated_at?: string;
@@ -50054,6 +52146,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50054
52146
  display_name?: string | null;
50055
52147
  email?: string | null;
50056
52148
  id?: string;
52149
+ is_superadmin?: boolean;
50057
52150
  notification_preferences?: import("../integrations/supabase/types").Json;
50058
52151
  tenant_id?: string | null;
50059
52152
  updated_at?: string;
@@ -50843,6 +52936,24 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50843
52936
  };
50844
52937
  Relationships: [];
50845
52938
  };
52939
+ sidebar_config: {
52940
+ Row: {
52941
+ id: string;
52942
+ module_order: string[];
52943
+ updated_at: string;
52944
+ };
52945
+ Insert: {
52946
+ id?: string;
52947
+ module_order?: string[];
52948
+ updated_at?: string;
52949
+ };
52950
+ Update: {
52951
+ id?: string;
52952
+ module_order?: string[];
52953
+ updated_at?: string;
52954
+ };
52955
+ Relationships: [];
52956
+ };
50846
52957
  stock_import_runs: {
50847
52958
  Row: {
50848
52959
  connection_id: string | null;
@@ -50901,7 +53012,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50901
53012
  reason: string | null;
50902
53013
  reserved_after: number | null;
50903
53014
  reserved_before: number | null;
50904
- trade_item_key: string;
53015
+ trade_item_key: string | null;
50905
53016
  };
50906
53017
  Insert: {
50907
53018
  connection_id?: string | null;
@@ -50918,7 +53029,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50918
53029
  reason?: string | null;
50919
53030
  reserved_after?: number | null;
50920
53031
  reserved_before?: number | null;
50921
- trade_item_key: string;
53032
+ trade_item_key?: string | null;
50922
53033
  };
50923
53034
  Update: {
50924
53035
  connection_id?: string | null;
@@ -50935,7 +53046,7 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
50935
53046
  reason?: string | null;
50936
53047
  reserved_after?: number | null;
50937
53048
  reserved_before?: number | null;
50938
- trade_item_key?: string;
53049
+ trade_item_key?: string | null;
50939
53050
  };
50940
53051
  Relationships: [];
50941
53052
  };
@@ -51278,6 +53389,114 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
51278
53389
  };
51279
53390
  Relationships: [];
51280
53391
  };
53392
+ trade_item_supply_lines: {
53393
+ Row: {
53394
+ available_quantity: number | null;
53395
+ connection_id: string;
53396
+ created_at: string;
53397
+ currency: string | null;
53398
+ endpoint_family: string | null;
53399
+ environment: string | null;
53400
+ id: string;
53401
+ last_error: string | null;
53402
+ last_status: number | null;
53403
+ packing_configuration_id: string | null;
53404
+ period_end: string | null;
53405
+ period_start: string | null;
53406
+ price_per_piece: number | null;
53407
+ sales_unit: string | null;
53408
+ supply_line_id: string | null;
53409
+ supply_type: string;
53410
+ trade_item_id: string;
53411
+ updated_at: string;
53412
+ user_id: string;
53413
+ week: number | null;
53414
+ year: number | null;
53415
+ };
53416
+ Insert: {
53417
+ available_quantity?: number | null;
53418
+ connection_id: string;
53419
+ created_at?: string;
53420
+ currency?: string | null;
53421
+ endpoint_family?: string | null;
53422
+ environment?: string | null;
53423
+ id?: string;
53424
+ last_error?: string | null;
53425
+ last_status?: number | null;
53426
+ packing_configuration_id?: string | null;
53427
+ period_end?: string | null;
53428
+ period_start?: string | null;
53429
+ price_per_piece?: number | null;
53430
+ sales_unit?: string | null;
53431
+ supply_line_id?: string | null;
53432
+ supply_type?: string;
53433
+ trade_item_id: string;
53434
+ updated_at?: string;
53435
+ user_id: string;
53436
+ week?: number | null;
53437
+ year?: number | null;
53438
+ };
53439
+ Update: {
53440
+ available_quantity?: number | null;
53441
+ connection_id?: string;
53442
+ created_at?: string;
53443
+ currency?: string | null;
53444
+ endpoint_family?: string | null;
53445
+ environment?: string | null;
53446
+ id?: string;
53447
+ last_error?: string | null;
53448
+ last_status?: number | null;
53449
+ packing_configuration_id?: string | null;
53450
+ period_end?: string | null;
53451
+ period_start?: string | null;
53452
+ price_per_piece?: number | null;
53453
+ sales_unit?: string | null;
53454
+ supply_line_id?: string | null;
53455
+ supply_type?: string;
53456
+ trade_item_id?: string;
53457
+ updated_at?: string;
53458
+ user_id?: string;
53459
+ week?: number | null;
53460
+ year?: number | null;
53461
+ };
53462
+ Relationships: [];
53463
+ };
53464
+ trade_item_warehouse_preferences: {
53465
+ Row: {
53466
+ connection_id: string;
53467
+ created_at: string;
53468
+ id: string;
53469
+ trade_item_id: string;
53470
+ updated_at: string;
53471
+ warehouse_id: string;
53472
+ warehouse_name: string | null;
53473
+ };
53474
+ Insert: {
53475
+ connection_id: string;
53476
+ created_at?: string;
53477
+ id?: string;
53478
+ trade_item_id: string;
53479
+ updated_at?: string;
53480
+ warehouse_id: string;
53481
+ warehouse_name?: string | null;
53482
+ };
53483
+ Update: {
53484
+ connection_id?: string;
53485
+ created_at?: string;
53486
+ id?: string;
53487
+ trade_item_id?: string;
53488
+ updated_at?: string;
53489
+ warehouse_id?: string;
53490
+ warehouse_name?: string | null;
53491
+ };
53492
+ Relationships: [{
53493
+ foreignKeyName: "trade_item_warehouse_preferences_connection_id_fkey";
53494
+ columns: ["connection_id"];
53495
+ isOneToOne: false;
53496
+ referencedRelation: "floriday_connections";
53497
+ referencedColumns: ["id"];
53498
+ }];
53499
+ };
51281
53500
  twinfield_connections: {
51282
53501
  Row: {
51283
53502
  access_token: string | null;
@@ -51597,6 +53816,10 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
51597
53816
  default_invoice_type: string;
51598
53817
  default_payment_term_days: number;
51599
53818
  default_vat_code: string;
53819
+ invoice_enabled_ao: boolean;
53820
+ invoice_enabled_fo: boolean;
53821
+ invoice_enabled_ho: boolean;
53822
+ invoice_enabled_mo: boolean;
51600
53823
  updated_at: string;
51601
53824
  user_id: string;
51602
53825
  };
@@ -51606,6 +53829,10 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
51606
53829
  default_invoice_type?: string;
51607
53830
  default_payment_term_days?: number;
51608
53831
  default_vat_code?: string;
53832
+ invoice_enabled_ao?: boolean;
53833
+ invoice_enabled_fo?: boolean;
53834
+ invoice_enabled_ho?: boolean;
53835
+ invoice_enabled_mo?: boolean;
51609
53836
  updated_at?: string;
51610
53837
  user_id: string;
51611
53838
  };
@@ -51615,6 +53842,10 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
51615
53842
  default_invoice_type?: string;
51616
53843
  default_payment_term_days?: number;
51617
53844
  default_vat_code?: string;
53845
+ invoice_enabled_ao?: boolean;
53846
+ invoice_enabled_fo?: boolean;
53847
+ invoice_enabled_ho?: boolean;
53848
+ invoice_enabled_mo?: boolean;
51618
53849
  updated_at?: string;
51619
53850
  user_id?: string;
51620
53851
  };
@@ -52909,6 +55140,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
52909
55140
  order_number: string;
52910
55141
  }[];
52911
55142
  };
55143
+ autolink_product_to_floriday: {
55144
+ Args: {
55145
+ p_product_id: string;
55146
+ };
55147
+ Returns: string;
55148
+ };
52912
55149
  backfill_open_order_reservations: {
52913
55150
  Args: never;
52914
55151
  Returns: {
@@ -52947,6 +55184,18 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
52947
55184
  Args: never;
52948
55185
  Returns: number;
52949
55186
  };
55187
+ consume_floriday_rate_limit: {
55188
+ Args: {
55189
+ p_bucket: string;
55190
+ p_capacity: number;
55191
+ p_cost?: number;
55192
+ p_refill_per_sec: number;
55193
+ };
55194
+ Returns: {
55195
+ granted: boolean;
55196
+ wait_ms: number;
55197
+ }[];
55198
+ };
52950
55199
  control_get_todays_carts: {
52951
55200
  Args: never;
52952
55201
  Returns: {
@@ -53027,6 +55276,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53027
55276
  status: string;
53028
55277
  }[];
53029
55278
  };
55279
+ enqueue_cart_replan_if_unlocked: {
55280
+ Args: {
55281
+ p_order_id: string;
55282
+ };
55283
+ Returns: undefined;
55284
+ };
53030
55285
  ensure_trade_item_stock_row: {
53031
55286
  Args: {
53032
55287
  p_key: string;
@@ -53133,6 +55388,13 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53133
55388
  office_code: string;
53134
55389
  }[];
53135
55390
  };
55391
+ get_floricode_record_counts: {
55392
+ Args: never;
55393
+ Returns: {
55394
+ count: number;
55395
+ resource: string;
55396
+ }[];
55397
+ };
53136
55398
  get_floriday_agreements_active: {
53137
55399
  Args: {
53138
55400
  p_on_date?: string;
@@ -53224,6 +55486,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53224
55486
  };
53225
55487
  Returns: import("../integrations/supabase/types").Json;
53226
55488
  };
55489
+ get_offer_delivery_options: {
55490
+ Args: {
55491
+ p_code: string;
55492
+ };
55493
+ Returns: import("../integrations/supabase/types").Json;
55494
+ };
53227
55495
  get_offer_recipient_by_code: {
53228
55496
  Args: {
53229
55497
  p_code: string;
@@ -53288,6 +55556,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53288
55556
  Args: never;
53289
55557
  Returns: boolean;
53290
55558
  };
55559
+ is_superadmin: {
55560
+ Args: {
55561
+ _user_id: string;
55562
+ };
55563
+ Returns: boolean;
55564
+ };
53291
55565
  local_effective_price: {
53292
55566
  Args: {
53293
55567
  _customer_id: string;
@@ -53322,6 +55596,13 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53322
55596
  };
53323
55597
  Returns: string;
53324
55598
  };
55599
+ next_order_number_for_date: {
55600
+ Args: {
55601
+ p_created_at?: string;
55602
+ p_prefix: string;
55603
+ };
55604
+ Returns: string;
55605
+ };
53325
55606
  next_work_order_number: {
53326
55607
  Args: {
53327
55608
  p_parent_work_order_id?: string;
@@ -53329,6 +55610,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53329
55610
  };
53330
55611
  Returns: string;
53331
55612
  };
55613
+ normalize_order_source: {
55614
+ Args: {
55615
+ p_src: string;
55616
+ };
55617
+ Returns: string;
55618
+ };
53332
55619
  normalize_vat: {
53333
55620
  Args: {
53334
55621
  v: string;
@@ -53343,10 +55630,21 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53343
55630
  };
53344
55631
  Returns: boolean;
53345
55632
  };
55633
+ order_number_prefix: {
55634
+ Args: {
55635
+ p_custom_fields?: import("../integrations/supabase/types").Json;
55636
+ p_order_source: string;
55637
+ };
55638
+ Returns: string;
55639
+ };
53346
55640
  pickstation_get_orders_raw: {
53347
55641
  Args: never;
53348
55642
  Returns: import("../integrations/supabase/types").Json;
53349
55643
  };
55644
+ pickstation_get_planning_context: {
55645
+ Args: never;
55646
+ Returns: import("../integrations/supabase/types").Json;
55647
+ };
53350
55648
  pickstation_get_settings: {
53351
55649
  Args: never;
53352
55650
  Returns: import("../integrations/supabase/types").Json;
@@ -53377,6 +55675,28 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53377
55675
  };
53378
55676
  Returns: undefined;
53379
55677
  };
55678
+ recompute_order_status: {
55679
+ Args: {
55680
+ p_order_id: string;
55681
+ };
55682
+ Returns: undefined;
55683
+ };
55684
+ recompute_reserved_for_order: {
55685
+ Args: {
55686
+ p_order_id: string;
55687
+ };
55688
+ Returns: undefined;
55689
+ };
55690
+ recompute_reserved_stock: {
55691
+ Args: {
55692
+ p_trade_item_key: string;
55693
+ };
55694
+ Returns: undefined;
55695
+ };
55696
+ refresh_external_customers_grouped: {
55697
+ Args: never;
55698
+ Returns: undefined;
55699
+ };
53380
55700
  refresh_floricode_derived_code_lists: {
53381
55701
  Args: never;
53382
55702
  Returns: {
@@ -53391,6 +55711,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53391
55711
  };
53392
55712
  Returns: number;
53393
55713
  };
55714
+ refresh_floricode_derived_for_products: {
55715
+ Args: {
55716
+ _product_ids: string[];
55717
+ };
55718
+ Returns: number;
55719
+ };
53394
55720
  reset_floriday_sync_cursor: {
53395
55721
  Args: {
53396
55722
  p_connection_id: string;
@@ -53398,6 +55724,12 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53398
55724
  };
53399
55725
  Returns: undefined;
53400
55726
  };
55727
+ resolve_product_id_for_item: {
55728
+ Args: {
55729
+ p_product_name: string;
55730
+ };
55731
+ Returns: string;
55732
+ };
53401
55733
  schedule_floriday_additional_services_sync: {
53402
55734
  Args: {
53403
55735
  p_apikey: string;
@@ -53675,6 +56007,24 @@ export declare const upsertSupplyLine: import("@tanstack/start-client-core").Opt
53675
56007
  };
53676
56008
  Returns: string[];
53677
56009
  };
56010
+ sync_cached_packing_from_product: {
56011
+ Args: {
56012
+ p_product_id: string;
56013
+ };
56014
+ Returns: undefined;
56015
+ };
56016
+ sync_order_cart_item_packing_from_product: {
56017
+ Args: {
56018
+ p_product_id: string;
56019
+ };
56020
+ Returns: undefined;
56021
+ };
56022
+ sync_product_packing_from_floriday_cache: {
56023
+ Args: {
56024
+ p_floriday_id: string;
56025
+ };
56026
+ Returns: undefined;
56027
+ };
53678
56028
  twinfield_decrypt: {
53679
56029
  Args: {
53680
56030
  cipher: string;