@flowselections/floriday-afhandeling-module 1.0.10 → 1.0.11

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 (69) hide show
  1. package/dist-lib/components/afhandeling/ControleLijstPrint.d.ts +7 -0
  2. package/dist-lib/components/afhandeling/ControleLijstPrint.d.ts.map +1 -0
  3. package/dist-lib/components/afhandeling/ControleLijstPrint.js +67 -0
  4. package/dist-lib/components/afhandeling/ControlePage.d.ts +2 -0
  5. package/dist-lib/components/afhandeling/ControlePage.d.ts.map +1 -0
  6. package/dist-lib/components/afhandeling/ControlePage.js +456 -0
  7. package/dist-lib/components/afhandeling/DagDetailDialog.d.ts.map +1 -1
  8. package/dist-lib/components/afhandeling/DagDetailDialog.js +9 -5
  9. package/dist-lib/components/afhandeling/VervoerderForm.d.ts.map +1 -1
  10. package/dist-lib/components/afhandeling/VervoerderForm.js +10 -1
  11. package/dist-lib/components/afhandeling/VervoerdersPage.d.ts.map +1 -1
  12. package/dist-lib/components/afhandeling/VervoerdersPage.js +3 -2
  13. package/dist-lib/components/afhandeling/WeekAgendaView.d.ts.map +1 -1
  14. package/dist-lib/components/afhandeling/WeekAgendaView.js +15 -5
  15. package/dist-lib/components/afhandeling/WeekdayPicker.d.ts +12 -0
  16. package/dist-lib/components/afhandeling/WeekdayPicker.d.ts.map +1 -0
  17. package/dist-lib/components/afhandeling/WeekdayPicker.js +30 -0
  18. package/dist-lib/components/pickstation/PakbonTemplate.d.ts +1 -0
  19. package/dist-lib/components/pickstation/PakbonTemplate.d.ts.map +1 -1
  20. package/dist-lib/components/pickstation/PakbonTemplate.js +31 -8
  21. package/dist-lib/components/settings/AfhandelingSettingsCard.d.ts.map +1 -1
  22. package/dist-lib/components/settings/AfhandelingSettingsCard.js +9 -2
  23. package/dist-lib/components/ui/responsive-dialog.d.ts +20 -0
  24. package/dist-lib/components/ui/responsive-dialog.d.ts.map +1 -0
  25. package/dist-lib/components/ui/responsive-dialog.js +44 -0
  26. package/dist-lib/hooks/useOrderPlanning.d.ts.map +1 -1
  27. package/dist-lib/hooks/useOrderPlanning.js +17 -6
  28. package/dist-lib/index.d.ts +1 -0
  29. package/dist-lib/index.d.ts.map +1 -1
  30. package/dist-lib/index.js +4 -2
  31. package/dist-lib/integrations/supabase/auth-middleware.d.ts +629 -3
  32. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  33. package/dist-lib/integrations/supabase/client.d.ts +629 -3
  34. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  35. package/dist-lib/integrations/supabase/client.server.d.ts +629 -3
  36. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  37. package/dist-lib/integrations/supabase/types.d.ts +639 -3
  38. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  39. package/dist-lib/lib/afhandelingSettings.functions.d.ts +1318 -62
  40. package/dist-lib/lib/afhandelingSettings.functions.d.ts.map +1 -1
  41. package/dist-lib/lib/afhandelingSettings.functions.js +16 -1
  42. package/dist-lib/lib/carrierMatch.server.d.ts +27 -0
  43. package/dist-lib/lib/carrierMatch.server.d.ts.map +1 -0
  44. package/dist-lib/lib/carrierMatch.server.js +75 -0
  45. package/dist-lib/lib/carriers.functions.d.ts +3151 -15
  46. package/dist-lib/lib/carriers.functions.d.ts.map +1 -1
  47. package/dist-lib/lib/carriers.functions.js +17 -2
  48. package/dist-lib/lib/cartAssignments.functions.d.ts +3145 -15
  49. package/dist-lib/lib/cartAssignments.functions.d.ts.map +1 -1
  50. package/dist-lib/lib/cartControl.functions.d.ts +99259 -0
  51. package/dist-lib/lib/cartControl.functions.d.ts.map +1 -0
  52. package/dist-lib/lib/cartControl.functions.js +489 -0
  53. package/dist-lib/lib/cartRescheduling.d.ts +30 -0
  54. package/dist-lib/lib/cartRescheduling.d.ts.map +1 -0
  55. package/dist-lib/lib/cartRescheduling.js +71 -0
  56. package/dist-lib/lib/floriday.functions.d.ts +629 -3
  57. package/dist-lib/lib/floriday.functions.d.ts.map +1 -1
  58. package/dist-lib/lib/pickstationI18n.d.ts +8 -0
  59. package/dist-lib/lib/pickstationI18n.d.ts.map +1 -1
  60. package/dist-lib/lib/pickstationI18n.js +48 -0
  61. package/dist-lib/lib/pickstationOrders.server.d.ts +1 -0
  62. package/dist-lib/lib/pickstationOrders.server.d.ts.map +1 -1
  63. package/dist-lib/lib/pickstationOrders.server.js +94 -7
  64. package/dist-lib/lib/pickstationTypes.d.ts +12 -0
  65. package/dist-lib/lib/pickstationTypes.d.ts.map +1 -1
  66. package/dist-lib/lib/planning.d.ts +23 -0
  67. package/dist-lib/lib/planning.d.ts.map +1 -1
  68. package/dist-lib/lib/planning.js +66 -6
  69. package/package.json +1 -1
@@ -7,6 +7,8 @@ export interface AfhandelingSettings {
7
7
  signupMailEnabled: boolean;
8
8
  signupMailLeadMinutes: number;
9
9
  signupMailPurpose: string;
10
+ /** ISO-dagnummers (1=ma … 7=zo) waarop gepickt mag worden. */
11
+ pickWeekdays: number[];
10
12
  }
11
13
  export declare const getAfhandelingSettings: import("@tanstack/start-client-core").OptionalFetcher<readonly [import("@tanstack/start-client-core").FunctionMiddlewareAfterServer<{}, unknown, undefined, {
12
14
  supabase: SupabaseClient<import("../integrations/supabase/types").Database, "public", "public", {
@@ -18,6 +20,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
18
20
  max_workdays_earlier_pick: number;
19
21
  pick_days_before_transport: number;
20
22
  pick_distribution_enabled: boolean;
23
+ pick_weekdays: number[];
21
24
  signup_mail_enabled: boolean;
22
25
  signup_mail_lead_minutes: number;
23
26
  signup_mail_purpose: string;
@@ -31,6 +34,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
31
34
  max_workdays_earlier_pick?: number;
32
35
  pick_days_before_transport?: number;
33
36
  pick_distribution_enabled?: boolean;
37
+ pick_weekdays?: number[];
34
38
  signup_mail_enabled?: boolean;
35
39
  signup_mail_lead_minutes?: number;
36
40
  signup_mail_purpose?: string;
@@ -44,6 +48,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
44
48
  max_workdays_earlier_pick?: number;
45
49
  pick_days_before_transport?: number;
46
50
  pick_distribution_enabled?: boolean;
51
+ pick_weekdays?: number[];
47
52
  signup_mail_enabled?: boolean;
48
53
  signup_mail_lead_minutes?: number;
49
54
  signup_mail_purpose?: string;
@@ -455,6 +460,48 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
455
460
  referencedColumns: ["id"];
456
461
  }];
457
462
  };
