@flowselections/logistiek-engine 1.0.5 → 1.0.7

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 (33) hide show
  1. package/dist-lib/components/LogistiekEnginePage.d.ts.map +1 -1
  2. package/dist-lib/components/LogistiekEnginePage.js +19 -4
  3. package/dist-lib/components/StrategieDialog.d.ts.map +1 -1
  4. package/dist-lib/components/StrategieDialog.js +1 -1
  5. package/dist-lib/hooks/useLogistiekStrategieen.d.ts +2 -1
  6. package/dist-lib/hooks/useLogistiekStrategieen.d.ts.map +1 -1
  7. package/dist-lib/hooks/useLogistiekStrategieen.js +72 -2
  8. package/dist-lib/integrations/supabase/auth-middleware.d.ts +396 -3
  9. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  10. package/dist-lib/integrations/supabase/client.d.ts +396 -3
  11. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  12. package/dist-lib/integrations/supabase/client.server.d.ts +396 -3
  13. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  14. package/dist-lib/integrations/supabase/types.d.ts +396 -3
  15. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  16. package/dist-lib/lib/floridayDocuments.functions.d.ts +1188 -9
  17. package/dist-lib/lib/floridayDocuments.functions.d.ts.map +1 -1
  18. package/dist-lib/lib/floridayPush.functions.d.ts +396 -3
  19. package/dist-lib/lib/floridayPush.functions.d.ts.map +1 -1
  20. package/dist-lib/lib/handlers/logistics-tick.server.d.ts.map +1 -1
  21. package/dist-lib/lib/handlers/logistics-tick.server.js +12 -1
  22. package/dist-lib/lib/loadCarrierPlanning.functions.d.ts +1980 -15
  23. package/dist-lib/lib/loadCarrierPlanning.functions.d.ts.map +1 -1
  24. package/dist-lib/lib/logisticsRecalcJob.functions.d.ts +792 -6
  25. package/dist-lib/lib/logisticsRecalcJob.functions.d.ts.map +1 -1
  26. package/dist-lib/lib/logisticsRecalculate.functions.d.ts +396 -3
  27. package/dist-lib/lib/logisticsRecalculate.functions.d.ts.map +1 -1
  28. package/dist-lib/lib/modulePrompts.d.ts.map +1 -1
  29. package/dist-lib/lib/modulePrompts.js +25 -0
  30. package/dist-lib/lib/planQueue.server.d.ts +17 -0
  31. package/dist-lib/lib/planQueue.server.d.ts.map +1 -0
  32. package/dist-lib/lib/planQueue.server.js +124 -0
  33. package/package.json +1 -1
@@ -1683,7 +1683,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
1683
1683
  city: string | null;
1684
1684
  country: string | null;
1685
1685
  created_at: string;
1686
- customer_id: string | null;
1686
+ customer_id: string;
1687
1687
  external_key: string | null;
1688
1688
  external_provider: string | null;
1689
1689
  floriday_location_id: string | null;
@@ -1707,7 +1707,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
1707
1707
  city?: string | null;
1708
1708
  country?: string | null;
1709
1709
  created_at?: string;
1710
- customer_id?: string | null;
1710
+ customer_id: string;
1711
1711
  external_key?: string | null;
1712
1712
  external_provider?: string | null;
1713
1713
  floriday_location_id?: string | null;
@@ -1731,7 +1731,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
1731
1731
  city?: string | null;
1732
1732
  country?: string | null;
1733
1733
  created_at?: string;
1734
- customer_id?: string | null;
1734
+ customer_id?: string;
1735
1735
  external_key?: string | null;
1736
1736
  external_provider?: string | null;
1737
1737
  floriday_location_id?: string | null;
@@ -6479,6 +6479,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
6479
6479
  Row: {
6480
6480
  buyer_organization_id: string | null;
6481
6481
  connection_id: string;
6482
+ controlled_at: string | null;
6482
6483
  created_at: string;
6483
6484
  data: import("../integrations/supabase/types").Json;
6484
6485
  floriday_id: string;
@@ -6490,6 +6491,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
6490
6491
  Insert: {
6491
6492
  buyer_organization_id?: string | null;
6492
6493
  connection_id: string;
6494
+ controlled_at?: string | null;
6493
6495
  created_at?: string;
6494
6496
  data: import("../integrations/supabase/types").Json;
6495
6497
  floriday_id: string;
@@ -6501,6 +6503,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
6501
6503
  Update: {
6502
6504
  buyer_organization_id?: string | null;
6503
6505
  connection_id?: string;
6506
+ controlled_at?: string | null;
6504
6507
  created_at?: string;
6505
6508
  data?: import("../integrations/supabase/types").Json;
6506
6509
  floriday_id?: string;
@@ -7402,6 +7405,54 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
7402
7405
  };
7403
7406
  Relationships: [];
7404
7407
  };
7408
+ invoice_timing_settings: {
7409
+ Row: {
7410
+ anchor: string;
7411
+ business_days_only: boolean;
7412
+ created_at: string;
7413
+ enabled: boolean;
7414
+ id: string;
7415
+ offset_days: number;
7416
+ pickup_anchor: string;
7417
+ pickup_business_days_only: boolean;
7418
+ pickup_offset_days: number;
7419
+ pickup_time_of_day: string;
7420
+ singleton: boolean;
7421
+ time_of_day: string;
7422
+ updated_at: string;
7423
+ };
7424
+ Insert: {
7425
+ anchor?: string;
7426
+ business_days_only?: boolean;
7427
+ created_at?: string;
7428
+ enabled?: boolean;
7429
+ id?: string;
7430
+ offset_days?: number;
7431
+ pickup_anchor?: string;
7432
+ pickup_business_days_only?: boolean;
7433
+ pickup_offset_days?: number;
7434
+ pickup_time_of_day?: string;
7435
+ singleton?: boolean;
7436
+ time_of_day?: string;
7437
+ updated_at?: string;
7438
+ };
7439
+ Update: {
7440
+ anchor?: string;
7441
+ business_days_only?: boolean;
7442
+ created_at?: string;
7443
+ enabled?: boolean;
7444
+ id?: string;
7445
+ offset_days?: number;
7446
+ pickup_anchor?: string;
7447
+ pickup_business_days_only?: boolean;
7448
+ pickup_offset_days?: number;
7449
+ pickup_time_of_day?: string;
7450
+ singleton?: boolean;
7451
+ time_of_day?: string;
7452
+ updated_at?: string;
7453
+ };
7454
+ Relationships: [];
7455
+ };
7405
7456
  itk_contact_persons: {
7406
7457
  Row: {
7407
7458
  created_at: string;
@@ -8632,6 +8683,45 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
8632
8683
  };
8633
8684
  Relationships: [];
8634
8685
  };
8686
+ logistics_plan_queue: {
8687
+ Row: {
8688
+ attempts: number;
8689
+ claimed_at: string | null;
8690
+ enqueued_at: string;
8691
+ error: string | null;
8692
+ id: string;
8693
+ next_attempt_at: string;
8694
+ order_id: string;
8695
+ reason: string;
8696
+ status: string;
8697
+ updated_at: string;
8698
+ };
8699
+ Insert: {
8700
+ attempts?: number;
8701
+ claimed_at?: string | null;
8702
+ enqueued_at?: string;
8703
+ error?: string | null;
8704
+ id?: string;
8705
+ next_attempt_at?: string;
8706
+ order_id: string;
8707
+ reason?: string;
8708
+ status?: string;
8709
+ updated_at?: string;
8710
+ };
8711
+ Update: {
8712
+ attempts?: number;
8713
+ claimed_at?: string | null;
8714
+ enqueued_at?: string;
8715
+ error?: string | null;
8716
+ id?: string;
8717
+ next_attempt_at?: string;
8718
+ order_id?: string;
8719
+ reason?: string;
8720
+ status?: string;
8721
+ updated_at?: string;
8722
+ };
8723
+ Relationships: [];
8724
+ };
8635
8725
  logistics_plan_runs: {
8636
8726
  Row: {
8637
8727
  created_at: string;
@@ -8707,6 +8797,24 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
8707
8797
  referencedColumns: ["id"];
8708
8798
  }];
8709
8799
  };
8800
+ logistics_plan_settings: {
8801
+ Row: {
8802
+ key: string;
8803
+ updated_at: string;
8804
+ value: string;
8805
+ };
8806
+ Insert: {
8807
+ key: string;
8808
+ updated_at?: string;
8809
+ value: string;
8810
+ };
8811
+ Update: {
8812
+ key?: string;
8813
+ updated_at?: string;
8814
+ value?: string;
8815
+ };
8816
+ Relationships: [];
8817
+ };
8710
8818
  logistics_rebuffer_state: {
8711
8819
  Row: {
8712
8820
  created_at: string;
@@ -9417,14 +9525,17 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
9417
9525
  };
9418
9526
  mailbox_messages: {
9419
9527
  Row: {
9528
+ attachments: import("../integrations/supabase/types").Json;
9420
9529
  body_html: string | null;
9421
9530
  body_text: string | null;
9531
+ cc_recipients: import("../integrations/supabase/types").Json;
9422
9532
  connection_id: string | null;
9423
9533
  created_at: string;
9424
9534
  error_message: string | null;
9425
9535
  external_id: string | null;
9426
9536
  from_email: string | null;
9427
9537
  from_name: string | null;
9538
+ has_attachments: boolean;
9428
9539
  id: string;
9429
9540
  message_id: string | null;
9430
9541
  profile_id: string | null;
@@ -9432,18 +9543,22 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
9432
9543
  received_at: string | null;
9433
9544
  status: string;
9434
9545
  subject: string | null;
9546
+ to_recipients: import("../integrations/supabase/types").Json;
9435
9547
  uid: number | null;
9436
9548
  updated_at: string;
9437
9549
  };
9438
9550
  Insert: {
9551
+ attachments?: import("../integrations/supabase/types").Json;
9439
9552
  body_html?: string | null;
9440
9553
  body_text?: string | null;
9554
+ cc_recipients?: import("../integrations/supabase/types").Json;
9441
9555
  connection_id?: string | null;
9442
9556
  created_at?: string;
9443
9557
  error_message?: string | null;
9444
9558
  external_id?: string | null;
9445
9559
  from_email?: string | null;
9446
9560
  from_name?: string | null;
9561
+ has_attachments?: boolean;
9447
9562
  id?: string;
9448
9563
  message_id?: string | null;
9449
9564
  profile_id?: string | null;
@@ -9451,18 +9566,22 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
9451
9566
  received_at?: string | null;
9452
9567
  status?: string;
9453
9568
  subject?: string | null;
9569
+ to_recipients?: import("../integrations/supabase/types").Json;
9454
9570
  uid?: number | null;
9455
9571
  updated_at?: string;
9456
9572
  };
9457
9573
  Update: {
9574
+ attachments?: import("../integrations/supabase/types").Json;
9458
9575
  body_html?: string | null;
9459
9576
  body_text?: string | null;
9577
+ cc_recipients?: import("../integrations/supabase/types").Json;
9460
9578
  connection_id?: string | null;
9461
9579
  created_at?: string;
9462
9580
  error_message?: string | null;
9463
9581
  external_id?: string | null;
9464
9582
  from_email?: string | null;
9465
9583
  from_name?: string | null;
9584
+ has_attachments?: boolean;
9466
9585
  id?: string;
9467
9586
  message_id?: string | null;
9468
9587
  profile_id?: string | null;
@@ -9470,6 +9589,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
9470
9589
  received_at?: string | null;
9471
9590
  status?: string;
9472
9591
  subject?: string | null;
9592
+ to_recipients?: import("../integrations/supabase/types").Json;
9473
9593
  uid?: number | null;
9474
9594
  updated_at?: string;
9475
9595
  };
@@ -9877,6 +9997,36 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
9877
9997
  };
9878
9998
  Relationships: [];
9879
9999
  };
10000
+ module_registry: {
10001
+ Row: {
10002
+ created_at: string;
10003
+ is_active: boolean;
10004
+ last_seen_at: string;
10005
+ module_id: string;
10006
+ name: string;
10007
+ shell_id: string | null;
10008
+ sort_order: number | null;
10009
+ };
10010
+ Insert: {
10011
+ created_at?: string;
10012
+ is_active?: boolean;
10013
+ last_seen_at?: string;
10014
+ module_id: string;
10015
+ name: string;
10016
+ shell_id?: string | null;
10017
+ sort_order?: number | null;
10018
+ };
10019
+ Update: {
10020
+ created_at?: string;
10021
+ is_active?: boolean;
10022
+ last_seen_at?: string;
10023
+ module_id?: string;
10024
+ name?: string;
10025
+ shell_id?: string | null;
10026
+ sort_order?: number | null;
10027
+ };
10028
+ Relationships: [];
10029
+ };
9880
10030
  module_runtime_config: {
9881
10031
  Row: {
9882
10032
  key: string;
@@ -10936,6 +11086,45 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
10936
11086
  };
10937
11087
  Relationships: [];
10938
11088
  };
11089
+ order_invoice_links: {
11090
+ Row: {
11091
+ attempts: number;
11092
+ created_at: string;
11093
+ error_message: string | null;
11094
+ id: string;
11095
+ invoice_number: string | null;
11096
+ next_attempt_at: string;
11097
+ order_id: string;
11098
+ processed_at: string | null;
11099
+ status: string;
11100
+ updated_at: string;
11101
+ };
11102
+ Insert: {
11103
+ attempts?: number;
11104
+ created_at?: string;
11105
+ error_message?: string | null;
11106
+ id?: string;
11107
+ invoice_number?: string | null;
11108
+ next_attempt_at?: string;
11109
+ order_id: string;
11110
+ processed_at?: string | null;
11111
+ status?: string;
11112
+ updated_at?: string;
11113
+ };
11114
+ Update: {
11115
+ attempts?: number;
11116
+ created_at?: string;
11117
+ error_message?: string | null;
11118
+ id?: string;
11119
+ invoice_number?: string | null;
11120
+ next_attempt_at?: string;
11121
+ order_id?: string;
11122
+ processed_at?: string | null;
11123
+ status?: string;
11124
+ updated_at?: string;
11125
+ };
11126
+ Relationships: [];
11127
+ };
10939
11128
  order_items: {
10940
11129
  Row: {
10941
11130
  crates_per_layer: number | null;
@@ -11118,6 +11307,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
11118
11307
  delivery_date: string | null;
11119
11308
  floriday_sales_order_id: string | null;
11120
11309
  id: string;
11310
+ invoice_due_at: string | null;
11121
11311
  is_reservation: boolean;
11122
11312
  notes: string | null;
11123
11313
  order_date: string;
@@ -11139,6 +11329,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
11139
11329
  delivery_date?: string | null;
11140
11330
  floriday_sales_order_id?: string | null;
11141
11331
  id?: string;
11332
+ invoice_due_at?: string | null;
11142
11333
  is_reservation?: boolean;
11143
11334
  notes?: string | null;
11144
11335
  order_date?: string;
@@ -11160,6 +11351,7 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
11160
11351
  delivery_date?: string | null;
11161
11352
  floriday_sales_order_id?: string | null;
11162
11353
  id?: string;
11354
+ invoice_due_at?: string | null;
11163
11355
  is_reservation?: boolean;
11164
11356
  notes?: string | null;
11165
11357
  order_date?: string;
@@ -12457,6 +12649,63 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
12457
12649
  referencedColumns: ["id"];
12458
12650
  }];