463
+ carrier_signup_dispatch_runs: {
464
+ Row: {
465
+ detail: import("../integrations/supabase/types").Json | null;
466
+ error: string | null;
467
+ finished_at: string | null;
468
+ groups: number;
469
+ id: string;
470
+ ok: boolean;
471
+ reason: string | null;
472
+ sent: number;
473
+ skipped: import("../integrations/supabase/types").Json;
474
+ started_at: string;
475
+ unassigned: import("../integrations/supabase/types").Json;
476
+ };
477
+ Insert: {
478
+ detail?: import("../integrations/supabase/types").Json | null;
479
+ error?: string | null;
480
+ finished_at?: string | null;
481
+ groups?: number;
482
+ id?: string;
483
+ ok?: boolean;
484
+ reason?: string | null;
485
+ sent?: number;
486
+ skipped?: import("../integrations/supabase/types").Json;
487
+ started_at?: string;
488
+ unassigned?: import("../integrations/supabase/types").Json;
489
+ };
490
+ Update: {
491
+ detail?: import("../integrations/supabase/types").Json | null;
492
+ error?: string | null;
493
+ finished_at?: string | null;
494
+ groups?: number;
495
+ id?: string;
496
+ ok?: boolean;
497
+ reason?: string | null;
498
+ sent?: number;
499
+ skipped?: import("../integrations/supabase/types").Json;
500
+ started_at?: string;
501
+ unassigned?: import("../integrations/supabase/types").Json;
502
+ };
503
+ Relationships: [];
504
+ };
458
505
  carrier_signup_dispatches: {
459
506
  Row: {
460
507
  carrier_id: string;
@@ -506,6 +553,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
506
553
  contact_person: string | null;
507
554
  created_at: string;
508
555
  delivery_days: number | null;
556
+ delivery_weekdays: number[];
509
557
  email: string | null;
510
558
  id: string;
511
559
  is_default: boolean;
@@ -513,6 +561,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
513
561
  notes: string | null;
514
562
  phone: string | null;
515
563
  pickup_moments: import("../integrations/supabase/types").Json;
564
+ pickup_weekdays: number[];
516
565
  service_cities: string[];
517
566
  service_countries: string[];
518
567
  service_provinces: string[];
@@ -528,6 +577,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
528
577
  contact_person?: string | null;
529
578
  created_at?: string;
530
579
  delivery_days?: number | null;
580
+ delivery_weekdays?: number[];
531
581
  email?: string | null;
532
582
  id?: string;
533
583
  is_default?: boolean;
@@ -535,6 +585,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
535
585
  notes?: string | null;
536
586
  phone?: string | null;
537
587
  pickup_moments?: import("../integrations/supabase/types").Json;
588
+ pickup_weekdays?: number[];
538
589
  service_cities?: string[];
539
590
  service_countries?: string[];
540
591
  service_provinces?: string[];
@@ -550,6 +601,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
550
601
  contact_person?: string | null;
551
602
  created_at?: string;
552
603
  delivery_days?: number | null;
604
+ delivery_weekdays?: number[];
553
605
  email?: string | null;
554
606
  id?: string;
555
607
  is_default?: boolean;
@@ -557,6 +609,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
557
609
  notes?: string | null;
558
610
  phone?: string | null;
559
611
  pickup_moments?: import("../integrations/supabase/types").Json;
612
+ pickup_weekdays?: number[];
560
613
  service_cities?: string[];
561
614
  service_countries?: string[];
562
615
  service_provinces?: string[];
@@ -569,6 +622,177 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
569
622
  };
570
623
  Relationships: [];
571
624
  };
625
+ cart_control_draft: {
626
+ Row: {
627
+ cart_states: import("../integrations/supabase/types").Json;
628
+ checked_keys: import("../integrations/supabase/types").Json;
629
+ draft_date: string;
630
+ form_state: import("../integrations/supabase/types").Json;
631
+ notes: string;
632
+ updated_at: string;
633
+ user_id: string;
634
+ };
635
+ Insert: {
636
+ cart_states?: import("../integrations/supabase/types").Json;
637
+ checked_keys?: import("../integrations/supabase/types").Json;
638
+ draft_date: string;
639
+ form_state?: import("../integrations/supabase/types").Json;
640
+ notes?: string;
641
+ updated_at?: string;
642
+ user_id: string;
643
+ };
644
+ Update: {
645
+ cart_states?: import("../integrations/supabase/types").Json;
646
+ checked_keys?: import("../integrations/supabase/types").Json;
647
+ draft_date?: string;
648
+ form_state?: import("../integrations/supabase/types").Json;
649
+ notes?: string;
650
+ updated_at?: string;
651
+ user_id?: string;
652
+ };
653
+ Relationships: [];
654
+ };
655
+ cart_control_items: {
656
+ Row: {
657
+ action: string;
658
+ block_reason: string | null;
659
+ carrier_name: string | null;
660
+ cart_index: number;
661
+ cart_number_id: string | null;
662
+ cart_number_label: string | null;
663
+ created_at: string;
664
+ customer_name: string | null;
665
+ delivery_date: string | null;
666
+ id: string;
667
+ new_pick_date: string | null;
668
+ order_id: string;
669
+ order_number: string | null;
670
+ order_source: string;
671
+ pickup_date: string | null;
672
+ session_id: string;
673
+ };
674
+ Insert: {
675
+ action: string;
676
+ block_reason?: string | null;
677
+ carrier_name?: string | null;
678
+ cart_index: number;
679
+ cart_number_id?: string | null;
680
+ cart_number_label?: string | null;
681
+ created_at?: string;
682
+ customer_name?: string | null;
683
+ delivery_date?: string | null;
684
+ id?: string;
685
+ new_pick_date?: string | null;
686
+ order_id: string;
687
+ order_number?: string | null;
688
+ order_source: string;
689
+ pickup_date?: string | null;
690
+ session_id: string;
691
+ };
692
+ Update: {
693
+ action?: string;
694
+ block_reason?: string | null;
695
+ carrier_name?: string | null;
696
+ cart_index?: number;
697
+ cart_number_id?: string | null;
698
+ cart_number_label?: string | null;
699
+ created_at?: string;
700
+ customer_name?: string | null;
701
+ delivery_date?: string | null;
702
+ id?: string;
703
+ new_pick_date?: string | null;
704
+ order_id?: string;
705
+ order_number?: string | null;
706
+ order_source?: string;
707
+ pickup_date?: string | null;
708
+ session_id?: string;
709
+ };
710
+ Relationships: [{
711
+ foreignKeyName: "cart_control_items_session_id_fkey";
712
+ columns: ["session_id"];
713
+ isOneToOne: false;
714
+ referencedRelation: "cart_control_sessions";
715
+ referencedColumns: ["id"];
716
+ }];
717
+ };
718
+ cart_control_sessions: {
719
+ Row: {
720
+ blocked_count: number;
721
+ checked_count: number;
722
+ control_date: string;
723
+ created_at: string;
724
+ id: string;
725
+ notes: string | null;
726
+ performed_at: string;
727
+ rescheduled_count: number;
728
+ total_carts: number;
729
+ updated_at: string;
730
+ user_id: string;
731
+ };
732
+ Insert: {
733
+ blocked_count?: number;
734
+ checked_count?: number;
735
+ control_date?: string;
736
+ created_at?: string;
737
+ id?: string;
738
+ notes?: string | null;
739
+ performed_at?: string;
740
+ rescheduled_count?: number;
741
+ total_carts?: number;
742
+ updated_at?: string;
743
+ user_id: string;
744
+ };
745
+ Update: {
746
+ blocked_count?: number;
747
+ checked_count?: number;
748
+ control_date?: string;
749
+ created_at?: string;
750
+ id?: string;
751
+ notes?: string | null;
752
+ performed_at?: string;
753
+ rescheduled_count?: number;
754
+ total_carts?: number;
755
+ updated_at?: string;
756
+ user_id?: string;
757
+ };
758
+ Relationships: [];
759
+ };
760
+ cart_numbers: {
761
+ Row: {
762
+ assigned_at: string;
763
+ cart_index: number;
764
+ cart_number: string;
765
+ day_seq: number;
766
+ id: string;
767
+ order_id: string;
768
+ order_source: string;
769
+ pick_date: string;
770
+ status: string;
771
+ };
772
+ Insert: {
773
+ assigned_at?: string;
774
+ cart_index: number;
775
+ cart_number: string;
776
+ day_seq: number;
777
+ id?: string;
778
+ order_id: string;
779
+ order_source: string;
780
+ pick_date: string;
781
+ status?: string;
782
+ };
783
+ Update: {
784
+ assigned_at?: string;
785
+ cart_index?: number;
786
+ cart_number?: string;
787
+ day_seq?: number;
788
+ id?: string;
789
+ order_id?: string;
790
+ order_source?: string;
791
+ pick_date?: string;
792
+ status?: string;
793
+ };
794
+ Relationships: [];
795
+ };
572
796
  cart_pick_overrides: {
573
797
  Row: {
574
798
  cart_index: number;
@@ -1241,6 +1465,54 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
1241
1465
  referencedColumns: ["id"];
1242
1466
  }];
1243
1467
  };
1468
+ dashboard_critical_alerts: {
1469
+ Row: {
1470
+ alert_key: string;
1471
+ alert_type: string;
1472
+ created_at: string;
1473
+ description: string | null;
1474
+ id: string;
1475
+ metadata: import("../integrations/supabase/types").Json | null;
1476
+ priority: string;
1477
+ raised_at: string;
1478
+ related_cart_ids: string[] | null;
1479
+ resolved_at: string | null;
1480
+ title: string;
1481
+ updated_at: string;
1482
+ user_id: string;
1483
+ };
1484
+ Insert: {
1485
+ alert_key: string;
1486
+ alert_type: string;
1487
+ created_at?: string;
1488
+ description?: string | null;
1489
+ id?: string;
1490
+ metadata?: import("../integrations/supabase/types").Json | null;
1491
+ priority?: string;
1492
+ raised_at?: string;
1493
+ related_cart_ids?: string[] | null;
1494
+ resolved_at?: string | null;
1495
+ title: string;
1496
+ updated_at?: string;
1497
+ user_id: string;
1498
+ };
1499
+ Update: {
1500
+ alert_key?: string;
1501
+ alert_type?: string;
1502
+ created_at?: string;
1503
+ description?: string | null;
1504
+ id?: string;
1505
+ metadata?: import("../integrations/supabase/types").Json | null;
1506
+ priority?: string;
1507
+ raised_at?: string;
1508
+ related_cart_ids?: string[] | null;
1509
+ resolved_at?: string | null;
1510
+ title?: string;
1511
+ updated_at?: string;
1512
+ user_id?: string;
1513
+ };
1514
+ Relationships: [];
1515
+ };
1244
1516
  dashboard_daily_reports: {
1245
1517
  Row: {
1246
1518
  created_at: string;
@@ -2743,6 +3015,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
2743
3015
  };
2744
3016
  floricode_sync_state: {
2745
3017
  Row: {
3018
+ cursor_skip: number;
2746
3019
  error_message: string | null;
2747
3020
  last_change_date_time: string | null;
2748
3021
  last_sequence_number: number;
@@ -2752,6 +3025,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
2752
3025
  updated_at: string;
2753
3026
  };
2754
3027
  Insert: {
3028
+ cursor_skip?: number;
2755
3029
  error_message?: string | null;
2756
3030
  last_change_date_time?: string | null;
2757
3031
  last_sequence_number?: number;
@@ -2761,6 +3035,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
2761
3035
  updated_at?: string;
2762
3036
  };
2763
3037
  Update: {
3038
+ cursor_skip?: number;
2764
3039
  error_message?: string | null;
2765
3040
  last_change_date_time?: string | null;
2766
3041
  last_sequence_number?: number;
@@ -5108,6 +5383,93 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
5108
5383
  };
5109
5384
  Relationships: [];
5110
5385
  };
5386
+ manufacture_product_components: {
5387
+ Row: {
5388
+ component_type: string;
5389
+ created_at: string;
5390
+ id: string;
5391
+ manufacture_product_id: string;
5392
+ product_group_id: string | null;
5393
+ quantity: number;
5394
+ trade_item_id: string | null;
5395
+ unit: string;
5396
+ };
5397
+ Insert: {
5398
+ component_type: string;
5399
+ created_at?: string;
5400
+ id?: string;
5401
+ manufacture_product_id: string;
5402
+ product_group_id?: string | null;
5403
+ quantity?: number;
5404
+ trade_item_id?: string | null;
5405
+ unit?: string;
5406
+ };
5407
+ Update: {
5408
+ component_type?: string;
5409
+ created_at?: string;
5410
+ id?: string;
5411
+ manufacture_product_id?: string;
5412
+ product_group_id?: string | null;
5413
+ quantity?: number;
5414
+ trade_item_id?: string | null;
5415
+ unit?: string;
5416
+ };
5417
+ Relationships: [{
5418
+ foreignKeyName: "manufacture_product_components_manufacture_product_id_fkey";
5419
+ columns: ["manufacture_product_id"];
5420
+ isOneToOne: false;
5421
+ referencedRelation: "manufacture_product_possible_stock_view";
5422
+ referencedColumns: ["manufacture_product_id"];
5423
+ }, {
5424
+ foreignKeyName: "manufacture_product_components_manufacture_product_id_fkey";
5425
+ columns: ["manufacture_product_id"];
5426
+ isOneToOne: false;
5427
+ referencedRelation: "manufacture_products";
5428
+ referencedColumns: ["id"];
5429
+ }, {
5430
+ foreignKeyName: "manufacture_product_components_product_group_id_fkey";
5431
+ columns: ["product_group_id"];
5432
+ isOneToOne: false;
5433
+ referencedRelation: "product_groups";
5434
+ referencedColumns: ["id"];
5435
+ }];
5436
+ };
5437
+ manufacture_products: {
5438
+ Row: {
5439
+ created_at: string;
5440
+ description: string | null;
5441
+ id: string;
5442
+ is_active: boolean;
5443
+ name: string;
5444
+ produced_stock: number;
5445
+ product_code: string;
5446
+ tenant_id: string;
5447
+ updated_at: string;
5448
+ };
5449
+ Insert: {
5450
+ created_at?: string;
5451
+ description?: string | null;
5452
+ id?: string;
5453
+ is_active?: boolean;
5454
+ name: string;
5455
+ produced_stock?: number;
5456
+ product_code: string;
5457
+ tenant_id: string;
5458
+ updated_at?: string;
5459
+ };
5460
+ Update: {
5461
+ created_at?: string;
5462
+ description?: string | null;
5463
+ id?: string;
5464
+ is_active?: boolean;
5465
+ name?: string;
5466
+ produced_stock?: number;
5467
+ product_code?: string;
5468
+ tenant_id?: string;
5469
+ updated_at?: string;
5470
+ };
5471
+ Relationships: [];
5472
+ };
5111
5473
  monteurs: {
5112
5474
  Row: {
5113
5475
  avatar_url: string | null;
@@ -6068,60 +6430,120 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
6068
6430
  };
6069
6431
  Relationships: [];
6070
6432
  };
6071
- products: {
6433
+ product_group_items: {
6072
6434
  Row: {
6073
- barcode: string | null;
6074
- batch: string;
6075
- crates_per_layer: number;
6076
6435
  created_at: string;
6077
- custom_fields: import("../integrations/supabase/types").Json;
6078
6436
  id: string;
6079
- image_url: string | null;
6080
- incoming_quantity: number;
6081
- layers_per_cart: number;
6082
- location: string;
6083
- min_quantity: number;
6084
- plants_per_crate: number;
6085
- product: string;
6086
- product_type: string;
6087
- purchase_price: number | null;
6437
+ product_group_id: string;
6088
6438
  quantity: number;
6089
- sale_price: number | null;
6090
- unit: string;
6091
- updated_at: string;
6092
- weight: string | null;
6439
+ trade_item_id: string;
6093
6440
  };
6094
6441
  Insert: {
6095
- barcode?: string | null;
6096
- batch: string;
6097
- crates_per_layer?: number;
6098
6442
  created_at?: string;
6099
- custom_fields?: import("../integrations/supabase/types").Json;
6100
6443
  id?: string;
6101
- image_url?: string | null;
6102
- incoming_quantity?: number;
6103
- layers_per_cart?: number;
6104
- location: string;
6105
- min_quantity?: number;
6106
- plants_per_crate?: number;
6107
- product: string;
6108
- product_type?: string;
6109
- purchase_price?: number | null;
6444
+ product_group_id: string;
6110
6445
  quantity?: number;
6111
- sale_price?: number | null;
6112
- unit?: string;
6113
- updated_at?: string;
6114
- weight?: string | null;
6446
+ trade_item_id: string;
6115
6447
  };
6116
6448
  Update: {
6117
- barcode?: string | null;
6118
- batch?: string;
6119
- crates_per_layer?: number;
6120
6449
  created_at?: string;
6121
- custom_fields?: import("../integrations/supabase/types").Json;
6122
6450
  id?: string;
6123
- image_url?: string | null;
6124
- incoming_quantity?: number;
6451
+ product_group_id?: string;
6452
+ quantity?: number;
6453
+ trade_item_id?: string;
6454
+ };
6455
+ Relationships: [{
6456
+ foreignKeyName: "product_group_items_product_group_id_fkey";
6457
+ columns: ["product_group_id"];
6458
+ isOneToOne: false;
6459
+ referencedRelation: "product_groups";
6460
+ referencedColumns: ["id"];
6461
+ }];
6462
+ };
6463
+ product_groups: {
6464
+ Row: {
6465
+ created_at: string;
6466
+ description: string | null;
6467
+ id: string;
6468
+ is_active: boolean;
6469
+ name: string;
6470
+ tenant_id: string;
6471
+ updated_at: string;
6472
+ };
6473
+ Insert: {
6474
+ created_at?: string;
6475
+ description?: string | null;
6476
+ id?: string;
6477
+ is_active?: boolean;
6478
+ name: string;
6479
+ tenant_id: string;
6480
+ updated_at?: string;
6481
+ };
6482
+ Update: {
6483
+ created_at?: string;
6484
+ description?: string | null;
6485
+ id?: string;
6486
+ is_active?: boolean;
6487
+ name?: string;
6488
+ tenant_id?: string;
6489
+ updated_at?: string;
6490
+ };
6491
+ Relationships: [];
6492
+ };
6493
+ products: {
6494
+ Row: {
6495
+ barcode: string | null;
6496
+ batch: string;
6497
+ crates_per_layer: number;
6498
+ created_at: string;
6499
+ custom_fields: import("../integrations/supabase/types").Json;
6500
+ id: string;
6501
+ image_url: string | null;
6502
+ incoming_quantity: number;
6503
+ layers_per_cart: number;
6504
+ location: string;
6505
+ min_quantity: number;
6506
+ plants_per_crate: number;
6507
+ product: string;
6508
+ product_type: string;
6509
+ purchase_price: number | null;
6510
+ quantity: number;
6511
+ sale_price: number | null;
6512
+ unit: string;
6513
+ updated_at: string;
6514
+ weight: string | null;
6515
+ };
6516
+ Insert: {
6517
+ barcode?: string | null;
6518
+ batch: string;
6519
+ crates_per_layer?: number;
6520
+ created_at?: string;
6521
+ custom_fields?: import("../integrations/supabase/types").Json;
6522
+ id?: string;
6523
+ image_url?: string | null;
6524
+ incoming_quantity?: number;
6525
+ layers_per_cart?: number;
6526
+ location: string;
6527
+ min_quantity?: number;
6528
+ plants_per_crate?: number;
6529
+ product: string;
6530
+ product_type?: string;
6531
+ purchase_price?: number | null;
6532
+ quantity?: number;
6533
+ sale_price?: number | null;
6534
+ unit?: string;
6535
+ updated_at?: string;
6536
+ weight?: string | null;
6537
+ };
6538
+ Update: {
6539
+ barcode?: string | null;
6540
+ batch?: string;
6541
+ crates_per_layer?: number;
6542
+ created_at?: string;
6543
+ custom_fields?: import("../integrations/supabase/types").Json;
6544
+ id?: string;
6545
+ image_url?: string | null;
6546
+ incoming_quantity?: number;
6125
6547
  layers_per_cart?: number;
6126
6548
  location?: string;
6127
6549
  min_quantity?: number;
@@ -7207,7 +7629,13 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7207
7629
  connection_id: string | null;
7208
7630
  created_at: string;
7209
7631
  data: import("../integrations/supabase/types").Json;
7632
+ floriday_id: string | null;
7633
+ floriday_link_error: string | null;
7634
+ floriday_link_status: string;
7210
7635
  id: string;
7636
+ last_floriday_sync_at: string | null;
7637
+ missing_required_fields: string[];
7638
+ source: string;
7211
7639
  updated_at: string;
7212
7640
  user_id: string;
7213
7641
  };
@@ -7215,7 +7643,13 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7215
7643
  connection_id?: string | null;
7216
7644
  created_at?: string;
7217
7645
  data?: import("../integrations/supabase/types").Json;
7646
+ floriday_id?: string | null;
7647
+ floriday_link_error?: string | null;
7648
+ floriday_link_status?: string;
7218
7649
  id?: string;
7650
+ last_floriday_sync_at?: string | null;
7651
+ missing_required_fields?: string[];
7652
+ source?: string;
7219
7653
  updated_at?: string;
7220
7654
  user_id: string;
7221
7655
  };
@@ -7223,7 +7657,55 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7223
7657
  connection_id?: string | null;
7224
7658
  created_at?: string;
7225
7659
  data?: import("../integrations/supabase/types").Json;
7660
+ floriday_id?: string | null;
7661
+ floriday_link_error?: string | null;
7662
+ floriday_link_status?: string;
7226
7663
  id?: string;
7664
+ last_floriday_sync_at?: string | null;
7665
+ missing_required_fields?: string[];
7666
+ source?: string;
7667
+ updated_at?: string;
7668
+ user_id?: string;
7669
+ };
7670
+ Relationships: [];
7671
+ };
7672
+ trade_item_stock: {
7673
+ Row: {
7674
+ connection_id: string;
7675
+ created_at: string;
7676
+ id: string;
7677
+ incoming_stock: number;
7678
+ minimum_stock: number;
7679
+ notes: string | null;
7680
+ physical_stock: number;
7681
+ reserved_stock: number;
7682
+ trade_item_key: string;
7683
+ updated_at: string;
7684
+ user_id: string;
7685
+ };
7686
+ Insert: {
7687
+ connection_id: string;
7688
+ created_at?: string;
7689
+ id?: string;
7690
+ incoming_stock?: number;
7691
+ minimum_stock?: number;
7692
+ notes?: string | null;
7693
+ physical_stock?: number;
7694
+ reserved_stock?: number;
7695
+ trade_item_key: string;
7696
+ updated_at?: string;
7697
+ user_id: string;
7698
+ };
7699
+ Update: {
7700
+ connection_id?: string;
7701
+ created_at?: string;
7702
+ id?: string;
7703
+ incoming_stock?: number;
7704
+ minimum_stock?: number;
7705
+ notes?: string | null;
7706
+ physical_stock?: number;
7707
+ reserved_stock?: number;
7708
+ trade_item_key?: string;
7227
7709
  updated_at?: string;
7228
7710
  user_id?: string;
7229
7711
  };
@@ -7573,6 +8055,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7573
8055
  };