12459
12651
  };
12652
+ print_queue_runners: {
12653
+ Row: {
12654
+ actief: boolean;
12655
+ basis_url: string;
12656
+ created_at: string;
12657
+ id: string;
12658
+ laatst_gezien: string;
12659
+ tick_sleutel: string;
12660
+ updated_at: string;
12661
+ };
12662
+ Insert: {
12663
+ actief?: boolean;
12664
+ basis_url: string;
12665
+ created_at?: string;
12666
+ id?: string;
12667
+ laatst_gezien?: string;
12668
+ tick_sleutel?: string;
12669
+ updated_at?: string;
12670
+ };
12671
+ Update: {
12672
+ actief?: boolean;
12673
+ basis_url?: string;
12674
+ created_at?: string;
12675
+ id?: string;
12676
+ laatst_gezien?: string;
12677
+ tick_sleutel?: string;
12678
+ updated_at?: string;
12679
+ };
12680
+ Relationships: [];
12681
+ };
12682
+ print_queue_settings: {
12683
+ Row: {
12684
+ bewaar_bestanden_dagen: number;
12685
+ bewaar_opdrachten_dagen: number;
12686
+ created_at: string;
12687
+ dubbel_venster_minuten: number;
12688
+ id: string;
12689
+ updated_at: string;
12690
+ };
12691
+ Insert: {
12692
+ bewaar_bestanden_dagen?: number;
12693
+ bewaar_opdrachten_dagen?: number;
12694
+ created_at?: string;
12695
+ dubbel_venster_minuten?: number;
12696
+ id?: string;
12697
+ updated_at?: string;
12698
+ };
12699
+ Update: {
12700
+ bewaar_bestanden_dagen?: number;
12701
+ bewaar_opdrachten_dagen?: number;
12702
+ created_at?: string;
12703
+ dubbel_venster_minuten?: number;
12704
+ id?: string;
12705
+ updated_at?: string;
12706
+ };
12707
+ Relationships: [];
12708
+ };
12460
12709
  print_rules: {
12461
12710
  Row: {
12462
12711
  actief: boolean;
@@ -15297,6 +15546,8 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
15297
15546
  };
15298
15547
  twinfield_invoice_settings: {
15299
15548
  Row: {
15549
+ auto_invoice_enabled: boolean;
15550
+ auto_invoice_trigger_statuses: string[];
15300
15551
  created_at: string;
15301
15552
  debtor_gl_account: string;
15302
15553
  default_credit_invoice_type: string | null;
@@ -15317,6 +15568,8 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
15317
15568
  vat_code_export: string | null;
15318
15569
  };
15319
15570
  Insert: {
15571
+ auto_invoice_enabled?: boolean;
15572
+ auto_invoice_trigger_statuses?: string[];
15320
15573
  created_at?: string;
15321
15574
  debtor_gl_account?: string;
15322
15575
  default_credit_invoice_type?: string | null;
@@ -15337,6 +15590,8 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
15337
15590
  vat_code_export?: string | null;
15338
15591
  };
15339
15592
  Update: {
15593
+ auto_invoice_enabled?: boolean;
15594
+ auto_invoice_trigger_statuses?: string[];
15340
15595
  created_at?: string;
15341
15596
  debtor_gl_account?: string;
15342
15597
  default_credit_invoice_type?: string | null;
@@ -16399,6 +16654,33 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
16399
16654
  referencedColumns: ["id"];
16400
16655
  }];
16401
16656
  };
16657
+ user_module_permissions: {
16658
+ Row: {
16659
+ created_at: string;
16660
+ id: string;
16661
+ module_id: string;
16662
+ permission: string;
16663
+ updated_at: string;
16664
+ user_id: string;
16665
+ };
16666
+ Insert: {
16667
+ created_at?: string;
16668
+ id?: string;
16669
+ module_id: string;
16670
+ permission: string;
16671
+ updated_at?: string;
16672
+ user_id: string;
16673
+ };
16674
+ Update: {
16675
+ created_at?: string;
16676
+ id?: string;
16677
+ module_id?: string;
16678
+ permission?: string;
16679
+ updated_at?: string;
16680
+ user_id?: string;
16681
+ };
16682
+ Relationships: [];
16683
+ };
16402
16684
  user_roles: {
16403
16685
  Row: {
16404
16686
  created_at: string;
@@ -18232,6 +18514,10 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
18232
18514
  processed_items: number;
18233
18515
  }[];
18234
18516
  };