7574
8056
  twinfield_invoice_sync_logs: {
7575
8057
  Row: {
8058
+ action_type: string | null;
7576
8059
  created_at: string;
7577
8060
  details: import("../integrations/supabase/types").Json | null;
7578
8061
  duration_ms: number | null;
@@ -7585,6 +8068,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7585
8068
  user_id: string;
7586
8069
  };
7587
8070
  Insert: {
8071
+ action_type?: string | null;
7588
8072
  created_at?: string;
7589
8073
  details?: import("../integrations/supabase/types").Json | null;
7590
8074
  duration_ms?: number | null;
@@ -7597,6 +8081,7 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7597
8081
  user_id: string;
7598
8082
  };
7599
8083
  Update: {
8084
+ action_type?: string | null;
7600
8085
  created_at?: string;
7601
8086
  details?: import("../integrations/supabase/types").Json | null;
7602
8087
  duration_ms?: number | null;
@@ -7832,6 +8317,57 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
7832
8317
  referencedColumns: ["id"];
7833
8318
  }];
7834
8319
  };
8320
+ twinfield_request_metrics: {
8321
+ Row: {
8322
+ bucket_hour: string;
8323
+ connection_id: string;
8324
+ error_count: number;
8325
+ rate_limited_count: number;
8326
+ request_count: number;
8327
+ updated_at: string;
8328
+ };
8329
+ Insert: {
8330
+ bucket_hour: string;
8331
+ connection_id: string;
8332
+ error_count?: number;
8333
+ rate_limited_count?: number;
8334
+ request_count?: number;
8335
+ updated_at?: string;
8336
+ };
8337
+ Update: {
8338
+ bucket_hour?: string;
8339
+ connection_id?: string;
8340
+ error_count?: number;
8341
+ rate_limited_count?: number;
8342
+ request_count?: number;
8343
+ updated_at?: string;
8344
+ };
8345
+ Relationships: [];
8346
+ };
8347
+ twinfield_session_cache: {
8348
+ Row: {
8349
+ cluster: string;
8350
+ created_at: string;
8351
+ expires_at: string;
8352
+ session_id: string;
8353
+ user_id: string;
8354
+ };
8355
+ Insert: {
8356
+ cluster: string;
8357
+ created_at?: string;
8358
+ expires_at: string;
8359
+ session_id: string;
8360
+ user_id: string;
8361
+ };
8362
+ Update: {
8363
+ cluster?: string;
8364
+ created_at?: string;
8365
+ expires_at?: string;
8366
+ session_id?: string;
8367
+ user_id?: string;
8368
+ };
8369
+ Relationships: [];
8370
+ };
7835
8371
  twinfield_settings: {
7836
8372
  Row: {
7837
8373
  active_environment: string;
@@ -8413,6 +8949,35 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
8413
8949
  };
8414
8950
  Relationships: [];
8415
8951
  };
8952
+ manufacture_product_possible_stock_view: {
8953
+ Row: {
8954
+ component_count: number | null;
8955
+ manufacture_product_id: string | null;
8956
+ possible_stock: number | null;
8957
+ };
8958
+ Relationships: [];
8959
+ };
8960
+ product_group_stock_view: {
8961
+ Row: {
8962
+ item_count: number | null;
8963
+ product_group_id: string | null;
8964
+ total_stock: number | null;
8965
+ };
8966
+ Relationships: [{
8967
+ foreignKeyName: "product_group_items_product_group_id_fkey";
8968
+ columns: ["product_group_id"];
8969
+ isOneToOne: false;
8970
+ referencedRelation: "product_groups";
8971
+ referencedColumns: ["id"];
8972
+ }];
8973
+ };
8974
+ trade_item_stock_view: {
8975
+ Row: {
8976
+ stock: number | null;
8977
+ trade_item_id: string | null;
8978
+ };
8979
+ Relationships: [];
8980
+ };
8416
8981
  v_external_customers_exact: {
8417
8982
  Row: {
8418
8983
  account_number: string | null;
@@ -8668,6 +9233,20 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
8668
9233
  };
8669
9234
  Returns: number;
8670
9235
  };
9236
+ assign_cart_numbers: {
9237
+ Args: {
9238
+ p_carts: import("../integrations/supabase/types").Json;
9239
+ };
9240
+ Returns: {
9241
+ cart_index: number;
9242
+ cart_number: string;
9243
+ day_seq: number;
9244
+ order_id: string;
9245
+ order_source: string;
9246
+ pick_date: string;
9247
+ status: string;
9248
+ }[];
9249
+ };
8671
9250
  assign_floriday_order_numbers: {
8672
9251
  Args: {
8673
9252
  p_ids: string[];
@@ -8687,10 +9266,37 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
8687
9266
  Args: never;
8688
9267
  Returns: number;
8689
9268
  };
9269
+ control_get_todays_carts: {
9270
+ Args: never;
9271
+ Returns: {
9272
+ cart_index: number;
9273
+ cart_number: string;
9274
+ cart_number_id: string;
9275
+ order_id: string;
9276
+ order_source: string;
9277
+ pick_date: string;
9278
+ status: string;
9279
+ }[];
9280
+ };
9281
+ count_distinct_regulatory_products: {
9282
+ Args: never;
9283
+ Returns: number;
9284
+ };
8690
9285
  current_monteur_id: {
8691
9286
  Args: never;
8692
9287
  Returns: string;
8693
9288
  };
9289
+ dashboard_alert_counts: {
9290
+ Args: never;
9291
+ Returns: import("../integrations/supabase/types").Json;
9292
+ };
9293
+ dashboard_alert_rows: {
9294
+ Args: {
9295
+ check_id: string;
9296
+ row_limit?: number;
9297
+ };
9298
+ Returns: import("../integrations/supabase/types").Json;
9299
+ };
8694
9300
  dashboard_list_public_schema: {
8695
9301
  Args: never;
8696
9302
  Returns: {
@@ -8771,6 +9377,13 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
8771
9377
  };
8772
9378
  Returns: boolean;
8773
9379
  };
9380
+ format_cart_number: {
9381
+ Args: {
9382
+ p_pick_date: string;
9383
+ p_seq: number;
9384
+ };
9385
+ Returns: string;
9386
+ };
8774
9387
  get_active_floriday_connection_public: {
8775
9388
  Args: never;
8776
9389
  Returns: {
@@ -8975,14 +9588,29 @@ export declare const getAfhandelingSettings: import("@tanstack/start-client-core
8975
9588
  };
8976
9589
  Returns: undefined;
8977
9590
  };
9591
+ pickstation_set_cart_status: {
9592
+ Args: {
9593
+ p_cart_index: number;
9594
+ p_order_id: string;
9595
+ p_order_source: string;
9596
+ p_status: string;
9597
+ };
9598
+ Returns: undefined;
9599
+ };
8978
9600
  refresh_floricode_derived_code_lists: {
8979
9601
  Args: never;
8980
9602
  Returns: {
8981
- out_environment: string;
8982
- out_list_name: string;
8983
- out_row_count: number;
9603
+ environment: string;
9604
+ list_name: string;
9605
+ row_count: number;
8984
9606
  }[];
8985
9607
  };
9608
+ refresh_floricode_derived_for_product: {
9609
+ Args: {
9610
+ p_product_code: string;
9611
+ };
9612
+ Returns: number;
9613
+ };
8986
9614
  reset_floriday_sync_cursor: {
8987
9615
  Args: {
8988
9616
  p_connection_id: string;
@@ -9303,6 +9931,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9303
9931
  max_workdays_earlier_pick: number;
9304
9932
  pick_days_before_transport: number;
9305
9933
  pick_distribution_enabled: boolean;
9934
+ pick_weekdays: number[];
9306
9935
  signup_mail_enabled: boolean;
9307
9936
  signup_mail_lead_minutes: number;
9308
9937
  signup_mail_purpose: string;
@@ -9316,6 +9945,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9316
9945
  max_workdays_earlier_pick?: number;
9317
9946
  pick_days_before_transport?: number;
9318
9947
  pick_distribution_enabled?: boolean;
9948
+ pick_weekdays?: number[];
9319
9949
  signup_mail_enabled?: boolean;
9320
9950
  signup_mail_lead_minutes?: number;
9321
9951
  signup_mail_purpose?: string;
@@ -9329,6 +9959,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9329
9959
  max_workdays_earlier_pick?: number;
9330
9960
  pick_days_before_transport?: number;
9331
9961
  pick_distribution_enabled?: boolean;
9962
+ pick_weekdays?: number[];
9332
9963
  signup_mail_enabled?: boolean;
9333
9964
  signup_mail_lead_minutes?: number;
9334
9965
  signup_mail_purpose?: string;
@@ -9740,6 +10371,48 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9740
10371
  referencedColumns: ["id"];
9741
10372
  }];
9742
10373
  };
10374
+ carrier_signup_dispatch_runs: {
10375
+ Row: {
10376
+ detail: import("../integrations/supabase/types").Json | null;
10377
+ error: string | null;
10378
+ finished_at: string | null;
10379
+ groups: number;
10380
+ id: string;
10381
+ ok: boolean;
10382
+ reason: string | null;
10383
+ sent: number;
10384
+ skipped: import("../integrations/supabase/types").Json;
10385
+ started_at: string;
10386
+ unassigned: import("../integrations/supabase/types").Json;
10387
+ };
10388
+ Insert: {
10389
+ detail?: import("../integrations/supabase/types").Json | null;
10390
+ error?: string | null;
10391
+ finished_at?: string | null;
10392
+ groups?: number;
10393
+ id?: string;
10394
+ ok?: boolean;
10395
+ reason?: string | null;
10396
+ sent?: number;
10397
+ skipped?: import("../integrations/supabase/types").Json;
10398
+ started_at?: string;
10399
+ unassigned?: import("../integrations/supabase/types").Json;
10400
+ };
10401
+ Update: {
10402
+ detail?: import("../integrations/supabase/types").Json | null;
10403
+ error?: string | null;
10404
+ finished_at?: string | null;
10405
+ groups?: number;
10406
+ id?: string;
10407
+ ok?: boolean;
10408
+ reason?: string | null;
10409
+ sent?: number;
10410
+ skipped?: import("../integrations/supabase/types").Json;
10411
+ started_at?: string;
10412
+ unassigned?: import("../integrations/supabase/types").Json;
10413
+ };
10414
+ Relationships: [];
10415
+ };
9743
10416
  carrier_signup_dispatches: {
9744
10417
  Row: {
9745
10418
  carrier_id: string;
@@ -9791,6 +10464,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9791
10464
  contact_person: string | null;
9792
10465
  created_at: string;
9793
10466
  delivery_days: number | null;
10467
+ delivery_weekdays: number[];
9794
10468
  email: string | null;
9795
10469
  id: string;
9796
10470
  is_default: boolean;
@@ -9798,6 +10472,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9798
10472
  notes: string | null;
9799
10473
  phone: string | null;
9800
10474
  pickup_moments: import("../integrations/supabase/types").Json;
10475
+ pickup_weekdays: number[];
9801
10476
  service_cities: string[];
9802
10477
  service_countries: string[];
9803
10478
  service_provinces: string[];
@@ -9813,6 +10488,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9813
10488
  contact_person?: string | null;
9814
10489
  created_at?: string;
9815
10490
  delivery_days?: number | null;
10491
+ delivery_weekdays?: number[];
9816
10492
  email?: string | null;
9817
10493
  id?: string;
9818
10494
  is_default?: boolean;
@@ -9820,6 +10496,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9820
10496
  notes?: string | null;
9821
10497
  phone?: string | null;
9822
10498
  pickup_moments?: import("../integrations/supabase/types").Json;
10499
+ pickup_weekdays?: number[];
9823
10500
  service_cities?: string[];
9824
10501
  service_countries?: string[];
9825
10502
  service_provinces?: string[];
@@ -9835,6 +10512,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9835
10512
  contact_person?: string | null;
9836
10513
  created_at?: string;
9837
10514
  delivery_days?: number | null;
10515
+ delivery_weekdays?: number[];
9838
10516
  email?: string | null;
9839
10517
  id?: string;
9840
10518
  is_default?: boolean;
@@ -9842,6 +10520,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9842
10520
  notes?: string | null;
9843
10521
  phone?: string | null;
9844
10522
  pickup_moments?: import("../integrations/supabase/types").Json;
10523
+ pickup_weekdays?: number[];
9845
10524
  service_cities?: string[];
9846
10525
  service_countries?: string[];
9847
10526
  service_provinces?: string[];
@@ -9854,6 +10533,177 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
9854
10533
  };
9855
10534
  Relationships: [];
9856
10535
  };
10536
+ cart_control_draft: {
10537
+ Row: {
10538
+ cart_states: import("../integrations/supabase/types").Json;
10539
+ checked_keys: import("../integrations/supabase/types").Json;
10540
+ draft_date: string;
10541
+ form_state: import("../integrations/supabase/types").Json;
10542
+ notes: string;
10543
+ updated_at: string;
10544
+ user_id: string;
10545
+ };
10546
+ Insert: {
10547
+ cart_states?: import("../integrations/supabase/types").Json;
10548
+ checked_keys?: import("../integrations/supabase/types").Json;
10549
+ draft_date: string;
10550
+ form_state?: import("../integrations/supabase/types").Json;
10551
+ notes?: string;
10552
+ updated_at?: string;
10553
+ user_id: string;
10554
+ };
10555
+ Update: {
10556
+ cart_states?: import("../integrations/supabase/types").Json;
10557
+ checked_keys?: import("../integrations/supabase/types").Json;
10558
+ draft_date?: string;
10559
+ form_state?: import("../integrations/supabase/types").Json;
10560
+ notes?: string;
10561
+ updated_at?: string;
10562
+ user_id?: string;
10563
+ };
10564
+ Relationships: [];
10565
+ };
10566
+ cart_control_items: {
10567
+ Row: {
10568
+ action: string;
10569
+ block_reason: string | null;
10570
+ carrier_name: string | null;
10571
+ cart_index: number;
10572
+ cart_number_id: string | null;
10573
+ cart_number_label: string | null;
10574
+ created_at: string;
10575
+ customer_name: string | null;
10576
+ delivery_date: string | null;
10577
+ id: string;
10578
+ new_pick_date: string | null;
10579
+ order_id: string;
10580
+ order_number: string | null;
10581
+ order_source: string;
10582
+ pickup_date: string | null;
10583
+ session_id: string;
10584
+ };
10585
+ Insert: {
10586
+ action: string;
10587
+ block_reason?: string | null;
10588
+ carrier_name?: string | null;
10589
+ cart_index: number;
10590
+ cart_number_id?: string | null;
10591
+ cart_number_label?: string | null;
10592
+ created_at?: string;
10593
+ customer_name?: string | null;
10594
+ delivery_date?: string | null;
10595
+ id?: string;
10596
+ new_pick_date?: string | null;
10597
+ order_id: string;
10598
+ order_number?: string | null;
10599
+ order_source: string;
10600
+ pickup_date?: string | null;
10601
+ session_id: string;
10602
+ };
10603
+ Update: {
10604
+ action?: string;
10605
+ block_reason?: string | null;
10606
+ carrier_name?: string | null;
10607
+ cart_index?: number;
10608
+ cart_number_id?: string | null;
10609
+ cart_number_label?: string | null;
10610
+ created_at?: string;
10611
+ customer_name?: string | null;
10612
+ delivery_date?: string | null;
10613
+ id?: string;
10614
+ new_pick_date?: string | null;
10615
+ order_id?: string;
10616
+ order_number?: string | null;
10617
+ order_source?: string;
10618
+ pickup_date?: string | null;
10619
+ session_id?: string;
10620
+ };
10621
+ Relationships: [{
10622
+ foreignKeyName: "cart_control_items_session_id_fkey";
10623
+ columns: ["session_id"];
10624
+ isOneToOne: false;
10625
+ referencedRelation: "cart_control_sessions";
10626
+ referencedColumns: ["id"];
10627
+ }];
10628
+ };
10629
+ cart_control_sessions: {
10630
+ Row: {
10631
+ blocked_count: number;
10632
+ checked_count: number;
10633
+ control_date: string;
10634
+ created_at: string;
10635
+ id: string;
10636
+ notes: string | null;
10637
+ performed_at: string;
10638
+ rescheduled_count: number;
10639
+ total_carts: number;
10640
+ updated_at: string;
10641
+ user_id: string;
10642
+ };
10643
+ Insert: {
10644
+ blocked_count?: number;
10645
+ checked_count?: number;
10646
+ control_date?: string;
10647
+ created_at?: string;
10648
+ id?: string;
10649
+ notes?: string | null;
10650
+ performed_at?: string;
10651
+ rescheduled_count?: number;
10652
+ total_carts?: number;
10653
+ updated_at?: string;
10654
+ user_id: string;
10655
+ };
10656
+ Update: {
10657
+ blocked_count?: number;
10658
+ checked_count?: number;
10659
+ control_date?: string;
10660
+ created_at?: string;
10661
+ id?: string;
10662
+ notes?: string | null;
10663
+ performed_at?: string;
10664
+ rescheduled_count?: number;
10665
+ total_carts?: number;
10666
+ updated_at?: string;
10667
+ user_id?: string;
10668
+ };
10669
+ Relationships: [];
10670
+ };
10671
+ cart_numbers: {
10672
+ Row: {
10673
+ assigned_at: string;
10674
+ cart_index: number;
10675
+ cart_number: string;
10676
+ day_seq: number;
10677
+ id: string;
10678
+ order_id: string;
10679
+ order_source: string;
10680
+ pick_date: string;
10681
+ status: string;
10682
+ };
10683
+ Insert: {
10684
+ assigned_at?: string;
10685
+ cart_index: number;
10686
+ cart_number: string;
10687
+ day_seq: number;
10688
+ id?: string;
10689
+ order_id: string;
10690
+ order_source: string;
10691
+ pick_date: string;
10692
+ status?: string;
10693
+ };
10694
+ Update: {
10695
+ assigned_at?: string;
10696
+ cart_index?: number;
10697
+ cart_number?: string;
10698
+ day_seq?: number;
10699
+ id?: string;
10700
+ order_id?: string;
10701
+ order_source?: string;
10702
+ pick_date?: string;
10703
+ status?: string;
10704
+ };
10705
+ Relationships: [];
10706
+ };
9857
10707
  cart_pick_overrides: {
9858
10708
  Row: {
9859
10709
  cart_index: number;
@@ -10502,29 +11352,77 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
10502
11352
  permissions?: import("../integrations/supabase/types").Json;
10503
11353
  sort_order?: number;
10504
11354
  title: string;
10505
- type: string;
11355
+ type: string;
11356
+ updated_at?: string;
11357
+ };
11358
+ Update: {
11359
+ config?: import("../integrations/supabase/types").Json;
11360
+ created_at?: string;
11361
+ filters?: import("../integrations/supabase/types").Json;
11362
+ id?: string;
11363
+ layout?: import("../integrations/supabase/types").Json;
11364
+ page_id?: string;
11365
+ permissions?: import("../integrations/supabase/types").Json;
11366
+ sort_order?: number;
11367
+ title?: string;
11368
+ type?: string;
11369
+ updated_at?: string;
11370
+ };
11371
+ Relationships: [{
11372
+ foreignKeyName: "dashboard_blocks_page_id_fkey";
11373
+ columns: ["page_id"];
11374
+ isOneToOne: false;
11375
+ referencedRelation: "dashboard_pages";
11376
+ referencedColumns: ["id"];
11377
+ }];
11378
+ };
11379
+ dashboard_critical_alerts: {
11380
+ Row: {
11381
+ alert_key: string;
11382
+ alert_type: string;
11383
+ created_at: string;
11384
+ description: string | null;
11385
+ id: string;
11386
+ metadata: import("../integrations/supabase/types").Json | null;
11387
+ priority: string;
11388
+ raised_at: string;
11389
+ related_cart_ids: string[] | null;
11390
+ resolved_at: string | null;
11391
+ title: string;
11392
+ updated_at: string;
11393
+ user_id: string;
11394
+ };
11395
+ Insert: {
11396
+ alert_key: string;
11397
+ alert_type: string;
11398
+ created_at?: string;
11399
+ description?: string | null;
11400
+ id?: string;
11401
+ metadata?: import("../integrations/supabase/types").Json | null;
11402
+ priority?: string;
11403
+ raised_at?: string;
11404
+ related_cart_ids?: string[] | null;
11405
+ resolved_at?: string | null;
11406
+ title: string;
10506
11407
  updated_at?: string;
11408
+ user_id: string;
10507
11409
  };
10508
11410
  Update: {
10509
- config?: import("../integrations/supabase/types").Json;
11411
+ alert_key?: string;
11412
+ alert_type?: string;
10510
11413
  created_at?: string;
10511
- filters?: import("../integrations/supabase/types").Json;
11414
+ description?: string | null;
10512
11415
  id?: string;
10513
- layout?: import("../integrations/supabase/types").Json;
10514
- page_id?: string;
10515
- permissions?: import("../integrations/supabase/types").Json;
10516
- sort_order?: number;
11416
+ metadata?: import("../integrations/supabase/types").Json | null;
11417
+ priority?: string;
11418
+ raised_at?: string;
11419
+ related_cart_ids?: string[] | null;
11420
+ resolved_at?: string | null;
10517
11421
  title?: string;
10518
- type?: string;
10519
11422
  updated_at?: string;
11423
+ user_id?: string;
10520
11424
  };
10521
- Relationships: [{
10522
- foreignKeyName: "dashboard_blocks_page_id_fkey";
10523
- columns: ["page_id"];
10524
- isOneToOne: false;
10525
- referencedRelation: "dashboard_pages";
10526
- referencedColumns: ["id"];
10527
- }];
11425
+ Relationships: [];
10528
11426
  };
10529
11427
  dashboard_daily_reports: {
10530
11428
  Row: {
@@ -12028,6 +12926,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
12028
12926
  };
12029
12927
  floricode_sync_state: {
12030
12928
  Row: {
12929
+ cursor_skip: number;
12031
12930
  error_message: string | null;
12032
12931
  last_change_date_time: string | null;
12033
12932
  last_sequence_number: number;
@@ -12037,6 +12936,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
12037
12936
  updated_at: string;
12038
12937
  };
12039
12938
  Insert: {
12939
+ cursor_skip?: number;
12040
12940
  error_message?: string | null;
12041
12941
  last_change_date_time?: string | null;
12042
12942
  last_sequence_number?: number;
@@ -12046,6 +12946,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
12046
12946
  updated_at?: string;
12047
12947
  };
12048
12948
  Update: {
12949
+ cursor_skip?: number;
12049
12950
  error_message?: string | null;
12050
12951
  last_change_date_time?: string | null;
12051
12952
  last_sequence_number?: number;
@@ -14393,6 +15294,93 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
14393
15294
  };
14394
15295
  Relationships: [];
14395
15296
  };
15297
+ manufacture_product_components: {
15298
+ Row: {
15299
+ component_type: string;
15300
+ created_at: string;
15301
+ id: string;
15302
+ manufacture_product_id: string;
15303
+ product_group_id: string | null;
15304
+ quantity: number;
15305
+ trade_item_id: string | null;
15306
+ unit: string;
15307
+ };
15308
+ Insert: {
15309
+ component_type: string;
15310
+ created_at?: string;
15311
+ id?: string;
15312
+ manufacture_product_id: string;
15313
+ product_group_id?: string | null;
15314
+ quantity?: number;
15315
+ trade_item_id?: string | null;
15316
+ unit?: string;
15317
+ };
15318
+ Update: {
15319
+ component_type?: string;
15320
+ created_at?: string;
15321
+ id?: string;
15322
+ manufacture_product_id?: string;
15323
+ product_group_id?: string | null;
15324
+ quantity?: number;
15325
+ trade_item_id?: string | null;
15326
+ unit?: string;
15327
+ };
15328
+ Relationships: [{
15329
+ foreignKeyName: "manufacture_product_components_manufacture_product_id_fkey";
15330
+ columns: ["manufacture_product_id"];
15331
+ isOneToOne: false;
15332
+ referencedRelation: "manufacture_product_possible_stock_view";
15333
+ referencedColumns: ["manufacture_product_id"];
15334
+ }, {
15335
+ foreignKeyName: "manufacture_product_components_manufacture_product_id_fkey";
15336
+ columns: ["manufacture_product_id"];
15337
+ isOneToOne: false;
15338
+ referencedRelation: "manufacture_products";
15339
+ referencedColumns: ["id"];
15340
+ }, {
15341
+ foreignKeyName: "manufacture_product_components_product_group_id_fkey";
15342
+ columns: ["product_group_id"];
15343
+ isOneToOne: false;
15344
+ referencedRelation: "product_groups";
15345
+ referencedColumns: ["id"];
15346
+ }];
15347
+ };
15348
+ manufacture_products: {
15349
+ Row: {
15350
+ created_at: string;
15351
+ description: string | null;
15352
+ id: string;
15353
+ is_active: boolean;
15354
+ name: string;
15355
+ produced_stock: number;
15356
+ product_code: string;
15357
+ tenant_id: string;
15358
+ updated_at: string;
15359
+ };
15360
+ Insert: {
15361
+ created_at?: string;
15362
+ description?: string | null;
15363
+ id?: string;
15364
+ is_active?: boolean;
15365
+ name: string;
15366
+ produced_stock?: number;
15367
+ product_code: string;
15368
+ tenant_id: string;
15369
+ updated_at?: string;
15370
+ };
15371
+ Update: {
15372
+ created_at?: string;
15373
+ description?: string | null;
15374
+ id?: string;
15375
+ is_active?: boolean;
15376
+ name?: string;
15377
+ produced_stock?: number;
15378
+ product_code?: string;
15379
+ tenant_id?: string;
15380
+ updated_at?: string;
15381
+ };
15382
+ Relationships: [];
15383
+ };
14396
15384
  monteurs: {
14397
15385
  Row: {
14398
15386
  avatar_url: string | null;
@@ -15353,6 +16341,66 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
15353
16341
  };
15354
16342
  Relationships: [];
15355
16343
  };
16344
+ product_group_items: {
16345
+ Row: {
16346
+ created_at: string;
16347
+ id: string;
16348
+ product_group_id: string;
16349
+ quantity: number;
16350
+ trade_item_id: string;
16351
+ };
16352
+ Insert: {
16353
+ created_at?: string;
16354
+ id?: string;
16355
+ product_group_id: string;
16356
+ quantity?: number;
16357
+ trade_item_id: string;
16358
+ };
16359
+ Update: {
16360
+ created_at?: string;
16361
+ id?: string;
16362
+ product_group_id?: string;
16363
+ quantity?: number;
16364
+ trade_item_id?: string;
16365
+ };
16366
+ Relationships: [{
16367
+ foreignKeyName: "product_group_items_product_group_id_fkey";
16368
+ columns: ["product_group_id"];
16369
+ isOneToOne: false;
16370
+ referencedRelation: "product_groups";
16371
+ referencedColumns: ["id"];
16372
+ }];
16373
+ };
16374
+ product_groups: {
16375
+ Row: {
16376
+ created_at: string;
16377
+ description: string | null;
16378
+ id: string;
16379
+ is_active: boolean;
16380
+ name: string;
16381
+ tenant_id: string;
16382
+ updated_at: string;
16383
+ };
16384
+ Insert: {
16385
+ created_at?: string;
16386
+ description?: string | null;
16387
+ id?: string;
16388
+ is_active?: boolean;
16389
+ name: string;
16390
+ tenant_id: string;
16391
+ updated_at?: string;
16392
+ };
16393
+ Update: {
16394
+ created_at?: string;
16395
+ description?: string | null;
16396
+ id?: string;
16397
+ is_active?: boolean;
16398
+ name?: string;
16399
+ tenant_id?: string;
16400
+ updated_at?: string;
16401
+ };
16402
+ Relationships: [];
16403
+ };
15356
16404
  products: {
15357
16405
  Row: {
15358
16406
  barcode: string | null;
@@ -16492,7 +17540,13 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
16492
17540
  connection_id: string | null;
16493
17541
  created_at: string;
16494
17542
  data: import("../integrations/supabase/types").Json;
17543
+ floriday_id: string | null;
17544
+ floriday_link_error: string | null;
17545
+ floriday_link_status: string;
16495
17546
  id: string;
17547
+ last_floriday_sync_at: string | null;
17548
+ missing_required_fields: string[];
17549
+ source: string;
16496
17550
  updated_at: string;
16497
17551
  user_id: string;
16498
17552
  };
@@ -16500,7 +17554,13 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
16500
17554
  connection_id?: string | null;
16501
17555
  created_at?: string;
16502
17556
  data?: import("../integrations/supabase/types").Json;
17557
+ floriday_id?: string | null;
17558
+ floriday_link_error?: string | null;
17559
+ floriday_link_status?: string;
16503
17560
  id?: string;
17561
+ last_floriday_sync_at?: string | null;
17562
+ missing_required_fields?: string[];
17563
+ source?: string;
16504
17564
  updated_at?: string;
16505
17565
  user_id: string;
16506
17566
  };
@@ -16508,7 +17568,55 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
16508
17568
  connection_id?: string | null;
16509
17569
  created_at?: string;
16510
17570
  data?: import("../integrations/supabase/types").Json;
17571
+ floriday_id?: string | null;
17572
+ floriday_link_error?: string | null;
17573
+ floriday_link_status?: string;
17574
+ id?: string;
17575
+ last_floriday_sync_at?: string | null;
17576
+ missing_required_fields?: string[];
17577
+ source?: string;
17578
+ updated_at?: string;
17579
+ user_id?: string;
17580
+ };
17581
+ Relationships: [];
17582
+ };
17583
+ trade_item_stock: {
17584
+ Row: {
17585
+ connection_id: string;
17586
+ created_at: string;
17587
+ id: string;
17588
+ incoming_stock: number;
17589
+ minimum_stock: number;
17590
+ notes: string | null;
17591
+ physical_stock: number;
17592
+ reserved_stock: number;
17593
+ trade_item_key: string;
17594
+ updated_at: string;
17595
+ user_id: string;
17596
+ };
17597
+ Insert: {
17598
+ connection_id: string;
17599
+ created_at?: string;
17600
+ id?: string;
17601
+ incoming_stock?: number;
17602
+ minimum_stock?: number;
17603
+ notes?: string | null;
17604
+ physical_stock?: number;
17605
+ reserved_stock?: number;
17606
+ trade_item_key: string;
17607
+ updated_at?: string;
17608
+ user_id: string;
17609
+ };
17610
+ Update: {
17611
+ connection_id?: string;
17612
+ created_at?: string;
16511
17613
  id?: string;
17614
+ incoming_stock?: number;
17615
+ minimum_stock?: number;
17616
+ notes?: string | null;
17617
+ physical_stock?: number;
17618
+ reserved_stock?: number;
17619
+ trade_item_key?: string;
16512
17620
  updated_at?: string;
16513
17621
  user_id?: string;
16514
17622
  };
@@ -16858,6 +17966,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
16858
17966
  };