18517
+ backfill_order_auto_invoice_queue: {
18518
+ Args: never;
18519
+ Returns: number;
18520
+ };
18235
18521
  calculate_layer_stock: {
18236
18522
  Args: {
18237
18523
  p_product_id: string;
@@ -18462,6 +18748,10 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
18462
18748
  Args: never;
18463
18749
  Returns: undefined;
18464
18750
  };
18751
+ cleanup_voorraad_module_history: {
18752
+ Args: never;
18753
+ Returns: undefined;
18754
+ };
18465
18755
  complete_floriday_stock_queue: {
18466
18756
  Args: {
18467
18757
  p_attempt_id?: string;
@@ -18583,6 +18873,13 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
18583
18873
  };
18584
18874
  Returns: import("../integrations/supabase/types").Json;
18585
18875
  };
18876
+ effective_module_permission: {
18877
+ Args: {
18878
+ _module_id: string;
18879
+ _user_id: string;
18880
+ };
18881
+ Returns: string;
18882
+ };
18586
18883
  email_auth_decrypt: {
18587
18884
  Args: {
18588
18885
  cipher: string;
@@ -19483,6 +19780,65 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
19483
19780
  };
19484
19781
  Returns: number;
19485
19782
  };
19783
+ logistics_plan_claim: {
19784
+ Args: {
19785
+ p_limit?: number;
19786
+ };
19787
+ Returns: {
19788
+ attempts: number;
19789
+ id: string;
19790
+ order_id: string;
19791
+ }[];
19792
+ };
19793
+ logistics_plan_enqueue: {
19794
+ Args: {
19795
+ p_order_id: string;
19796
+ p_reason?: string;
19797
+ };
19798
+ Returns: undefined;
19799
+ };
19800
+ logistics_plan_ensure_event: {
19801
+ Args: {
19802
+ p_order_id: string;
19803
+ };
19804
+ Returns: boolean;
19805
+ };
19806
+ logistics_plan_finish: {
19807
+ Args: {
19808
+ p_error?: string;
19809
+ p_id: string;
19810
+ };
19811
+ Returns: undefined;
19812
+ };
19813
+ logistics_plan_impact_orders: {
19814
+ Args: {
19815
+ p_order_id: string;
19816
+ };
19817
+ Returns: {
19818
+ buffer_id: string;
19819
+ order_id: string;
19820
+ plan_date: string;
19821
+ }[];
19822
+ };
19823
+ logistics_plan_kick: {
19824
+ Args: never;
19825
+ Returns: undefined;
19826
+ };
19827
+ logistics_plan_prune: {
19828
+ Args: never;
19829
+ Returns: number;
19830
+ };
19831
+ logistics_plan_release_stale: {
19832
+ Args: never;
19833
+ Returns: number;
19834
+ };
19835
+ logistics_plan_setting: {
19836
+ Args: {
19837
+ p_default: number;
19838
+ p_key: string;
19839
+ };
19840
+ Returns: number;
19841
+ };
19486
19842
  logistics_queue_capacity_email: {
19487
19843
  Args: {
19488
19844
  p_alert_id: string;
@@ -19721,6 +20077,13 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
19721
20077
  };
19722
20078
  Returns: undefined;
19723
20079
  };
20080
+ my_module_permissions: {
20081
+ Args: never;
20082
+ Returns: {
20083
+ module_id: string;
20084
+ permission: string;
20085
+ }[];
20086
+ };
19724
20087
  next_manufacture_partij: {
19725
20088
  Args: {
19726
20089
  _tenant_id: string;
@@ -19771,6 +20134,13 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
19771
20134
  };
19772
20135
  Returns: boolean;
19773
20136
  };
20137
+ opruim_print_historie: {
20138
+ Args: never;
20139
+ Returns: {
20140
+ ontdaan: number;
20141
+ verwijderd: number;
20142
+ }[];
20143
+ };
19774
20144
  order_number_prefix: {
19775
20145
  Args: {
19776
20146
  p_custom_fields?: import("../integrations/supabase/types").Json;
@@ -20165,6 +20535,12 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
20165
20535
  };
20166
20536
  Returns: undefined;
20167
20537
  };
20538
+ reset_stalled_floriday_stock_queue: {
20539
+ Args: {
20540
+ p_include_failed?: boolean;
20541
+ };
20542
+ Returns: number;
20543
+ };
20168
20544
  resolve_group_allocation: {
20169
20545
  Args: {
20170
20546
  _needed: number;
@@ -20219,10 +20595,18 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
20219
20595
  Args: never;
20220
20596
  Returns: undefined;
20221
20597
  };
20598
+ run_floriday_stock_queue_process: {
20599
+ Args: never;
20600
+ Returns: undefined;
20601
+ };
20222
20602
  run_logistics_tasks_dispatch: {
20223
20603
  Args: never;
20224
20604
  Returns: undefined;
20225
20605
  };
20606
+ run_print_queue_ticks: {
20607
+ Args: never;
20608
+ Returns: number;
20609
+ };
20226
20610
  run_twinfield_queue_tick: {
20227
20611
  Args: never;
20228
20612
  Returns: undefined;
@@ -20610,6 +20994,15 @@ export declare const replanOrderLoadCarriers: import("@tanstack/start-client-cor
20610
20994
  };
20611
20995
  Returns: undefined;
20612
20996
  };
20997
+ trade_item_stock_duplicates: {
20998
+ Args: never;
20999
+ Returns: {
21000
+ keys: string[];
21001
+ product_id: string;
21002
+ product_name: string;
21003
+ row_count: number;
21004
+ }[];
21005
+ };
20613
21006
  try_debtor_lock: {
20614
21007
  Args: {
20615
21008
  _group_key: string;
@@ -22372,7 +22765,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
22372
22765
  city: string | null;
22373
22766
  country: string | null;
22374
22767
  created_at: string;
22375
- customer_id: string | null;
22768
+ customer_id: string;
22376
22769
  external_key: string | null;
22377
22770
  external_provider: string | null;
22378
22771
  floriday_location_id: string | null;
@@ -22396,7 +22789,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
22396
22789
  city?: string | null;
22397
22790
  country?: string | null;
22398
22791
  created_at?: string;
22399
- customer_id?: string | null;
22792
+ customer_id: string;
22400
22793
  external_key?: string | null;
22401
22794
  external_provider?: string | null;
22402
22795
  floriday_location_id?: string | null;
@@ -22420,7 +22813,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
22420
22813
  city?: string | null;
22421
22814
  country?: string | null;
22422
22815
  created_at?: string;
22423
- customer_id?: string | null;
22816
+ customer_id?: string;
22424
22817
  external_key?: string | null;
22425
22818
  external_provider?: string | null;
22426
22819
  floriday_location_id?: string | null;
@@ -27168,6 +27561,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
27168
27561
  Row: {
27169
27562
  buyer_organization_id: string | null;
27170
27563
  connection_id: string;
27564
+ controlled_at: string | null;
27171
27565
  created_at: string;
27172
27566
  data: import("../integrations/supabase/types").Json;
27173
27567
  floriday_id: string;
@@ -27179,6 +27573,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
27179
27573
  Insert: {
27180
27574
  buyer_organization_id?: string | null;
27181
27575
  connection_id: string;
27576
+ controlled_at?: string | null;
27182
27577
  created_at?: string;
27183
27578
  data: import("../integrations/supabase/types").Json;
27184
27579
  floriday_id: string;
@@ -27190,6 +27585,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
27190
27585
  Update: {
27191
27586
  buyer_organization_id?: string | null;
27192
27587
  connection_id?: string;
27588
+ controlled_at?: string | null;
27193
27589
  created_at?: string;
27194
27590
  data?: import("../integrations/supabase/types").Json;
27195
27591
  floriday_id?: string;
@@ -28091,6 +28487,54 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
28091
28487
  };
28092
28488
  Relationships: [];
28093
28489
  };
28490
+ invoice_timing_settings: {
28491
+ Row: {
28492
+ anchor: string;
28493
+ business_days_only: boolean;
28494
+ created_at: string;
28495
+ enabled: boolean;
28496
+ id: string;
28497
+ offset_days: number;
28498
+ pickup_anchor: string;
28499
+ pickup_business_days_only: boolean;
28500
+ pickup_offset_days: number;
28501
+ pickup_time_of_day: string;
28502
+ singleton: boolean;
28503
+ time_of_day: string;
28504
+ updated_at: string;
28505
+ };
28506
+ Insert: {
28507
+ anchor?: string;
28508
+ business_days_only?: boolean;
28509
+ created_at?: string;
28510
+ enabled?: boolean;
28511
+ id?: string;
28512
+ offset_days?: number;
28513
+ pickup_anchor?: string;
28514
+ pickup_business_days_only?: boolean;
28515
+ pickup_offset_days?: number;
28516
+ pickup_time_of_day?: string;
28517
+ singleton?: boolean;
28518
+ time_of_day?: string;
28519
+ updated_at?: string;
28520
+ };
28521
+ Update: {
28522
+ anchor?: string;
28523
+ business_days_only?: boolean;
28524
+ created_at?: string;
28525
+ enabled?: boolean;
28526
+ id?: string;
28527
+ offset_days?: number;
28528
+ pickup_anchor?: string;
28529
+ pickup_business_days_only?: boolean;
28530
+ pickup_offset_days?: number;
28531
+ pickup_time_of_day?: string;
28532
+ singleton?: boolean;
28533
+ time_of_day?: string;
28534
+ updated_at?: string;
28535
+ };
28536
+ Relationships: [];
28537
+ };
28094
28538
  itk_contact_persons: {
28095
28539
  Row: {
28096
28540
  created_at: string;
@@ -29321,6 +29765,45 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
29321
29765
  };
29322
29766
  Relationships: [];
29323
29767
  };
29768
+ logistics_plan_queue: {
29769
+ Row: {
29770
+ attempts: number;
29771
+ claimed_at: string | null;
29772
+ enqueued_at: string;
29773
+ error: string | null;
29774
+ id: string;
29775
+ next_attempt_at: string;
29776
+ order_id: string;
29777
+ reason: string;
29778
+ status: string;
29779
+ updated_at: string;
29780
+ };
29781
+ Insert: {
29782
+ attempts?: number;
29783
+ claimed_at?: string | null;
29784
+ enqueued_at?: string;
29785
+ error?: string | null;
29786
+ id?: string;
29787
+ next_attempt_at?: string;
29788
+ order_id: string;
29789
+ reason?: string;
29790
+ status?: string;
29791
+ updated_at?: string;
29792
+ };
29793
+ Update: {
29794
+ attempts?: number;
29795
+ claimed_at?: string | null;
29796
+ enqueued_at?: string;
29797
+ error?: string | null;
29798
+ id?: string;
29799
+ next_attempt_at?: string;
29800
+ order_id?: string;
29801
+ reason?: string;
29802
+ status?: string;
29803
+ updated_at?: string;
29804
+ };
29805
+ Relationships: [];
29806
+ };
29324
29807
  logistics_plan_runs: {
29325
29808
  Row: {
29326
29809
  created_at: string;
@@ -29396,6 +29879,24 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
29396
29879
  referencedColumns: ["id"];
29397
29880
  }];
29398
29881
  };
29882
+ logistics_plan_settings: {
29883
+ Row: {
29884
+ key: string;
29885
+ updated_at: string;
29886
+ value: string;
29887
+ };
29888
+ Insert: {
29889
+ key: string;
29890
+ updated_at?: string;
29891
+ value: string;
29892
+ };
29893
+ Update: {
29894
+ key?: string;
29895
+ updated_at?: string;
29896
+ value?: string;
29897
+ };
29898
+ Relationships: [];
29899
+ };
29399
29900
  logistics_rebuffer_state: {
29400
29901
  Row: {
29401
29902
  created_at: string;
@@ -30106,14 +30607,17 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
30106
30607
  };
30107
30608
  mailbox_messages: {
30108
30609
  Row: {
30610
+ attachments: import("../integrations/supabase/types").Json;
30109
30611
  body_html: string | null;
30110
30612
  body_text: string | null;
30613
+ cc_recipients: import("../integrations/supabase/types").Json;
30111
30614
  connection_id: string | null;
30112
30615
  created_at: string;
30113
30616
  error_message: string | null;
30114
30617
  external_id: string | null;
30115
30618
  from_email: string | null;
30116
30619
  from_name: string | null;
30620
+ has_attachments: boolean;
30117
30621
  id: string;
30118
30622
  message_id: string | null;
30119
30623
  profile_id: string | null;
@@ -30121,18 +30625,22 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
30121
30625
  received_at: string | null;
30122
30626
  status: string;
30123
30627
  subject: string | null;
30628
+ to_recipients: import("../integrations/supabase/types").Json;
30124
30629
  uid: number | null;
30125
30630
  updated_at: string;
30126
30631
  };
30127
30632
  Insert: {
30633
+ attachments?: import("../integrations/supabase/types").Json;
30128
30634
  body_html?: string | null;
30129
30635
  body_text?: string | null;
30636
+ cc_recipients?: import("../integrations/supabase/types").Json;
30130
30637
  connection_id?: string | null;
30131
30638
  created_at?: string;
30132
30639
  error_message?: string | null;
30133
30640
  external_id?: string | null;
30134
30641
  from_email?: string | null;
30135
30642
  from_name?: string | null;
30643
+ has_attachments?: boolean;
30136
30644
  id?: string;
30137
30645
  message_id?: string | null;
30138
30646
  profile_id?: string | null;
@@ -30140,18 +30648,22 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
30140
30648
  received_at?: string | null;
30141
30649
  status?: string;
30142
30650
  subject?: string | null;
30651
+ to_recipients?: import("../integrations/supabase/types").Json;
30143
30652
  uid?: number | null;
30144
30653
  updated_at?: string;
30145
30654
  };
30146
30655
  Update: {
30656
+ attachments?: import("../integrations/supabase/types").Json;
30147
30657
  body_html?: string | null;
30148
30658
  body_text?: string | null;
30659
+ cc_recipients?: import("../integrations/supabase/types").Json;
30149
30660
  connection_id?: string | null;
30150
30661
  created_at?: string;
30151
30662
  error_message?: string | null;
30152
30663
  external_id?: string | null;
30153
30664
  from_email?: string | null;
30154
30665
  from_name?: string | null;
30666
+ has_attachments?: boolean;
30155
30667
  id?: string;
30156
30668
  message_id?: string | null;
30157
30669
  profile_id?: string | null;
@@ -30159,6 +30671,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
30159
30671
  received_at?: string | null;
30160
30672
  status?: string;
30161
30673
  subject?: string | null;
30674
+ to_recipients?: import("../integrations/supabase/types").Json;
30162
30675
  uid?: number | null;
30163
30676
  updated_at?: string;
30164
30677
  };
@@ -30566,6 +31079,36 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
30566
31079
  };
30567
31080
  Relationships: [];
30568
31081
  };
31082
+ module_registry: {
31083
+ Row: {
31084
+ created_at: string;
31085
+ is_active: boolean;
31086
+ last_seen_at: string;
31087
+ module_id: string;
31088
+ name: string;
31089
+ shell_id: string | null;
31090
+ sort_order: number | null;
31091
+ };
31092
+ Insert: {
31093
+ created_at?: string;
31094
+ is_active?: boolean;
31095
+ last_seen_at?: string;
31096
+ module_id: string;
31097
+ name: string;
31098
+ shell_id?: string | null;
31099
+ sort_order?: number | null;
31100
+ };
31101
+ Update: {
31102
+ created_at?: string;
31103
+ is_active?: boolean;
31104
+ last_seen_at?: string;
31105
+ module_id?: string;
31106
+ name?: string;
31107
+ shell_id?: string | null;
31108
+ sort_order?: number | null;
31109
+ };
31110
+ Relationships: [];
31111
+ };
30569
31112
  module_runtime_config: {
30570
31113
  Row: {
30571
31114
  key: string;
@@ -31625,6 +32168,45 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
31625
32168
  };
31626
32169
  Relationships: [];
31627
32170
  };
32171
+ order_invoice_links: {
32172
+ Row: {
32173
+ attempts: number;
32174
+ created_at: string;
32175
+ error_message: string | null;
32176
+ id: string;
32177
+ invoice_number: string | null;
32178
+ next_attempt_at: string;
32179
+ order_id: string;
32180
+ processed_at: string | null;
32181
+ status: string;
32182
+ updated_at: string;
32183
+ };
32184
+ Insert: {
32185
+ attempts?: number;
32186
+ created_at?: string;
32187
+ error_message?: string | null;
32188
+ id?: string;
32189
+ invoice_number?: string | null;
32190
+ next_attempt_at?: string;
32191
+ order_id: string;
32192
+ processed_at?: string | null;
32193
+ status?: string;
32194
+ updated_at?: string;
32195
+ };
32196
+ Update: {
32197
+ attempts?: number;
32198
+ created_at?: string;
32199
+ error_message?: string | null;
32200
+ id?: string;
32201
+ invoice_number?: string | null;
32202
+ next_attempt_at?: string;
32203
+ order_id?: string;
32204
+ processed_at?: string | null;
32205
+ status?: string;
32206
+ updated_at?: string;
32207
+ };
32208
+ Relationships: [];
32209
+ };
31628
32210
  order_items: {
31629
32211
  Row: {
31630
32212
  crates_per_layer: number | null;
@@ -31807,6 +32389,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
31807
32389
  delivery_date: string | null;
31808
32390
  floriday_sales_order_id: string | null;
31809
32391
  id: string;
32392
+ invoice_due_at: string | null;
31810
32393
  is_reservation: boolean;
31811
32394
  notes: string | null;
31812
32395
  order_date: string;
@@ -31828,6 +32411,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
31828
32411
  delivery_date?: string | null;
31829
32412
  floriday_sales_order_id?: string | null;
31830
32413
  id?: string;
32414
+ invoice_due_at?: string | null;
31831
32415
  is_reservation?: boolean;
31832
32416
  notes?: string | null;
31833
32417
  order_date?: string;
@@ -31849,6 +32433,7 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
31849
32433
  delivery_date?: string | null;
31850
32434
  floriday_sales_order_id?: string | null;
31851
32435
  id?: string;
32436
+ invoice_due_at?: string | null;
31852
32437
  is_reservation?: boolean;
31853
32438
  notes?: string | null;
31854
32439
  order_date?: string;
@@ -33146,6 +33731,63 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
33146
33731
  referencedColumns: ["id"];
33147
33732
  }];
33148
33733
  };
33734
+ print_queue_runners: {
33735
+ Row: {
33736
+ actief: boolean;
33737
+ basis_url: string;
33738
+ created_at: string;
33739
+ id: string;
33740
+ laatst_gezien: string;
33741
+ tick_sleutel: string;
33742
+ updated_at: string;
33743
+ };
33744
+ Insert: {
33745
+ actief?: boolean;
33746
+ basis_url: string;
33747
+ created_at?: string;
33748
+ id?: string;
33749
+ laatst_gezien?: string;
33750
+ tick_sleutel?: string;
33751
+ updated_at?: string;
33752
+ };
33753
+ Update: {
33754
+ actief?: boolean;
33755
+ basis_url?: string;
33756
+ created_at?: string;
33757
+ id?: string;
33758
+ laatst_gezien?: string;
33759
+ tick_sleutel?: string;
33760
+ updated_at?: string;
33761
+ };
33762
+ Relationships: [];
33763
+ };
33764
+ print_queue_settings: {
33765
+ Row: {
33766
+ bewaar_bestanden_dagen: number;
33767
+ bewaar_opdrachten_dagen: number;
33768
+ created_at: string;
33769
+ dubbel_venster_minuten: number;
33770
+ id: string;
33771
+ updated_at: string;
33772
+ };
33773
+ Insert: {
33774
+ bewaar_bestanden_dagen?: number;
33775
+ bewaar_opdrachten_dagen?: number;
33776
+ created_at?: string;
33777
+ dubbel_venster_minuten?: number;
33778
+ id?: string;
33779
+ updated_at?: string;
33780
+ };
33781
+ Update: {
33782
+ bewaar_bestanden_dagen?: number;
33783
+ bewaar_opdrachten_dagen?: number;
33784
+ created_at?: string;
33785
+ dubbel_venster_minuten?: number;
33786
+ id?: string;
33787
+ updated_at?: string;
33788
+ };
33789
+ Relationships: [];
33790
+ };
33149
33791
  print_rules: {
33150
33792
  Row: {
33151
33793
  actief: boolean;
@@ -35986,6 +36628,8 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
35986
36628
  };
35987
36629
  twinfield_invoice_settings: {
35988
36630
  Row: {
36631
+ auto_invoice_enabled: boolean;
36632
+ auto_invoice_trigger_statuses: string[];
35989
36633
  created_at: string;
35990
36634
  debtor_gl_account: string;
35991
36635
  default_credit_invoice_type: string | null;
@@ -36006,6 +36650,8 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
36006
36650
  vat_code_export: string | null;
36007
36651
  };
36008
36652
  Insert: {
36653
+ auto_invoice_enabled?: boolean;
36654
+ auto_invoice_trigger_statuses?: string[];
36009
36655
  created_at?: string;
36010
36656
  debtor_gl_account?: string;
36011
36657
  default_credit_invoice_type?: string | null;
@@ -36026,6 +36672,8 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
36026
36672
  vat_code_export?: string | null;
36027
36673
  };
36028
36674
  Update: {
36675
+ auto_invoice_enabled?: boolean;
36676
+ auto_invoice_trigger_statuses?: string[];
36029
36677
  created_at?: string;
36030
36678
  debtor_gl_account?: string;
36031
36679
  default_credit_invoice_type?: string | null;
@@ -37088,6 +37736,33 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
37088
37736
  referencedColumns: ["id"];
37089
37737
  }];
37090
37738
  };
37739
+ user_module_permissions: {
37740
+ Row: {
37741
+ created_at: string;
37742
+ id: string;
37743
+ module_id: string;
37744
+ permission: string;
37745
+ updated_at: string;
37746
+ user_id: string;
37747
+ };
37748
+ Insert: {
37749
+ created_at?: string;
37750
+ id?: string;
37751
+ module_id: string;
37752
+ permission: string;
37753
+ updated_at?: string;
37754
+ user_id: string;
37755
+ };
37756
+ Update: {
37757
+ created_at?: string;
37758
+ id?: string;
37759
+ module_id?: string;
37760
+ permission?: string;
37761
+ updated_at?: string;
37762
+ user_id?: string;
37763
+ };
37764
+ Relationships: [];
37765
+ };
37091
37766
  user_roles: {
37092
37767
  Row: {
37093
37768
  created_at: string;
@@ -38921,6 +39596,10 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
38921
39596
  processed_items: number;
38922
39597
  }[];
38923
39598
  };
39599
+ backfill_order_auto_invoice_queue: {
39600
+ Args: never;
39601
+ Returns: number;
39602
+ };
38924
39603
  calculate_layer_stock: {
38925
39604
  Args: {
38926
39605
  p_product_id: string;
@@ -39151,6 +39830,10 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
39151
39830
  Args: never;
39152
39831
  Returns: undefined;
39153
39832
  };
39833
+ cleanup_voorraad_module_history: {
39834
+ Args: never;
39835
+ Returns: undefined;
39836
+ };
39154
39837
  complete_floriday_stock_queue: {
39155
39838
  Args: {
39156
39839
  p_attempt_id?: string;
@@ -39272,6 +39955,13 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
39272
39955
  };
39273
39956
  Returns: import("../integrations/supabase/types").Json;
39274
39957
  };
39958
+ effective_module_permission: {
39959
+ Args: {
39960
+ _module_id: string;
39961
+ _user_id: string;
39962
+ };
39963
+ Returns: string;
39964
+ };
39275
39965
  email_auth_decrypt: {
39276
39966
  Args: {
39277
39967
  cipher: string;
@@ -40172,6 +40862,65 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
40172
40862
  };
40173
40863
  Returns: number;
40174
40864
  };
40865
+ logistics_plan_claim: {
40866
+ Args: {
40867
+ p_limit?: number;
40868
+ };
40869
+ Returns: {
40870
+ attempts: number;
40871
+ id: string;
40872
+ order_id: string;
40873
+ }[];
40874
+ };
40875
+ logistics_plan_enqueue: {
40876
+ Args: {
40877
+ p_order_id: string;
40878
+ p_reason?: string;
40879
+ };
40880
+ Returns: undefined;
40881
+ };
40882
+ logistics_plan_ensure_event: {
40883
+ Args: {
40884
+ p_order_id: string;
40885
+ };
40886
+ Returns: boolean;
40887
+ };
40888
+ logistics_plan_finish: {
40889
+ Args: {
40890
+ p_error?: string;
40891
+ p_id: string;
40892
+ };
40893
+ Returns: undefined;
40894
+ };
40895
+ logistics_plan_impact_orders: {
40896
+ Args: {
40897
+ p_order_id: string;
40898
+ };
40899
+ Returns: {
40900
+ buffer_id: string;
40901
+ order_id: string;
40902
+ plan_date: string;
40903
+ }[];
40904
+ };
40905
+ logistics_plan_kick: {
40906
+ Args: never;
40907
+ Returns: undefined;
40908
+ };
40909
+ logistics_plan_prune: {
40910
+ Args: never;
40911
+ Returns: number;
40912
+ };
40913
+ logistics_plan_release_stale: {
40914
+ Args: never;
40915
+ Returns: number;
40916
+ };
40917
+ logistics_plan_setting: {
40918
+ Args: {
40919
+ p_default: number;
40920
+ p_key: string;
40921
+ };
40922
+ Returns: number;
40923
+ };
40175
40924
  logistics_queue_capacity_email: {
40176
40925
  Args: {
40177
40926
  p_alert_id: string;
@@ -40410,6 +41159,13 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
40410
41159
  };
40411
41160
  Returns: undefined;
40412
41161
  };
41162
+ my_module_permissions: {
41163
+ Args: never;
41164
+ Returns: {
41165
+ module_id: string;
41166
+ permission: string;
41167
+ }[];
41168
+ };
40413
41169
  next_manufacture_partij: {
40414
41170
  Args: {
40415
41171
  _tenant_id: string;
@@ -40460,6 +41216,13 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
40460
41216
  };
40461
41217
  Returns: boolean;
40462
41218
  };
41219
+ opruim_print_historie: {
41220
+ Args: never;
41221
+ Returns: {
41222
+ ontdaan: number;
41223
+ verwijderd: number;
41224
+ }[];
41225
+ };
40463
41226
  order_number_prefix: {
40464
41227
  Args: {
40465
41228
  p_custom_fields?: import("../integrations/supabase/types").Json;
@@ -40854,6 +41617,12 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
40854
41617
  };
40855
41618
  Returns: undefined;
40856
41619
  };
41620
+ reset_stalled_floriday_stock_queue: {
41621
+ Args: {
41622
+ p_include_failed?: boolean;
41623
+ };
41624
+ Returns: number;
41625
+ };
40857
41626
  resolve_group_allocation: {
40858
41627
  Args: {
40859
41628
  _needed: number;
@@ -40908,10 +41677,18 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
40908
41677
  Args: never;
40909
41678
  Returns: undefined;
40910
41679
  };
41680
+ run_floriday_stock_queue_process: {
41681
+ Args: never;
41682
+ Returns: undefined;
41683
+ };
40911
41684
  run_logistics_tasks_dispatch: {
40912
41685
  Args: never;
40913
41686
  Returns: undefined;
40914
41687
  };
41688
+ run_print_queue_ticks: {
41689
+ Args: never;
41690
+ Returns: number;
41691
+ };
40915
41692
  run_twinfield_queue_tick: {
40916
41693
  Args: never;
40917
41694
  Returns: undefined;
@@ -41299,6 +42076,15 @@ export declare const replanBufferLoadCarriers: import("@tanstack/start-client-co
41299
42076
  };
41300
42077
  Returns: undefined;
41301
42078
  };
42079
+ trade_item_stock_duplicates: {
42080
+ Args: never;
42081
+ Returns: {
42082
+ keys: string[];
42083
+ product_id: string;
42084
+ product_name: string;
42085
+ row_count: number;
42086
+ }[];
42087
+ };
41302
42088
  try_debtor_lock: {
41303
42089
  Args: {
41304
42090
  _group_key: string;
@@ -43065,7 +43851,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
43065
43851
  city: string | null;
43066
43852
  country: string | null;
43067
43853
  created_at: string;
43068
- customer_id: string | null;
43854
+ customer_id: string;
43069
43855
  external_key: string | null;
43070
43856
  external_provider: string | null;
43071
43857
  floriday_location_id: string | null;
@@ -43089,7 +43875,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
43089
43875
  city?: string | null;
43090
43876
  country?: string | null;
43091
43877
  created_at?: string;
43092
- customer_id?: string | null;
43878
+ customer_id: string;
43093
43879
  external_key?: string | null;
43094
43880
  external_provider?: string | null;
43095
43881
  floriday_location_id?: string | null;
@@ -43113,7 +43899,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
43113
43899
  city?: string | null;
43114
43900
  country?: string | null;
43115
43901
  created_at?: string;
43116
- customer_id?: string | null;
43902
+ customer_id?: string;
43117
43903
  external_key?: string | null;
43118
43904
  external_provider?: string | null;
43119
43905
  floriday_location_id?: string | null;
@@ -47861,6 +48647,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
47861
48647
  Row: {
47862
48648
  buyer_organization_id: string | null;
47863
48649
  connection_id: string;
48650
+ controlled_at: string | null;
47864
48651
  created_at: string;
47865
48652
  data: import("../integrations/supabase/types").Json;
47866
48653
  floriday_id: string;
@@ -47872,6 +48659,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
47872
48659
  Insert: {
47873
48660
  buyer_organization_id?: string | null;
47874
48661
  connection_id: string;
48662
+ controlled_at?: string | null;
47875
48663
  created_at?: string;
47876
48664
  data: import("../integrations/supabase/types").Json;
47877
48665
  floriday_id: string;
@@ -47883,6 +48671,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
47883
48671
  Update: {
47884
48672
  buyer_organization_id?: string | null;
47885
48673
  connection_id?: string;
48674
+ controlled_at?: string | null;
47886
48675
  created_at?: string;
47887
48676
  data?: import("../integrations/supabase/types").Json;
47888
48677
  floriday_id?: string;
@@ -48784,6 +49573,54 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
48784
49573
  };
48785
49574
  Relationships: [];
48786
49575
  };
49576
+ invoice_timing_settings: {
49577
+ Row: {
49578
+ anchor: string;
49579
+ business_days_only: boolean;
49580
+ created_at: string;
49581
+ enabled: boolean;
49582
+ id: string;
49583
+ offset_days: number;
49584
+ pickup_anchor: string;
49585
+ pickup_business_days_only: boolean;
49586
+ pickup_offset_days: number;
49587
+ pickup_time_of_day: string;
49588
+ singleton: boolean;
49589
+ time_of_day: string;
49590
+ updated_at: string;
49591
+ };
49592
+ Insert: {
49593
+ anchor?: string;
49594
+ business_days_only?: boolean;
49595
+ created_at?: string;
49596
+ enabled?: boolean;
49597
+ id?: string;
49598
+ offset_days?: number;
49599
+ pickup_anchor?: string;
49600
+ pickup_business_days_only?: boolean;
49601
+ pickup_offset_days?: number;
49602
+ pickup_time_of_day?: string;
49603
+ singleton?: boolean;
49604
+ time_of_day?: string;
49605
+ updated_at?: string;
49606
+ };
49607
+ Update: {
49608
+ anchor?: string;
49609
+ business_days_only?: boolean;
49610
+ created_at?: string;
49611
+ enabled?: boolean;
49612
+ id?: string;
49613
+ offset_days?: number;
49614
+ pickup_anchor?: string;
49615
+ pickup_business_days_only?: boolean;
49616
+ pickup_offset_days?: number;
49617
+ pickup_time_of_day?: string;
49618
+ singleton?: boolean;
49619
+ time_of_day?: string;
49620
+ updated_at?: string;
49621
+ };
49622
+ Relationships: [];
49623
+ };
48787
49624
  itk_contact_persons: {
48788
49625
  Row: {
48789
49626
  created_at: string;
@@ -50014,6 +50851,45 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
50014
50851
  };
50015
50852
  Relationships: [];
50016
50853
  };
50854
+ logistics_plan_queue: {
50855
+ Row: {
50856
+ attempts: number;
50857
+ claimed_at: string | null;
50858
+ enqueued_at: string;
50859
+ error: string | null;
50860
+ id: string;
50861
+ next_attempt_at: string;
50862
+ order_id: string;
50863
+ reason: string;
50864
+ status: string;
50865
+ updated_at: string;
50866
+ };
50867
+ Insert: {
50868
+ attempts?: number;
50869
+ claimed_at?: string | null;
50870
+ enqueued_at?: string;
50871
+ error?: string | null;
50872
+ id?: string;
50873
+ next_attempt_at?: string;
50874
+ order_id: string;
50875
+ reason?: string;
50876
+ status?: string;
50877
+ updated_at?: string;
50878
+ };
50879
+ Update: {
50880
+ attempts?: number;
50881
+ claimed_at?: string | null;
50882
+ enqueued_at?: string;
50883
+ error?: string | null;
50884
+ id?: string;
50885
+ next_attempt_at?: string;
50886
+ order_id?: string;
50887
+ reason?: string;
50888
+ status?: string;
50889
+ updated_at?: string;
50890
+ };
50891
+ Relationships: [];
50892
+ };
50017
50893
  logistics_plan_runs: {
50018
50894
  Row: {
50019
50895
  created_at: string;
@@ -50089,6 +50965,24 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
50089
50965
  referencedColumns: ["id"];
50090
50966
  }];
50091
50967
  };
50968
+ logistics_plan_settings: {
50969
+ Row: {
50970
+ key: string;
50971
+ updated_at: string;
50972
+ value: string;
50973
+ };
50974
+ Insert: {
50975
+ key: string;
50976
+ updated_at?: string;
50977
+ value: string;
50978
+ };
50979
+ Update: {
50980
+ key?: string;
50981
+ updated_at?: string;
50982
+ value?: string;
50983
+ };
50984
+ Relationships: [];
50985
+ };
50092
50986
  logistics_rebuffer_state: {
50093
50987
  Row: {
50094
50988
  created_at: string;
@@ -50799,14 +51693,17 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
50799
51693
  };
50800
51694
  mailbox_messages: {
50801
51695
  Row: {
51696
+ attachments: import("../integrations/supabase/types").Json;
50802
51697
  body_html: string | null;
50803
51698
  body_text: string | null;
51699
+ cc_recipients: import("../integrations/supabase/types").Json;
50804
51700
  connection_id: string | null;
50805
51701
  created_at: string;
50806
51702
  error_message: string | null;
50807
51703
  external_id: string | null;
50808
51704
  from_email: string | null;
50809
51705
  from_name: string | null;
51706
+ has_attachments: boolean;
50810
51707
  id: string;
50811
51708
  message_id: string | null;
50812
51709
  profile_id: string | null;
@@ -50814,18 +51711,22 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
50814
51711
  received_at: string | null;
50815
51712
  status: string;
50816
51713
  subject: string | null;
51714
+ to_recipients: import("../integrations/supabase/types").Json;
50817
51715
  uid: number | null;
50818
51716
  updated_at: string;
50819
51717
  };
50820
51718
  Insert: {
51719
+ attachments?: import("../integrations/supabase/types").Json;
50821
51720
  body_html?: string | null;
50822
51721
  body_text?: string | null;
51722
+ cc_recipients?: import("../integrations/supabase/types").Json;
50823
51723
  connection_id?: string | null;
50824
51724
  created_at?: string;
50825
51725
  error_message?: string | null;
50826
51726
  external_id?: string | null;
50827
51727
  from_email?: string | null;
50828
51728
  from_name?: string | null;
51729
+ has_attachments?: boolean;
50829
51730
  id?: string;
50830
51731
  message_id?: string | null;
50831
51732
  profile_id?: string | null;
@@ -50833,18 +51734,22 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
50833
51734
  received_at?: string | null;
50834
51735
  status?: string;
50835
51736
  subject?: string | null;
51737
+ to_recipients?: import("../integrations/supabase/types").Json;
50836
51738
  uid?: number | null;
50837
51739
  updated_at?: string;
50838
51740
  };
50839
51741
  Update: {
51742
+ attachments?: import("../integrations/supabase/types").Json;
50840
51743
  body_html?: string | null;
50841
51744
  body_text?: string | null;
51745
+ cc_recipients?: import("../integrations/supabase/types").Json;
50842
51746
  connection_id?: string | null;
50843
51747
  created_at?: string;
50844
51748
  error_message?: string | null;
50845
51749
  external_id?: string | null;
50846
51750
  from_email?: string | null;
50847
51751
  from_name?: string | null;
51752
+ has_attachments?: boolean;
50848
51753
  id?: string;
50849
51754
  message_id?: string | null;
50850
51755
  profile_id?: string | null;
@@ -50852,6 +51757,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
50852
51757
  received_at?: string | null;
50853
51758
  status?: string;
50854
51759
  subject?: string | null;
51760
+ to_recipients?: import("../integrations/supabase/types").Json;
50855
51761
  uid?: number | null;
50856
51762
  updated_at?: string;
50857
51763
  };
@@ -51259,6 +52165,36 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
51259
52165
  };
51260
52166
  Relationships: [];
51261
52167
  };
52168
+ module_registry: {
52169
+ Row: {
52170
+ created_at: string;
52171
+ is_active: boolean;
52172
+ last_seen_at: string;
52173
+ module_id: string;
52174
+ name: string;
52175
+ shell_id: string | null;
52176
+ sort_order: number | null;
52177
+ };
52178
+ Insert: {
52179
+ created_at?: string;
52180
+ is_active?: boolean;
52181
+ last_seen_at?: string;
52182
+ module_id: string;
52183
+ name: string;
52184
+ shell_id?: string | null;
52185
+ sort_order?: number | null;
52186
+ };
52187
+ Update: {
52188
+ created_at?: string;
52189
+ is_active?: boolean;
52190
+ last_seen_at?: string;
52191
+ module_id?: string;
52192
+ name?: string;
52193
+ shell_id?: string | null;
52194
+ sort_order?: number | null;
52195
+ };
52196
+ Relationships: [];
52197
+ };
51262
52198
  module_runtime_config: {
51263
52199
  Row: {
51264
52200
  key: string;
@@ -52318,6 +53254,45 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
52318
53254
  };
52319
53255
  Relationships: [];
52320
53256
  };
53257
+ order_invoice_links: {
53258
+ Row: {
53259
+ attempts: number;
53260
+ created_at: string;
53261
+ error_message: string | null;
53262
+ id: string;
53263
+ invoice_number: string | null;
53264
+ next_attempt_at: string;
53265
+ order_id: string;
53266
+ processed_at: string | null;
53267
+ status: string;
53268
+ updated_at: string;
53269
+ };
53270
+ Insert: {
53271
+ attempts?: number;
53272
+ created_at?: string;
53273
+ error_message?: string | null;
53274
+ id?: string;
53275
+ invoice_number?: string | null;
53276
+ next_attempt_at?: string;
53277
+ order_id: string;
53278
+ processed_at?: string | null;
53279
+ status?: string;
53280
+ updated_at?: string;
53281
+ };
53282
+ Update: {
53283
+ attempts?: number;
53284
+ created_at?: string;
53285
+ error_message?: string | null;
53286
+ id?: string;
53287
+ invoice_number?: string | null;
53288
+ next_attempt_at?: string;
53289
+ order_id?: string;
53290
+ processed_at?: string | null;
53291
+ status?: string;
53292
+ updated_at?: string;
53293
+ };
53294
+ Relationships: [];
53295
+ };
52321
53296
  order_items: {
52322
53297
  Row: {
52323
53298
  crates_per_layer: number | null;
@@ -52500,6 +53475,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
52500
53475
  delivery_date: string | null;
52501
53476
  floriday_sales_order_id: string | null;
52502
53477
  id: string;
53478
+ invoice_due_at: string | null;
52503
53479
  is_reservation: boolean;
52504
53480
  notes: string | null;
52505
53481
  order_date: string;
@@ -52521,6 +53497,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
52521
53497
  delivery_date?: string | null;
52522
53498
  floriday_sales_order_id?: string | null;
52523
53499
  id?: string;
53500
+ invoice_due_at?: string | null;
52524
53501
  is_reservation?: boolean;
52525
53502
  notes?: string | null;
52526
53503
  order_date?: string;
@@ -52542,6 +53519,7 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
52542
53519
  delivery_date?: string | null;
52543
53520
  floriday_sales_order_id?: string | null;
52544
53521
  id?: string;
53522
+ invoice_due_at?: string | null;
52545
53523
  is_reservation?: boolean;
52546
53524
  notes?: string | null;
52547
53525
  order_date?: string;
@@ -53839,6 +54817,63 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
53839
54817
  referencedColumns: ["id"];
53840
54818
  }];
53841
54819
  };
54820
+ print_queue_runners: {
54821
+ Row: {
54822
+ actief: boolean;
54823
+ basis_url: string;
54824
+ created_at: string;
54825
+ id: string;
54826
+ laatst_gezien: string;
54827
+ tick_sleutel: string;
54828
+ updated_at: string;
54829
+ };
54830
+ Insert: {
54831
+ actief?: boolean;
54832
+ basis_url: string;
54833
+ created_at?: string;
54834
+ id?: string;
54835
+ laatst_gezien?: string;
54836
+ tick_sleutel?: string;
54837
+ updated_at?: string;
54838
+ };
54839
+ Update: {
54840
+ actief?: boolean;
54841
+ basis_url?: string;
54842
+ created_at?: string;
54843
+ id?: string;
54844
+ laatst_gezien?: string;
54845
+ tick_sleutel?: string;
54846
+ updated_at?: string;
54847
+ };
54848
+ Relationships: [];
54849
+ };
54850
+ print_queue_settings: {
54851
+ Row: {
54852
+ bewaar_bestanden_dagen: number;
54853
+ bewaar_opdrachten_dagen: number;
54854
+ created_at: string;
54855
+ dubbel_venster_minuten: number;
54856
+ id: string;
54857
+ updated_at: string;
54858
+ };
54859
+ Insert: {
54860
+ bewaar_bestanden_dagen?: number;
54861
+ bewaar_opdrachten_dagen?: number;
54862
+ created_at?: string;
54863
+ dubbel_venster_minuten?: number;
54864
+ id?: string;
54865
+ updated_at?: string;
54866
+ };
54867
+ Update: {
54868
+ bewaar_bestanden_dagen?: number;
54869
+ bewaar_opdrachten_dagen?: number;
54870
+ created_at?: string;
54871
+ dubbel_venster_minuten?: number;
54872
+ id?: string;
54873
+ updated_at?: string;
54874
+ };
54875
+ Relationships: [];
54876
+ };
53842
54877
  print_rules: {
53843
54878
  Row: {
53844
54879
  actief: boolean;
@@ -56679,6 +57714,8 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
56679
57714
  };
56680
57715
  twinfield_invoice_settings: {
56681
57716
  Row: {
57717
+ auto_invoice_enabled: boolean;
57718
+ auto_invoice_trigger_statuses: string[];
56682
57719
  created_at: string;
56683
57720
  debtor_gl_account: string;
56684
57721
  default_credit_invoice_type: string | null;
@@ -56699,6 +57736,8 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
56699
57736
  vat_code_export: string | null;
56700
57737
  };
56701
57738
  Insert: {
57739
+ auto_invoice_enabled?: boolean;
57740
+ auto_invoice_trigger_statuses?: string[];
56702
57741
  created_at?: string;
56703
57742
  debtor_gl_account?: string;
56704
57743
  default_credit_invoice_type?: string | null;
@@ -56719,6 +57758,8 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
56719
57758
  vat_code_export?: string | null;
56720
57759
  };
56721
57760
  Update: {
57761
+ auto_invoice_enabled?: boolean;
57762
+ auto_invoice_trigger_statuses?: string[];
56722
57763
  created_at?: string;
56723
57764
  debtor_gl_account?: string;
56724
57765
  default_credit_invoice_type?: string | null;
@@ -57781,6 +58822,33 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
57781
58822
  referencedColumns: ["id"];
57782
58823
  }];
57783
58824
  };
58825
+ user_module_permissions: {
58826
+ Row: {
58827
+ created_at: string;
58828
+ id: string;
58829
+ module_id: string;
58830
+ permission: string;
58831
+ updated_at: string;
58832
+ user_id: string;
58833
+ };
58834
+ Insert: {
58835
+ created_at?: string;
58836
+ id?: string;
58837
+ module_id: string;
58838
+ permission: string;
58839
+ updated_at?: string;
58840
+ user_id: string;
58841
+ };
58842
+ Update: {
58843
+ created_at?: string;
58844
+ id?: string;
58845
+ module_id?: string;
58846
+ permission?: string;
58847
+ updated_at?: string;
58848
+ user_id?: string;
58849
+ };
58850
+ Relationships: [];
58851
+ };
57784
58852
  user_roles: {
57785
58853
  Row: {
57786
58854
  created_at: string;
@@ -59614,6 +60682,10 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
59614
60682
  processed_items: number;
59615
60683
  }[];
59616
60684
  };
60685
+ backfill_order_auto_invoice_queue: {
60686
+ Args: never;
60687
+ Returns: number;
60688
+ };
59617
60689
  calculate_layer_stock: {
59618
60690
  Args: {
59619
60691
  p_product_id: string;
@@ -59844,6 +60916,10 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
59844
60916
  Args: never;
59845
60917
  Returns: undefined;
59846
60918
  };
60919
+ cleanup_voorraad_module_history: {
60920
+ Args: never;
60921
+ Returns: undefined;
60922
+ };
59847
60923
  complete_floriday_stock_queue: {
59848
60924
  Args: {
59849
60925
  p_attempt_id?: string;
@@ -59965,6 +61041,13 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
59965
61041
  };
59966
61042
  Returns: import("../integrations/supabase/types").Json;
59967
61043
  };
61044
+ effective_module_permission: {
61045
+ Args: {
61046
+ _module_id: string;
61047
+ _user_id: string;
61048
+ };
61049
+ Returns: string;
61050
+ };
59968
61051
  email_auth_decrypt: {
59969
61052
  Args: {
59970
61053
  cipher: string;
@@ -60865,6 +61948,65 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
60865
61948
  };
60866
61949
  Returns: number;
60867
61950
  };
61951
+ logistics_plan_claim: {
61952
+ Args: {
61953
+ p_limit?: number;
61954
+ };
61955
+ Returns: {
61956
+ attempts: number;
61957
+ id: string;
61958
+ order_id: string;
61959
+ }[];
61960
+ };
61961
+ logistics_plan_enqueue: {
61962
+ Args: {
61963
+ p_order_id: string;
61964
+ p_reason?: string;
61965
+ };
61966
+ Returns: undefined;
61967
+ };
61968
+ logistics_plan_ensure_event: {
61969
+ Args: {
61970
+ p_order_id: string;
61971
+ };
61972
+ Returns: boolean;
61973
+ };
61974
+ logistics_plan_finish: {
61975
+ Args: {
61976
+ p_error?: string;
61977
+ p_id: string;
61978
+ };
61979
+ Returns: undefined;
61980
+ };
61981
+ logistics_plan_impact_orders: {
61982
+ Args: {
61983
+ p_order_id: string;
61984
+ };
61985
+ Returns: {
61986
+ buffer_id: string;
61987
+ order_id: string;
61988
+ plan_date: string;
61989
+ }[];
61990
+ };
61991
+ logistics_plan_kick: {
61992
+ Args: never;
61993
+ Returns: undefined;
61994
+ };
61995
+ logistics_plan_prune: {
61996
+ Args: never;
61997
+ Returns: number;
61998
+ };
61999
+ logistics_plan_release_stale: {
62000
+ Args: never;
62001
+ Returns: number;
62002
+ };
62003
+ logistics_plan_setting: {
62004
+ Args: {
62005
+ p_default: number;
62006
+ p_key: string;
62007
+ };
62008
+ Returns: number;
62009
+ };
60868
62010
  logistics_queue_capacity_email: {
60869
62011
  Args: {
60870
62012
  p_alert_id: string;
@@ -61103,6 +62245,13 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
61103
62245
  };
61104
62246
  Returns: undefined;
61105
62247
  };
62248
+ my_module_permissions: {
62249
+ Args: never;
62250
+ Returns: {
62251
+ module_id: string;
62252
+ permission: string;
62253
+ }[];
62254
+ };
61106
62255
  next_manufacture_partij: {
61107
62256
  Args: {
61108
62257
  _tenant_id: string;
@@ -61153,6 +62302,13 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
61153
62302
  };
61154
62303
  Returns: boolean;
61155
62304
  };
62305
+ opruim_print_historie: {
62306
+ Args: never;
62307
+ Returns: {
62308
+ ontdaan: number;
62309
+ verwijderd: number;
62310
+ }[];
62311
+ };
61156
62312
  order_number_prefix: {
61157
62313
  Args: {
61158
62314
  p_custom_fields?: import("../integrations/supabase/types").Json;
@@ -61547,6 +62703,12 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
61547
62703
  };
61548
62704
  Returns: undefined;
61549
62705
  };
62706
+ reset_stalled_floriday_stock_queue: {
62707
+ Args: {
62708
+ p_include_failed?: boolean;
62709
+ };
62710
+ Returns: number;
62711
+ };
61550
62712
  resolve_group_allocation: {
61551
62713
  Args: {
61552
62714
  _needed: number;
@@ -61601,10 +62763,18 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
61601
62763
  Args: never;
61602
62764
  Returns: undefined;
61603
62765
  };
62766
+ run_floriday_stock_queue_process: {
62767
+ Args: never;
62768
+ Returns: undefined;
62769
+ };
61604
62770
  run_logistics_tasks_dispatch: {
61605
62771
  Args: never;
61606
62772
  Returns: undefined;
61607
62773
  };
62774
+ run_print_queue_ticks: {
62775
+ Args: never;
62776
+ Returns: number;
62777
+ };
61608
62778
  run_twinfield_queue_tick: {
61609
62779
  Args: never;
61610
62780
  Returns: undefined;
@@ -61992,6 +63162,15 @@ export declare const planAllLoadCarriers: import("@tanstack/start-client-core").
61992
63162
  };
61993
63163
  Returns: undefined;
61994
63164
  };
63165
+ trade_item_stock_duplicates: {
63166
+ Args: never;
63167
+ Returns: {
63168
+ keys: string[];
63169
+ product_id: string;
63170
+ product_name: string;
63171
+ row_count: number;
63172
+ }[];
63173
+ };
61995
63174
  try_debtor_lock: {
61996
63175
  Args: {
61997
63176
  _group_key: string;
@@ -63758,7 +64937,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
63758
64937
  city: string | null;
63759
64938
  country: string | null;
63760
64939
  created_at: string;
63761
- customer_id: string | null;
64940
+ customer_id: string;
63762
64941
  external_key: string | null;
63763
64942
  external_provider: string | null;
63764
64943
  floriday_location_id: string | null;
@@ -63782,7 +64961,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
63782
64961
  city?: string | null;
63783
64962
  country?: string | null;
63784
64963
  created_at?: string;
63785
- customer_id?: string | null;
64964
+ customer_id: string;
63786
64965
  external_key?: string | null;
63787
64966
  external_provider?: string | null;
63788
64967
  floriday_location_id?: string | null;
@@ -63806,7 +64985,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
63806
64985
  city?: string | null;
63807
64986
  country?: string | null;
63808
64987
  created_at?: string;
63809
- customer_id?: string | null;
64988
+ customer_id?: string;
63810
64989
  external_key?: string | null;
63811
64990
  external_provider?: string | null;
63812
64991
  floriday_location_id?: string | null;
@@ -68554,6 +69733,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
68554
69733
  Row: {
68555
69734
  buyer_organization_id: string | null;
68556
69735
  connection_id: string;
69736
+ controlled_at: string | null;
68557
69737
  created_at: string;
68558
69738
  data: import("../integrations/supabase/types").Json;
68559
69739
  floriday_id: string;
@@ -68565,6 +69745,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
68565
69745
  Insert: {
68566
69746
  buyer_organization_id?: string | null;
68567
69747
  connection_id: string;
69748
+ controlled_at?: string | null;
68568
69749
  created_at?: string;
68569
69750
  data: import("../integrations/supabase/types").Json;
68570
69751
  floriday_id: string;
@@ -68576,6 +69757,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
68576
69757
  Update: {
68577
69758
  buyer_organization_id?: string | null;
68578
69759
  connection_id?: string;
69760
+ controlled_at?: string | null;
68579
69761
  created_at?: string;
68580
69762
  data?: import("../integrations/supabase/types").Json;
68581
69763
  floriday_id?: string;
@@ -69477,6 +70659,54 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
69477
70659
  };
69478
70660
  Relationships: [];
69479
70661
  };
70662
+ invoice_timing_settings: {
70663
+ Row: {
70664
+ anchor: string;
70665
+ business_days_only: boolean;
70666
+ created_at: string;
70667
+ enabled: boolean;
70668
+ id: string;
70669
+ offset_days: number;
70670
+ pickup_anchor: string;
70671
+ pickup_business_days_only: boolean;
70672
+ pickup_offset_days: number;
70673
+ pickup_time_of_day: string;
70674
+ singleton: boolean;
70675
+ time_of_day: string;
70676
+ updated_at: string;
70677
+ };
70678
+ Insert: {
70679
+ anchor?: string;
70680
+ business_days_only?: boolean;
70681
+ created_at?: string;
70682
+ enabled?: boolean;
70683
+ id?: string;
70684
+ offset_days?: number;
70685
+ pickup_anchor?: string;
70686
+ pickup_business_days_only?: boolean;
70687
+ pickup_offset_days?: number;
70688
+ pickup_time_of_day?: string;
70689
+ singleton?: boolean;
70690
+ time_of_day?: string;
70691
+ updated_at?: string;
70692
+ };
70693
+ Update: {
70694
+ anchor?: string;
70695
+ business_days_only?: boolean;
70696
+ created_at?: string;
70697
+ enabled?: boolean;
70698
+ id?: string;
70699
+ offset_days?: number;
70700
+ pickup_anchor?: string;
70701
+ pickup_business_days_only?: boolean;
70702
+ pickup_offset_days?: number;
70703
+ pickup_time_of_day?: string;
70704
+ singleton?: boolean;
70705
+ time_of_day?: string;
70706
+ updated_at?: string;
70707
+ };
70708
+ Relationships: [];
70709
+ };
69480
70710
  itk_contact_persons: {
69481
70711
  Row: {
69482
70712
  created_at: string;
@@ -70707,6 +71937,45 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
70707
71937
  };
70708
71938
  Relationships: [];
70709
71939
  };
71940
+ logistics_plan_queue: {
71941
+ Row: {
71942
+ attempts: number;
71943
+ claimed_at: string | null;
71944
+ enqueued_at: string;
71945
+ error: string | null;
71946
+ id: string;
71947
+ next_attempt_at: string;
71948
+ order_id: string;
71949
+ reason: string;
71950
+ status: string;
71951
+ updated_at: string;
71952
+ };
71953
+ Insert: {
71954
+ attempts?: number;
71955
+ claimed_at?: string | null;
71956
+ enqueued_at?: string;
71957
+ error?: string | null;
71958
+ id?: string;
71959
+ next_attempt_at?: string;
71960
+ order_id: string;
71961
+ reason?: string;
71962
+ status?: string;
71963
+ updated_at?: string;
71964
+ };
71965
+ Update: {
71966
+ attempts?: number;
71967
+ claimed_at?: string | null;
71968
+ enqueued_at?: string;
71969
+ error?: string | null;
71970
+ id?: string;
71971
+ next_attempt_at?: string;
71972
+ order_id?: string;
71973
+ reason?: string;
71974
+ status?: string;
71975
+ updated_at?: string;
71976
+ };
71977
+ Relationships: [];
71978
+ };
70710
71979
  logistics_plan_runs: {
70711
71980
  Row: {
70712
71981
  created_at: string;
@@ -70782,6 +72051,24 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
70782
72051
  referencedColumns: ["id"];
70783
72052
  }];
70784
72053
  };
72054
+ logistics_plan_settings: {
72055
+ Row: {
72056
+ key: string;
72057
+ updated_at: string;
72058
+ value: string;
72059
+ };
72060
+ Insert: {
72061
+ key: string;
72062
+ updated_at?: string;
72063
+ value: string;
72064
+ };
72065
+ Update: {
72066
+ key?: string;
72067
+ updated_at?: string;
72068
+ value?: string;
72069
+ };
72070
+ Relationships: [];
72071
+ };
70785
72072
  logistics_rebuffer_state: {
70786
72073
  Row: {
70787
72074
  created_at: string;
@@ -71492,14 +72779,17 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
71492
72779
  };
71493
72780
  mailbox_messages: {
71494
72781
  Row: {
72782
+ attachments: import("../integrations/supabase/types").Json;
71495
72783
  body_html: string | null;
71496
72784
  body_text: string | null;
72785
+ cc_recipients: import("../integrations/supabase/types").Json;
71497
72786
  connection_id: string | null;
71498
72787
  created_at: string;
71499
72788
  error_message: string | null;
71500
72789
  external_id: string | null;
71501
72790
  from_email: string | null;
71502
72791
  from_name: string | null;
72792
+ has_attachments: boolean;
71503
72793
  id: string;
71504
72794
  message_id: string | null;
71505
72795
  profile_id: string | null;
@@ -71507,18 +72797,22 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
71507
72797
  received_at: string | null;
71508
72798
  status: string;
71509
72799
  subject: string | null;
72800
+ to_recipients: import("../integrations/supabase/types").Json;
71510
72801
  uid: number | null;
71511
72802
  updated_at: string;
71512
72803
  };
71513
72804
  Insert: {
72805
+ attachments?: import("../integrations/supabase/types").Json;
71514
72806
  body_html?: string | null;
71515
72807
  body_text?: string | null;
72808
+ cc_recipients?: import("../integrations/supabase/types").Json;
71516
72809
  connection_id?: string | null;
71517
72810
  created_at?: string;
71518
72811
  error_message?: string | null;
71519
72812
  external_id?: string | null;
71520
72813
  from_email?: string | null;
71521
72814
  from_name?: string | null;
72815
+ has_attachments?: boolean;
71522
72816
  id?: string;
71523
72817
  message_id?: string | null;
71524
72818
  profile_id?: string | null;
@@ -71526,18 +72820,22 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
71526
72820
  received_at?: string | null;
71527
72821
  status?: string;
71528
72822
  subject?: string | null;
72823
+ to_recipients?: import("../integrations/supabase/types").Json;
71529
72824
  uid?: number | null;
71530
72825
  updated_at?: string;
71531
72826
  };
71532
72827
  Update: {
72828
+ attachments?: import("../integrations/supabase/types").Json;
71533
72829
  body_html?: string | null;
71534
72830
  body_text?: string | null;
72831
+ cc_recipients?: import("../integrations/supabase/types").Json;
71535
72832
  connection_id?: string | null;
71536
72833
  created_at?: string;
71537
72834
  error_message?: string | null;
71538
72835
  external_id?: string | null;
71539
72836
  from_email?: string | null;
71540
72837
  from_name?: string | null;
72838
+ has_attachments?: boolean;
71541
72839
  id?: string;
71542
72840
  message_id?: string | null;
71543
72841
  profile_id?: string | null;
@@ -71545,6 +72843,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
71545
72843
  received_at?: string | null;
71546
72844
  status?: string;
71547
72845
  subject?: string | null;
72846
+ to_recipients?: import("../integrations/supabase/types").Json;
71548
72847
  uid?: number | null;
71549
72848
  updated_at?: string;
71550
72849
  };
@@ -71952,6 +73251,36 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
71952
73251
  };
71953
73252
  Relationships: [];
71954
73253
  };
73254
+ module_registry: {
73255
+ Row: {
73256
+ created_at: string;
73257
+ is_active: boolean;
73258
+ last_seen_at: string;
73259
+ module_id: string;
73260
+ name: string;
73261
+ shell_id: string | null;
73262
+ sort_order: number | null;
73263
+ };
73264
+ Insert: {
73265
+ created_at?: string;
73266
+ is_active?: boolean;
73267
+ last_seen_at?: string;
73268
+ module_id: string;
73269
+ name: string;
73270
+ shell_id?: string | null;
73271
+ sort_order?: number | null;
73272
+ };
73273
+ Update: {
73274
+ created_at?: string;
73275
+ is_active?: boolean;
73276
+ last_seen_at?: string;
73277
+ module_id?: string;
73278
+ name?: string;
73279
+ shell_id?: string | null;
73280
+ sort_order?: number | null;
73281
+ };
73282
+ Relationships: [];
73283
+ };
71955
73284
  module_runtime_config: {
71956
73285
  Row: {
71957
73286
  key: string;
@@ -73011,6 +74340,45 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
73011
74340
  };
73012
74341
  Relationships: [];
73013
74342
  };
74343
+ order_invoice_links: {
74344
+ Row: {
74345
+ attempts: number;
74346
+ created_at: string;
74347
+ error_message: string | null;
74348
+ id: string;
74349
+ invoice_number: string | null;
74350
+ next_attempt_at: string;
74351
+ order_id: string;
74352
+ processed_at: string | null;
74353
+ status: string;
74354
+ updated_at: string;
74355
+ };
74356
+ Insert: {
74357
+ attempts?: number;
74358
+ created_at?: string;
74359
+ error_message?: string | null;
74360
+ id?: string;
74361
+ invoice_number?: string | null;
74362
+ next_attempt_at?: string;
74363
+ order_id: string;
74364
+ processed_at?: string | null;
74365
+ status?: string;
74366
+ updated_at?: string;
74367
+ };
74368
+ Update: {
74369
+ attempts?: number;
74370
+ created_at?: string;
74371
+ error_message?: string | null;
74372
+ id?: string;
74373
+ invoice_number?: string | null;
74374
+ next_attempt_at?: string;
74375
+ order_id?: string;
74376
+ processed_at?: string | null;
74377
+ status?: string;
74378
+ updated_at?: string;
74379
+ };
74380
+ Relationships: [];
74381
+ };
73014
74382
  order_items: {
73015
74383
  Row: {
73016
74384
  crates_per_layer: number | null;
@@ -73193,6 +74561,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
73193
74561
  delivery_date: string | null;
73194
74562
  floriday_sales_order_id: string | null;
73195
74563
  id: string;
74564
+ invoice_due_at: string | null;
73196
74565
  is_reservation: boolean;
73197
74566
  notes: string | null;
73198
74567
  order_date: string;
@@ -73214,6 +74583,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
73214
74583
  delivery_date?: string | null;
73215
74584
  floriday_sales_order_id?: string | null;
73216
74585
  id?: string;
74586
+ invoice_due_at?: string | null;
73217
74587
  is_reservation?: boolean;
73218
74588
  notes?: string | null;
73219
74589
  order_date?: string;
@@ -73235,6 +74605,7 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
73235
74605
  delivery_date?: string | null;
73236
74606
  floriday_sales_order_id?: string | null;
73237
74607
  id?: string;
74608
+ invoice_due_at?: string | null;
73238
74609
  is_reservation?: boolean;
73239
74610
  notes?: string | null;
73240
74611
  order_date?: string;
@@ -74532,6 +75903,63 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
74532
75903
  referencedColumns: ["id"];
74533
75904
  }];
74534
75905
  };
75906
+ print_queue_runners: {
75907
+ Row: {
75908
+ actief: boolean;
75909
+ basis_url: string;
75910
+ created_at: string;
75911
+ id: string;
75912
+ laatst_gezien: string;
75913
+ tick_sleutel: string;
75914
+ updated_at: string;
75915
+ };
75916
+ Insert: {
75917
+ actief?: boolean;
75918
+ basis_url: string;
75919
+ created_at?: string;
75920
+ id?: string;
75921
+ laatst_gezien?: string;
75922
+ tick_sleutel?: string;
75923
+ updated_at?: string;
75924
+ };
75925
+ Update: {
75926
+ actief?: boolean;
75927
+ basis_url?: string;
75928
+ created_at?: string;
75929
+ id?: string;
75930
+ laatst_gezien?: string;
75931
+ tick_sleutel?: string;
75932
+ updated_at?: string;
75933
+ };
75934
+ Relationships: [];
75935
+ };
75936
+ print_queue_settings: {
75937
+ Row: {
75938
+ bewaar_bestanden_dagen: number;
75939
+ bewaar_opdrachten_dagen: number;
75940
+ created_at: string;
75941
+ dubbel_venster_minuten: number;
75942
+ id: string;
75943
+ updated_at: string;
75944
+ };
75945
+ Insert: {
75946
+ bewaar_bestanden_dagen?: number;
75947
+ bewaar_opdrachten_dagen?: number;
75948
+ created_at?: string;
75949
+ dubbel_venster_minuten?: number;
75950
+ id?: string;
75951
+ updated_at?: string;
75952
+ };
75953
+ Update: {
75954
+ bewaar_bestanden_dagen?: number;
75955
+ bewaar_opdrachten_dagen?: number;
75956
+ created_at?: string;
75957
+ dubbel_venster_minuten?: number;
75958
+ id?: string;
75959
+ updated_at?: string;
75960
+ };
75961
+ Relationships: [];
75962
+ };
74535
75963
  print_rules: {
74536
75964
  Row: {
74537
75965
  actief: boolean;
@@ -77372,6 +78800,8 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
77372
78800
  };
77373
78801
  twinfield_invoice_settings: {
77374
78802
  Row: {
78803
+ auto_invoice_enabled: boolean;
78804
+ auto_invoice_trigger_statuses: string[];
77375
78805
  created_at: string;
77376
78806
  debtor_gl_account: string;
77377
78807
  default_credit_invoice_type: string | null;
@@ -77392,6 +78822,8 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
77392
78822
  vat_code_export: string | null;
77393
78823
  };
77394
78824
  Insert: {
78825
+ auto_invoice_enabled?: boolean;
78826
+ auto_invoice_trigger_statuses?: string[];
77395
78827
  created_at?: string;
77396
78828
  debtor_gl_account?: string;
77397
78829
  default_credit_invoice_type?: string | null;
@@ -77412,6 +78844,8 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
77412
78844
  vat_code_export?: string | null;
77413
78845
  };
77414
78846
  Update: {
78847
+ auto_invoice_enabled?: boolean;
78848
+ auto_invoice_trigger_statuses?: string[];
77415
78849
  created_at?: string;
77416
78850
  debtor_gl_account?: string;
77417
78851
  default_credit_invoice_type?: string | null;
@@ -78474,6 +79908,33 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
78474
79908
  referencedColumns: ["id"];
78475
79909
  }];
78476
79910
  };
79911
+ user_module_permissions: {
79912
+ Row: {
79913
+ created_at: string;
79914
+ id: string;
79915
+ module_id: string;
79916
+ permission: string;
79917
+ updated_at: string;
79918
+ user_id: string;
79919
+ };
79920
+ Insert: {
79921
+ created_at?: string;
79922
+ id?: string;
79923
+ module_id: string;
79924
+ permission: string;
79925
+ updated_at?: string;
79926
+ user_id: string;
79927
+ };
79928
+ Update: {
79929
+ created_at?: string;
79930
+ id?: string;
79931
+ module_id?: string;
79932
+ permission?: string;
79933
+ updated_at?: string;
79934
+ user_id?: string;
79935
+ };
79936
+ Relationships: [];
79937
+ };
78477
79938
  user_roles: {
78478
79939
  Row: {
78479
79940
  created_at: string;
@@ -80307,6 +81768,10 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
80307
81768
  processed_items: number;
80308
81769
  }[];
80309
81770
  };
81771
+ backfill_order_auto_invoice_queue: {
81772
+ Args: never;
81773
+ Returns: number;
81774
+ };
80310
81775
  calculate_layer_stock: {
80311
81776
  Args: {
80312
81777
  p_product_id: string;
@@ -80537,6 +82002,10 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
80537
82002
  Args: never;
80538
82003
  Returns: undefined;
80539
82004
  };
82005
+ cleanup_voorraad_module_history: {
82006
+ Args: never;
82007
+ Returns: undefined;
82008
+ };
80540
82009
  complete_floriday_stock_queue: {
80541
82010
  Args: {
80542
82011
  p_attempt_id?: string;
@@ -80658,6 +82127,13 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
80658
82127
  };
80659
82128
  Returns: import("../integrations/supabase/types").Json;
80660
82129
  };
82130
+ effective_module_permission: {
82131
+ Args: {
82132
+ _module_id: string;
82133
+ _user_id: string;
82134
+ };
82135
+ Returns: string;
82136
+ };
80661
82137
  email_auth_decrypt: {
80662
82138
  Args: {
80663
82139
  cipher: string;
@@ -81558,6 +83034,65 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
81558
83034
  };
81559
83035
  Returns: number;
81560
83036
  };
83037
+ logistics_plan_claim: {
83038
+ Args: {
83039
+ p_limit?: number;
83040
+ };
83041
+ Returns: {
83042
+ attempts: number;
83043
+ id: string;
83044
+ order_id: string;
83045
+ }[];
83046
+ };
83047
+ logistics_plan_enqueue: {
83048
+ Args: {
83049
+ p_order_id: string;
83050
+ p_reason?: string;
83051
+ };
83052
+ Returns: undefined;
83053
+ };
83054
+ logistics_plan_ensure_event: {
83055
+ Args: {
83056
+ p_order_id: string;
83057
+ };
83058
+ Returns: boolean;
83059
+ };
83060
+ logistics_plan_finish: {
83061
+ Args: {
83062
+ p_error?: string;
83063
+ p_id: string;
83064
+ };
83065
+ Returns: undefined;
83066
+ };
83067
+ logistics_plan_impact_orders: {
83068
+ Args: {
83069
+ p_order_id: string;
83070
+ };
83071
+ Returns: {
83072
+ buffer_id: string;
83073
+ order_id: string;
83074
+ plan_date: string;
83075
+ }[];
83076
+ };
83077
+ logistics_plan_kick: {
83078
+ Args: never;
83079
+ Returns: undefined;
83080
+ };
83081
+ logistics_plan_prune: {
83082
+ Args: never;
83083
+ Returns: number;
83084
+ };
83085
+ logistics_plan_release_stale: {
83086
+ Args: never;
83087
+ Returns: number;
83088
+ };
83089
+ logistics_plan_setting: {
83090
+ Args: {
83091
+ p_default: number;
83092
+ p_key: string;
83093
+ };
83094
+ Returns: number;
83095
+ };
81561
83096
  logistics_queue_capacity_email: {
81562
83097
  Args: {
81563
83098
  p_alert_id: string;
@@ -81796,6 +83331,13 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
81796
83331
  };
81797
83332
  Returns: undefined;
81798
83333
  };
83334
+ my_module_permissions: {
83335
+ Args: never;
83336
+ Returns: {
83337
+ module_id: string;
83338
+ permission: string;
83339
+ }[];
83340
+ };
81799
83341
  next_manufacture_partij: {
81800
83342
  Args: {
81801
83343
  _tenant_id: string;
@@ -81846,6 +83388,13 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
81846
83388
  };
81847
83389
  Returns: boolean;
81848
83390
  };
83391
+ opruim_print_historie: {
83392
+ Args: never;
83393
+ Returns: {
83394
+ ontdaan: number;
83395
+ verwijderd: number;
83396
+ }[];
83397
+ };
81849
83398
  order_number_prefix: {
81850
83399
  Args: {
81851
83400
  p_custom_fields?: import("../integrations/supabase/types").Json;
@@ -82240,6 +83789,12 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
82240
83789
  };
82241
83790
  Returns: undefined;
82242
83791
  };
83792
+ reset_stalled_floriday_stock_queue: {
83793
+ Args: {
83794
+ p_include_failed?: boolean;
83795
+ };
83796
+ Returns: number;
83797
+ };
82243
83798
  resolve_group_allocation: {
82244
83799
  Args: {
82245
83800
  _needed: number;
@@ -82294,10 +83849,18 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
82294
83849
  Args: never;
82295
83850
  Returns: undefined;
82296
83851
  };
83852
+ run_floriday_stock_queue_process: {
83853
+ Args: never;
83854
+ Returns: undefined;
83855
+ };
82297
83856
  run_logistics_tasks_dispatch: {
82298
83857
  Args: never;
82299
83858
  Returns: undefined;
82300
83859
  };
83860
+ run_print_queue_ticks: {
83861
+ Args: never;
83862
+ Returns: number;
83863
+ };
82301
83864
  run_twinfield_queue_tick: {
82302
83865
  Args: never;
82303
83866
  Returns: undefined;
@@ -82685,6 +84248,15 @@ export declare const ensureLogisticsTasks: import("@tanstack/start-client-core")
82685
84248
  };
82686
84249
  Returns: undefined;
82687
84250
  };
84251
+ trade_item_stock_duplicates: {
84252
+ Args: never;
84253
+ Returns: {
84254
+ keys: string[];
84255
+ product_id: string;
84256
+ product_name: string;
84257
+ row_count: number;
84258
+ }[];
84259
+ };
82688
84260
  try_debtor_lock: {
82689
84261
  Args: {
82690
84262
  _group_key: string;
@@ -84449,7 +86021,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
84449
86021
  city: string | null;
84450
86022
  country: string | null;
84451
86023
  created_at: string;
84452
- customer_id: string | null;
86024
+ customer_id: string;
84453
86025
  external_key: string | null;
84454
86026
  external_provider: string | null;
84455
86027
  floriday_location_id: string | null;
@@ -84473,7 +86045,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
84473
86045
  city?: string | null;
84474
86046
  country?: string | null;
84475
86047
  created_at?: string;
84476
- customer_id?: string | null;
86048
+ customer_id: string;
84477
86049
  external_key?: string | null;
84478
86050
  external_provider?: string | null;
84479
86051
  floriday_location_id?: string | null;
@@ -84497,7 +86069,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
84497
86069
  city?: string | null;
84498
86070
  country?: string | null;
84499
86071
  created_at?: string;
84500
- customer_id?: string | null;
86072
+ customer_id?: string;
84501
86073
  external_key?: string | null;
84502
86074
  external_provider?: string | null;
84503
86075
  floriday_location_id?: string | null;
@@ -89245,6 +90817,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
89245
90817
  Row: {
89246
90818
  buyer_organization_id: string | null;
89247
90819
  connection_id: string;
90820
+ controlled_at: string | null;
89248
90821
  created_at: string;
89249
90822
  data: import("../integrations/supabase/types").Json;
89250
90823
  floriday_id: string;
@@ -89256,6 +90829,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
89256
90829
  Insert: {
89257
90830
  buyer_organization_id?: string | null;
89258
90831
  connection_id: string;
90832
+ controlled_at?: string | null;
89259
90833
  created_at?: string;
89260
90834
  data: import("../integrations/supabase/types").Json;
89261
90835
  floriday_id: string;
@@ -89267,6 +90841,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
89267
90841
  Update: {
89268
90842
  buyer_organization_id?: string | null;
89269
90843
  connection_id?: string;
90844
+ controlled_at?: string | null;
89270
90845
  created_at?: string;
89271
90846
  data?: import("../integrations/supabase/types").Json;
89272
90847
  floriday_id?: string;
@@ -90168,6 +91743,54 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
90168
91743
  };
90169
91744
  Relationships: [];
90170
91745
  };
91746
+ invoice_timing_settings: {
91747
+ Row: {
91748
+ anchor: string;
91749
+ business_days_only: boolean;
91750
+ created_at: string;
91751
+ enabled: boolean;
91752
+ id: string;
91753
+ offset_days: number;
91754
+ pickup_anchor: string;
91755
+ pickup_business_days_only: boolean;
91756
+ pickup_offset_days: number;
91757
+ pickup_time_of_day: string;
91758
+ singleton: boolean;
91759
+ time_of_day: string;
91760
+ updated_at: string;
91761
+ };
91762
+ Insert: {
91763
+ anchor?: string;
91764
+ business_days_only?: boolean;
91765
+ created_at?: string;
91766
+ enabled?: boolean;
91767
+ id?: string;
91768
+ offset_days?: number;
91769
+ pickup_anchor?: string;
91770
+ pickup_business_days_only?: boolean;
91771
+ pickup_offset_days?: number;
91772
+ pickup_time_of_day?: string;
91773
+ singleton?: boolean;
91774
+ time_of_day?: string;
91775
+ updated_at?: string;
91776
+ };
91777
+ Update: {
91778
+ anchor?: string;
91779
+ business_days_only?: boolean;
91780
+ created_at?: string;
91781
+ enabled?: boolean;
91782
+ id?: string;
91783
+ offset_days?: number;
91784
+ pickup_anchor?: string;
91785
+ pickup_business_days_only?: boolean;
91786
+ pickup_offset_days?: number;
91787
+ pickup_time_of_day?: string;
91788
+ singleton?: boolean;
91789
+ time_of_day?: string;
91790
+ updated_at?: string;
91791
+ };
91792
+ Relationships: [];
91793
+ };
90171
91794
  itk_contact_persons: {
90172
91795
  Row: {
90173
91796
  created_at: string;
@@ -91398,6 +93021,45 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
91398
93021
  };
91399
93022
  Relationships: [];
91400
93023
  };
93024
+ logistics_plan_queue: {
93025
+ Row: {
93026
+ attempts: number;
93027
+ claimed_at: string | null;
93028
+ enqueued_at: string;
93029
+ error: string | null;
93030
+ id: string;
93031
+ next_attempt_at: string;
93032
+ order_id: string;
93033
+ reason: string;
93034
+ status: string;
93035
+ updated_at: string;
93036
+ };
93037
+ Insert: {
93038
+ attempts?: number;
93039
+ claimed_at?: string | null;
93040
+ enqueued_at?: string;
93041
+ error?: string | null;
93042
+ id?: string;
93043
+ next_attempt_at?: string;
93044
+ order_id: string;
93045
+ reason?: string;
93046
+ status?: string;
93047
+ updated_at?: string;
93048
+ };
93049
+ Update: {
93050
+ attempts?: number;
93051
+ claimed_at?: string | null;
93052
+ enqueued_at?: string;
93053
+ error?: string | null;
93054
+ id?: string;
93055
+ next_attempt_at?: string;
93056
+ order_id?: string;
93057
+ reason?: string;
93058
+ status?: string;
93059
+ updated_at?: string;
93060
+ };
93061
+ Relationships: [];
93062
+ };
91401
93063
  logistics_plan_runs: {
91402
93064
  Row: {
91403
93065
  created_at: string;
@@ -91473,6 +93135,24 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
91473
93135
  referencedColumns: ["id"];
91474
93136
  }];
91475
93137
  };
93138
+ logistics_plan_settings: {
93139
+ Row: {
93140
+ key: string;
93141
+ updated_at: string;
93142
+ value: string;
93143
+ };
93144
+ Insert: {
93145
+ key: string;
93146
+ updated_at?: string;
93147
+ value: string;
93148
+ };
93149
+ Update: {
93150
+ key?: string;
93151
+ updated_at?: string;
93152
+ value?: string;
93153
+ };
93154
+ Relationships: [];
93155
+ };
91476
93156
  logistics_rebuffer_state: {
91477
93157
  Row: {
91478
93158
  created_at: string;
@@ -92183,14 +93863,17 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
92183
93863
  };
92184
93864
  mailbox_messages: {
92185
93865
  Row: {
93866
+ attachments: import("../integrations/supabase/types").Json;
92186
93867
  body_html: string | null;
92187
93868
  body_text: string | null;
93869
+ cc_recipients: import("../integrations/supabase/types").Json;
92188
93870
  connection_id: string | null;
92189
93871
  created_at: string;
92190
93872
  error_message: string | null;
92191
93873
  external_id: string | null;
92192
93874
  from_email: string | null;
92193
93875
  from_name: string | null;
93876
+ has_attachments: boolean;
92194
93877
  id: string;
92195
93878
  message_id: string | null;
92196
93879
  profile_id: string | null;
@@ -92198,18 +93881,22 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
92198
93881
  received_at: string | null;
92199
93882
  status: string;
92200
93883
  subject: string | null;
93884
+ to_recipients: import("../integrations/supabase/types").Json;
92201
93885
  uid: number | null;
92202
93886
  updated_at: string;
92203
93887
  };
92204
93888
  Insert: {
93889
+ attachments?: import("../integrations/supabase/types").Json;
92205
93890
  body_html?: string | null;
92206
93891
  body_text?: string | null;
93892
+ cc_recipients?: import("../integrations/supabase/types").Json;
92207
93893
  connection_id?: string | null;
92208
93894
  created_at?: string;
92209
93895
  error_message?: string | null;
92210
93896
  external_id?: string | null;
92211
93897
  from_email?: string | null;
92212
93898
  from_name?: string | null;
93899
+ has_attachments?: boolean;
92213
93900
  id?: string;
92214
93901
  message_id?: string | null;
92215
93902
  profile_id?: string | null;
@@ -92217,18 +93904,22 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
92217
93904
  received_at?: string | null;
92218
93905
  status?: string;
92219
93906
  subject?: string | null;
93907
+ to_recipients?: import("../integrations/supabase/types").Json;
92220
93908
  uid?: number | null;
92221
93909
  updated_at?: string;
92222
93910
  };
92223
93911
  Update: {
93912
+ attachments?: import("../integrations/supabase/types").Json;
92224
93913
  body_html?: string | null;
92225
93914
  body_text?: string | null;
93915
+ cc_recipients?: import("../integrations/supabase/types").Json;
92226
93916
  connection_id?: string | null;
92227
93917
  created_at?: string;
92228
93918
  error_message?: string | null;
92229
93919
  external_id?: string | null;
92230
93920
  from_email?: string | null;
92231
93921
  from_name?: string | null;
93922
+ has_attachments?: boolean;
92232
93923
  id?: string;
92233
93924
  message_id?: string | null;
92234
93925
  profile_id?: string | null;
@@ -92236,6 +93927,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
92236
93927
  received_at?: string | null;
92237
93928
  status?: string;
92238
93929
  subject?: string | null;
93930
+ to_recipients?: import("../integrations/supabase/types").Json;
92239
93931
  uid?: number | null;
92240
93932
  updated_at?: string;
92241
93933
  };
@@ -92643,6 +94335,36 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
92643
94335
  };
92644
94336
  Relationships: [];
92645
94337
  };
94338
+ module_registry: {
94339
+ Row: {
94340
+ created_at: string;
94341
+ is_active: boolean;
94342
+ last_seen_at: string;
94343
+ module_id: string;
94344
+ name: string;
94345
+ shell_id: string | null;
94346
+ sort_order: number | null;
94347
+ };
94348
+ Insert: {
94349
+ created_at?: string;
94350
+ is_active?: boolean;
94351
+ last_seen_at?: string;
94352
+ module_id: string;
94353
+ name: string;
94354
+ shell_id?: string | null;
94355
+ sort_order?: number | null;
94356
+ };
94357
+ Update: {
94358
+ created_at?: string;
94359
+ is_active?: boolean;
94360
+ last_seen_at?: string;
94361
+ module_id?: string;
94362
+ name?: string;
94363
+ shell_id?: string | null;
94364
+ sort_order?: number | null;
94365
+ };
94366
+ Relationships: [];
94367
+ };
92646
94368
  module_runtime_config: {
92647
94369
  Row: {
92648
94370
  key: string;
@@ -93702,6 +95424,45 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
93702
95424
  };
93703
95425
  Relationships: [];
93704
95426
  };
95427
+ order_invoice_links: {
95428
+ Row: {
95429
+ attempts: number;
95430
+ created_at: string;
95431
+ error_message: string | null;
95432
+ id: string;
95433
+ invoice_number: string | null;
95434
+ next_attempt_at: string;
95435
+ order_id: string;
95436
+ processed_at: string | null;
95437
+ status: string;
95438
+ updated_at: string;
95439
+ };
95440
+ Insert: {
95441
+ attempts?: number;
95442
+ created_at?: string;
95443
+ error_message?: string | null;
95444
+ id?: string;
95445
+ invoice_number?: string | null;
95446
+ next_attempt_at?: string;
95447
+ order_id: string;
95448
+ processed_at?: string | null;
95449
+ status?: string;
95450
+ updated_at?: string;
95451
+ };
95452
+ Update: {
95453
+ attempts?: number;
95454
+ created_at?: string;
95455
+ error_message?: string | null;
95456
+ id?: string;
95457
+ invoice_number?: string | null;
95458
+ next_attempt_at?: string;
95459
+ order_id?: string;
95460
+ processed_at?: string | null;
95461
+ status?: string;
95462
+ updated_at?: string;
95463
+ };
95464
+ Relationships: [];
95465
+ };
93705
95466
  order_items: {
93706
95467
  Row: {
93707
95468
  crates_per_layer: number | null;
@@ -93884,6 +95645,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
93884
95645
  delivery_date: string | null;
93885
95646
  floriday_sales_order_id: string | null;
93886
95647
  id: string;
95648
+ invoice_due_at: string | null;
93887
95649
  is_reservation: boolean;
93888
95650
  notes: string | null;
93889
95651
  order_date: string;
@@ -93905,6 +95667,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
93905
95667
  delivery_date?: string | null;
93906
95668
  floriday_sales_order_id?: string | null;
93907
95669
  id?: string;
95670
+ invoice_due_at?: string | null;
93908
95671
  is_reservation?: boolean;
93909
95672
  notes?: string | null;
93910
95673
  order_date?: string;
@@ -93926,6 +95689,7 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
93926
95689
  delivery_date?: string | null;
93927
95690
  floriday_sales_order_id?: string | null;
93928
95691
  id?: string;
95692
+ invoice_due_at?: string | null;
93929
95693
  is_reservation?: boolean;
93930
95694
  notes?: string | null;
93931
95695
  order_date?: string;
@@ -95223,6 +96987,63 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
95223
96987
  referencedColumns: ["id"];
95224
96988
  }];
95225
96989
  };
96990
+ print_queue_runners: {
96991
+ Row: {
96992
+ actief: boolean;
96993
+ basis_url: string;
96994
+ created_at: string;
96995
+ id: string;
96996
+ laatst_gezien: string;
96997
+ tick_sleutel: string;
96998
+ updated_at: string;
96999
+ };
97000
+ Insert: {
97001
+ actief?: boolean;
97002
+ basis_url: string;
97003
+ created_at?: string;
97004
+ id?: string;
97005
+ laatst_gezien?: string;
97006
+ tick_sleutel?: string;
97007
+ updated_at?: string;
97008
+ };
97009
+ Update: {
97010
+ actief?: boolean;
97011
+ basis_url?: string;
97012
+ created_at?: string;
97013
+ id?: string;
97014
+ laatst_gezien?: string;
97015
+ tick_sleutel?: string;
97016
+ updated_at?: string;
97017
+ };
97018
+ Relationships: [];
97019
+ };
97020
+ print_queue_settings: {
97021
+ Row: {
97022
+ bewaar_bestanden_dagen: number;
97023
+ bewaar_opdrachten_dagen: number;
97024
+ created_at: string;
97025
+ dubbel_venster_minuten: number;
97026
+ id: string;
97027
+ updated_at: string;
97028
+ };
97029
+ Insert: {
97030
+ bewaar_bestanden_dagen?: number;
97031
+ bewaar_opdrachten_dagen?: number;
97032
+ created_at?: string;
97033
+ dubbel_venster_minuten?: number;
97034
+ id?: string;
97035
+ updated_at?: string;
97036
+ };
97037
+ Update: {
97038
+ bewaar_bestanden_dagen?: number;
97039
+ bewaar_opdrachten_dagen?: number;
97040
+ created_at?: string;
97041
+ dubbel_venster_minuten?: number;
97042
+ id?: string;
97043
+ updated_at?: string;
97044
+ };
97045
+ Relationships: [];
97046
+ };
95226
97047
  print_rules: {
95227
97048
  Row: {
95228
97049
  actief: boolean;
@@ -98063,6 +99884,8 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
98063
99884
  };
98064
99885
  twinfield_invoice_settings: {
98065
99886
  Row: {
99887
+ auto_invoice_enabled: boolean;
99888
+ auto_invoice_trigger_statuses: string[];
98066
99889
  created_at: string;
98067
99890
  debtor_gl_account: string;
98068
99891
  default_credit_invoice_type: string | null;
@@ -98083,6 +99906,8 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
98083
99906
  vat_code_export: string | null;
98084
99907
  };
98085
99908
  Insert: {
99909
+ auto_invoice_enabled?: boolean;
99910
+ auto_invoice_trigger_statuses?: string[];
98086
99911
  created_at?: string;
98087
99912
  debtor_gl_account?: string;
98088
99913
  default_credit_invoice_type?: string | null;
@@ -98103,6 +99928,8 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
98103
99928
  vat_code_export?: string | null;
98104
99929
  };
98105
99930
  Update: {
99931
+ auto_invoice_enabled?: boolean;
99932
+ auto_invoice_trigger_statuses?: string[];
98106
99933
  created_at?: string;
98107
99934
  debtor_gl_account?: string;
98108
99935
  default_credit_invoice_type?: string | null;
@@ -99165,6 +100992,33 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
99165
100992
  referencedColumns: ["id"];
99166
100993
  }];
99167
100994
  };
100995
+ user_module_permissions: {
100996
+ Row: {
100997
+ created_at: string;
100998
+ id: string;
100999
+ module_id: string;
101000
+ permission: string;
101001
+ updated_at: string;
101002
+ user_id: string;
101003
+ };
101004
+ Insert: {
101005
+ created_at?: string;
101006
+ id?: string;
101007
+ module_id: string;
101008
+ permission: string;
101009
+ updated_at?: string;
101010
+ user_id: string;
101011
+ };
101012
+ Update: {
101013
+ created_at?: string;
101014
+ id?: string;
101015
+ module_id?: string;
101016
+ permission?: string;
101017
+ updated_at?: string;
101018
+ user_id?: string;
101019
+ };
101020
+ Relationships: [];
101021
+ };
99168
101022
  user_roles: {
99169
101023
  Row: {
99170
101024
  created_at: string;
@@ -100998,6 +102852,10 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
100998
102852
  processed_items: number;
100999
102853
  }[];
101000
102854
  };
102855
+ backfill_order_auto_invoice_queue: {
102856
+ Args: never;
102857
+ Returns: number;
102858
+ };
101001
102859
  calculate_layer_stock: {
101002
102860
  Args: {
101003
102861
  p_product_id: string;
@@ -101228,6 +103086,10 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
101228
103086
  Args: never;
101229
103087
  Returns: undefined;
101230
103088
  };
103089
+ cleanup_voorraad_module_history: {
103090
+ Args: never;
103091
+ Returns: undefined;
103092
+ };
101231
103093
  complete_floriday_stock_queue: {
101232
103094
  Args: {
101233
103095
  p_attempt_id?: string;
@@ -101349,6 +103211,13 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
101349
103211
  };
101350
103212
  Returns: import("../integrations/supabase/types").Json;
101351
103213
  };
103214
+ effective_module_permission: {
103215
+ Args: {
103216
+ _module_id: string;
103217
+ _user_id: string;
103218
+ };
103219
+ Returns: string;
103220
+ };
101352
103221
  email_auth_decrypt: {
101353
103222
  Args: {
101354
103223
  cipher: string;
@@ -102249,6 +104118,65 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
102249
104118
  };
102250
104119
  Returns: number;
102251
104120
  };
104121
+ logistics_plan_claim: {
104122
+ Args: {
104123
+ p_limit?: number;
104124
+ };
104125
+ Returns: {
104126
+ attempts: number;
104127
+ id: string;
104128
+ order_id: string;
104129
+ }[];
104130
+ };
104131
+ logistics_plan_enqueue: {
104132
+ Args: {
104133
+ p_order_id: string;
104134
+ p_reason?: string;
104135
+ };
104136
+ Returns: undefined;
104137
+ };
104138
+ logistics_plan_ensure_event: {
104139
+ Args: {
104140
+ p_order_id: string;
104141
+ };
104142
+ Returns: boolean;
104143
+ };
104144
+ logistics_plan_finish: {
104145
+ Args: {
104146
+ p_error?: string;
104147
+ p_id: string;
104148
+ };
104149
+ Returns: undefined;
104150
+ };
104151
+ logistics_plan_impact_orders: {
104152
+ Args: {
104153
+ p_order_id: string;
104154
+ };
104155
+ Returns: {
104156
+ buffer_id: string;
104157
+ order_id: string;
104158
+ plan_date: string;
104159
+ }[];
104160
+ };
104161
+ logistics_plan_kick: {
104162
+ Args: never;
104163
+ Returns: undefined;
104164
+ };
104165
+ logistics_plan_prune: {
104166
+ Args: never;
104167
+ Returns: number;
104168
+ };
104169
+ logistics_plan_release_stale: {
104170
+ Args: never;
104171
+ Returns: number;
104172
+ };
104173
+ logistics_plan_setting: {
104174
+ Args: {
104175
+ p_default: number;
104176
+ p_key: string;
104177
+ };
104178
+ Returns: number;
104179
+ };
102252
104180
  logistics_queue_capacity_email: {
102253
104181
  Args: {
102254
104182
  p_alert_id: string;
@@ -102487,6 +104415,13 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
102487
104415
  };
102488
104416
  Returns: undefined;
102489
104417
  };
104418
+ my_module_permissions: {
104419
+ Args: never;
104420
+ Returns: {
104421
+ module_id: string;
104422
+ permission: string;
104423
+ }[];
104424
+ };
102490
104425
  next_manufacture_partij: {
102491
104426
  Args: {
102492
104427
  _tenant_id: string;
@@ -102537,6 +104472,13 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
102537
104472
  };
102538
104473
  Returns: boolean;
102539
104474
  };
104475
+ opruim_print_historie: {
104476
+ Args: never;
104477
+ Returns: {
104478
+ ontdaan: number;
104479
+ verwijderd: number;
104480
+ }[];
104481
+ };
102540
104482
  order_number_prefix: {
102541
104483
  Args: {
102542
104484
  p_custom_fields?: import("../integrations/supabase/types").Json;
@@ -102931,6 +104873,12 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
102931
104873
  };
102932
104874
  Returns: undefined;
102933
104875
  };
104876
+ reset_stalled_floriday_stock_queue: {
104877
+ Args: {
104878
+ p_include_failed?: boolean;
104879
+ };
104880
+ Returns: number;
104881
+ };
102934
104882
  resolve_group_allocation: {
102935
104883
  Args: {
102936
104884
  _needed: number;
@@ -102985,10 +104933,18 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
102985
104933
  Args: never;
102986
104934
  Returns: undefined;
102987
104935
  };
104936
+ run_floriday_stock_queue_process: {
104937
+ Args: never;
104938
+ Returns: undefined;
104939
+ };
102988
104940
  run_logistics_tasks_dispatch: {
102989
104941
  Args: never;
102990
104942
  Returns: undefined;
102991
104943
  };
104944
+ run_print_queue_ticks: {
104945
+ Args: never;
104946
+ Returns: number;
104947
+ };
102992
104948
  run_twinfield_queue_tick: {
102993
104949
  Args: never;
102994
104950
  Returns: undefined;
@@ -103376,6 +105332,15 @@ export declare const previewLoadCarrierPlan: import("@tanstack/start-client-core
103376
105332
  };
103377
105333
  Returns: undefined;
103378
105334
  };
105335
+ trade_item_stock_duplicates: {
105336
+ Args: never;
105337
+ Returns: {
105338
+ keys: string[];
105339
+ product_id: string;
105340
+ product_name: string;
105341
+ row_count: number;
105342
+ }[];
105343
+ };
103379
105344
  try_debtor_lock: {
103380
105345
  Args: {
103381
105346
  _group_key: string;