16859
17967
  twinfield_invoice_sync_logs: {
16860
17968
  Row: {
17969
+ action_type: string | null;
16861
17970
  created_at: string;
16862
17971
  details: import("../integrations/supabase/types").Json | null;
16863
17972
  duration_ms: number | null;
@@ -16870,6 +17979,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
16870
17979
  user_id: string;
16871
17980
  };
16872
17981
  Insert: {
17982
+ action_type?: string | null;
16873
17983
  created_at?: string;
16874
17984
  details?: import("../integrations/supabase/types").Json | null;
16875
17985
  duration_ms?: number | null;
@@ -16882,6 +17992,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
16882
17992
  user_id: string;
16883
17993
  };
16884
17994
  Update: {
17995
+ action_type?: string | null;
16885
17996
  created_at?: string;
16886
17997
  details?: import("../integrations/supabase/types").Json | null;
16887
17998
  duration_ms?: number | null;
@@ -17117,6 +18228,57 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
17117
18228
  referencedColumns: ["id"];
17118
18229
  }];
17119
18230
  };
18231
+ twinfield_request_metrics: {
18232
+ Row: {
18233
+ bucket_hour: string;
18234
+ connection_id: string;
18235
+ error_count: number;
18236
+ rate_limited_count: number;
18237
+ request_count: number;
18238
+ updated_at: string;
18239
+ };
18240
+ Insert: {
18241
+ bucket_hour: string;
18242
+ connection_id: string;
18243
+ error_count?: number;
18244
+ rate_limited_count?: number;
18245
+ request_count?: number;
18246
+ updated_at?: string;
18247
+ };
18248
+ Update: {
18249
+ bucket_hour?: string;
18250
+ connection_id?: string;
18251
+ error_count?: number;
18252
+ rate_limited_count?: number;
18253
+ request_count?: number;
18254
+ updated_at?: string;
18255
+ };
18256
+ Relationships: [];
18257
+ };
18258
+ twinfield_session_cache: {
18259
+ Row: {
18260
+ cluster: string;
18261
+ created_at: string;
18262
+ expires_at: string;
18263
+ session_id: string;
18264
+ user_id: string;
18265
+ };
18266
+ Insert: {
18267
+ cluster: string;
18268
+ created_at?: string;
18269
+ expires_at: string;
18270
+ session_id: string;
18271
+ user_id: string;
18272
+ };
18273
+ Update: {
18274
+ cluster?: string;
18275
+ created_at?: string;
18276
+ expires_at?: string;
18277
+ session_id?: string;
18278
+ user_id?: string;
18279
+ };
18280
+ Relationships: [];
18281
+ };
17120
18282
  twinfield_settings: {
17121
18283
  Row: {
17122
18284
  active_environment: string;
@@ -17698,6 +18860,35 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
17698
18860
  };
17699
18861
  Relationships: [];
17700
18862
  };
18863
+ manufacture_product_possible_stock_view: {
18864
+ Row: {
18865
+ component_count: number | null;
18866
+ manufacture_product_id: string | null;
18867
+ possible_stock: number | null;
18868
+ };
18869
+ Relationships: [];
18870
+ };
18871
+ product_group_stock_view: {
18872
+ Row: {
18873
+ item_count: number | null;
18874
+ product_group_id: string | null;
18875
+ total_stock: number | null;
18876
+ };
18877
+ Relationships: [{
18878
+ foreignKeyName: "product_group_items_product_group_id_fkey";
18879
+ columns: ["product_group_id"];
18880
+ isOneToOne: false;
18881
+ referencedRelation: "product_groups";
18882
+ referencedColumns: ["id"];
18883
+ }];
18884
+ };
18885
+ trade_item_stock_view: {
18886
+ Row: {
18887
+ stock: number | null;
18888
+ trade_item_id: string | null;
18889
+ };
18890
+ Relationships: [];
18891
+ };
17701
18892
  v_external_customers_exact: {
17702
18893
  Row: {
17703
18894
  account_number: string | null;
@@ -17953,6 +19144,20 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
17953
19144
  };
17954
19145
  Returns: number;
17955
19146
  };
19147
+ assign_cart_numbers: {
19148
+ Args: {
19149
+ p_carts: import("../integrations/supabase/types").Json;
19150
+ };
19151
+ Returns: {
19152
+ cart_index: number;
19153
+ cart_number: string;
19154
+ day_seq: number;
19155
+ order_id: string;
19156
+ order_source: string;
19157
+ pick_date: string;
19158
+ status: string;
19159
+ }[];
19160
+ };
17956
19161
  assign_floriday_order_numbers: {
17957
19162
  Args: {
17958
19163
  p_ids: string[];
@@ -17972,10 +19177,37 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
17972
19177
  Args: never;
17973
19178
  Returns: number;
17974
19179
  };
19180
+ control_get_todays_carts: {
19181
+ Args: never;
19182
+ Returns: {
19183
+ cart_index: number;
19184
+ cart_number: string;
19185
+ cart_number_id: string;
19186
+ order_id: string;
19187
+ order_source: string;
19188
+ pick_date: string;
19189
+ status: string;
19190
+ }[];
19191
+ };
19192
+ count_distinct_regulatory_products: {
19193
+ Args: never;
19194
+ Returns: number;
19195
+ };
17975
19196
  current_monteur_id: {
17976
19197
  Args: never;
17977
19198
  Returns: string;
17978
19199
  };
19200
+ dashboard_alert_counts: {
19201
+ Args: never;
19202
+ Returns: import("../integrations/supabase/types").Json;
19203
+ };
19204
+ dashboard_alert_rows: {
19205
+ Args: {
19206
+ check_id: string;
19207
+ row_limit?: number;
19208
+ };
19209
+ Returns: import("../integrations/supabase/types").Json;
19210
+ };
17979
19211
  dashboard_list_public_schema: {
17980
19212
  Args: never;
17981
19213
  Returns: {
@@ -18056,6 +19288,13 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
18056
19288
  };
18057
19289
  Returns: boolean;
18058
19290
  };
19291
+ format_cart_number: {
19292
+ Args: {
19293
+ p_pick_date: string;
19294
+ p_seq: number;
19295
+ };
19296
+ Returns: string;
19297
+ };
18059
19298
  get_active_floriday_connection_public: {
18060
19299
  Args: never;
18061
19300
  Returns: {
@@ -18260,14 +19499,29 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
18260
19499
  };
18261
19500
  Returns: undefined;
18262
19501
  };
19502
+ pickstation_set_cart_status: {
19503
+ Args: {
19504
+ p_cart_index: number;
19505
+ p_order_id: string;
19506
+ p_order_source: string;
19507
+ p_status: string;
19508
+ };
19509
+ Returns: undefined;
19510
+ };
18263
19511
  refresh_floricode_derived_code_lists: {
18264
19512
  Args: never;
18265
19513
  Returns: {
18266
- out_environment: string;
18267
- out_list_name: string;
18268
- out_row_count: number;
19514
+ environment: string;
19515
+ list_name: string;
19516
+ row_count: number;
18269
19517
  }[];
18270
19518
  };
19519
+ refresh_floricode_derived_for_product: {
19520
+ Args: {
19521
+ p_product_code: string;
19522
+ };
19523
+ Returns: number;
19524
+ };
18271
19525
  reset_floriday_sync_cursor: {
18272
19526
  Args: {
18273
19527
  p_connection_id: string;
@@ -18585,6 +19839,7 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
18585
19839
  signupMailEnabled?: boolean;
18586
19840
  signupMailLeadMinutes?: number;
18587
19841
  signupMailPurpose?: string;
19842
+ pickWeekdays?: number[];
18588
19843
  }) => {
18589
19844
  pickDaysBeforeTransport: number | undefined;
18590
19845
  transportRegisterDaysBefore: number | undefined;
@@ -18593,5 +19848,6 @@ export declare const updateAfhandelingSettings: import("@tanstack/start-client-c
18593
19848
  signupMailEnabled: boolean | undefined;
18594
19849
  signupMailLeadMinutes: number | undefined;
18595
19850
  signupMailPurpose: string | undefined;
19851
+ pickWeekdays: number[] | undefined;
18596
19852
  }, Promise<AfhandelingSettings>>;
18597
19853
  //# sourceMappingURL=afhandelingSettings.functions.d.ts.map