@flowselections/scan-module 1.0.6 → 1.0.8

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.
@@ -1451,9 +1451,10 @@ export type Database = {
1451
1451
  Row: {
1452
1452
  assigned_at: string;
1453
1453
  cart_index: number;
1454
- cart_number: string | null;
1454
+ cart_number: string;
1455
1455
  day_seq: number | null;
1456
1456
  delivered_at: string | null;
1457
+ engine_cart_label: string | null;
1457
1458
  id: string;
1458
1459
  order_id: string;
1459
1460
  order_source: string;
@@ -1463,9 +1464,10 @@ export type Database = {
1463
1464
  Insert: {
1464
1465
  assigned_at?: string;
1465
1466
  cart_index: number;
1466
- cart_number?: string | null;
1467
+ cart_number: string;
1467
1468
  day_seq?: number | null;
1468
1469
  delivered_at?: string | null;
1470
+ engine_cart_label?: string | null;
1469
1471
  id?: string;
1470
1472
  order_id: string;
1471
1473
  order_source: string;
@@ -1475,9 +1477,10 @@ export type Database = {
1475
1477
  Update: {
1476
1478
  assigned_at?: string;
1477
1479
  cart_index?: number;
1478
- cart_number?: string | null;
1480
+ cart_number?: string;
1479
1481
  day_seq?: number | null;
1480
1482
  delivered_at?: string | null;
1483
+ engine_cart_label?: string | null;
1481
1484
  id?: string;
1482
1485
  order_id?: string;
1483
1486
  order_source?: string;
@@ -1857,6 +1860,42 @@ export type Database = {
1857
1860
  };
1858
1861
  Relationships: [];
1859
1862
  };
1863
+ customer_assortment_items: {
1864
+ Row: {
1865
+ created_at: string;
1866
+ customer_key: string;
1867
+ id: string;
1868
+ in_assortment: boolean;
1869
+ manual_override: boolean;
1870
+ source: string;
1871
+ synced_at: string | null;
1872
+ trade_item_key: string;
1873
+ updated_at: string;
1874
+ };
1875
+ Insert: {
1876
+ created_at?: string;
1877
+ customer_key: string;
1878
+ id?: string;
1879
+ in_assortment?: boolean;
1880
+ manual_override?: boolean;
1881
+ source?: string;
1882
+ synced_at?: string | null;
1883
+ trade_item_key: string;
1884
+ updated_at?: string;
1885
+ };
1886
+ Update: {
1887
+ created_at?: string;
1888
+ customer_key?: string;
1889
+ id?: string;
1890
+ in_assortment?: boolean;
1891
+ manual_override?: boolean;
1892
+ source?: string;
1893
+ synced_at?: string | null;
1894
+ trade_item_key?: string;
1895
+ updated_at?: string;
1896
+ };
1897
+ Relationships: [];
1898
+ };
1860
1899
  customer_audit_log: {
1861
1900
  Row: {
1862
1901
  action: string;
@@ -2202,6 +2241,8 @@ export type Database = {
2202
2241
  created_at: string;
2203
2242
  currency: string;
2204
2243
  distribute_over: string | null;
2244
+ external_id: string | null;
2245
+ external_synced_at: string | null;
2205
2246
  group_type: string;
2206
2247
  handling_fee: number | null;
2207
2248
  id: string;
@@ -2214,6 +2255,7 @@ export type Database = {
2214
2255
  rounding: string;
2215
2256
  rounding_step: number;
2216
2257
  sort_order: number;
2258
+ source: string;
2217
2259
  unit: string;
2218
2260
  updated_at: string;
2219
2261
  };
@@ -2224,6 +2266,8 @@ export type Database = {
2224
2266
  created_at?: string;
2225
2267
  currency?: string;
2226
2268
  distribute_over?: string | null;
2269
+ external_id?: string | null;
2270
+ external_synced_at?: string | null;
2227
2271
  group_type?: string;
2228
2272
  handling_fee?: number | null;
2229
2273
  id?: string;
@@ -2236,6 +2280,7 @@ export type Database = {
2236
2280
  rounding?: string;
2237
2281
  rounding_step?: number;
2238
2282
  sort_order?: number;
2283
+ source?: string;
2239
2284
  unit?: string;
2240
2285
  updated_at?: string;
2241
2286
  };
@@ -2246,6 +2291,8 @@ export type Database = {
2246
2291
  created_at?: string;
2247
2292
  currency?: string;
2248
2293
  distribute_over?: string | null;
2294
+ external_id?: string | null;
2295
+ external_synced_at?: string | null;
2249
2296
  group_type?: string;
2250
2297
  handling_fee?: number | null;
2251
2298
  id?: string;
@@ -2258,11 +2305,69 @@ export type Database = {
2258
2305
  rounding?: string;
2259
2306
  rounding_step?: number;
2260
2307
  sort_order?: number;
2308
+ source?: string;
2261
2309
  unit?: string;
2262
2310
  updated_at?: string;
2263
2311
  };
2264
2312
  Relationships: [];
2265
2313
  };
2314
+ customer_product_stickers: {
2315
+ Row: {
2316
+ content_hash: string | null;
2317
+ created_at: string;
2318
+ customer_key: string;
2319
+ file_name: string;
2320
+ file_path: string;
2321
+ file_size: number | null;
2322
+ floriday_sticker_id: string | null;
2323
+ floriday_synced_at: string | null;
2324
+ height_mm: number | null;
2325
+ id: string;
2326
+ mime_type: string | null;
2327
+ source: string;
2328
+ trade_item_key: string;
2329
+ updated_at: string;
2330
+ uploaded_by: string | null;
2331
+ width_mm: number | null;
2332
+ };
2333
+ Insert: {
2334
+ content_hash?: string | null;
2335
+ created_at?: string;
2336
+ customer_key: string;
2337
+ file_name: string;
2338
+ file_path: string;
2339
+ file_size?: number | null;
2340
+ floriday_sticker_id?: string | null;
2341
+ floriday_synced_at?: string | null;
2342
+ height_mm?: number | null;
2343
+ id?: string;
2344
+ mime_type?: string | null;
2345
+ source?: string;
2346
+ trade_item_key: string;
2347
+ updated_at?: string;
2348
+ uploaded_by?: string | null;
2349
+ width_mm?: number | null;
2350
+ };
2351
+ Update: {
2352
+ content_hash?: string | null;
2353
+ created_at?: string;
2354
+ customer_key?: string;
2355
+ file_name?: string;
2356
+ file_path?: string;
2357
+ file_size?: number | null;
2358
+ floriday_sticker_id?: string | null;
2359
+ floriday_synced_at?: string | null;
2360
+ height_mm?: number | null;
2361
+ id?: string;
2362
+ mime_type?: string | null;
2363
+ source?: string;
2364
+ trade_item_key?: string;
2365
+ updated_at?: string;
2366
+ uploaded_by?: string | null;
2367
+ width_mm?: number | null;
2368
+ };
2369
+ Relationships: [];
2370
+ };
2266
2371
  customer_selected_assortment: {
2267
2372
  Row: {
2268
2373
  article_number: string | null;
@@ -2313,6 +2418,30 @@ export type Database = {
2313
2418
  }
2314
2419
  ];
2315
2420
  };
2421
+ customer_sticker_settings: {
2422
+ Row: {
2423
+ created_at: string;
2424
+ customer_key: string;
2425
+ height_mm: number;
2426
+ updated_at: string;
2427
+ width_mm: number;
2428
+ };
2429
+ Insert: {
2430
+ created_at?: string;
2431
+ customer_key: string;
2432
+ height_mm?: number;
2433
+ updated_at?: string;
2434
+ width_mm?: number;
2435
+ };
2436
+ Update: {
2437
+ created_at?: string;
2438
+ customer_key?: string;
2439
+ height_mm?: number;
2440
+ updated_at?: string;
2441
+ width_mm?: number;
2442
+ };
2443
+ Relationships: [];
2444
+ };
2316
2445
  customer_trade_settings: {
2317
2446
  Row: {
2318
2447
  category: string;
@@ -3674,6 +3803,7 @@ export type Database = {
3674
3803
  };
3675
3804
  email_auth_outbox: {
3676
3805
  Row: {
3806
+ attachments: Json;
3677
3807
  attempts: number;
3678
3808
  bcc_addresses: string[];
3679
3809
  cc_addresses: string[];
@@ -3696,6 +3826,7 @@ export type Database = {
3696
3826
  updated_at: string;
3697
3827
  };
3698
3828
  Insert: {
3829
+ attachments?: Json;
3699
3830
  attempts?: number;
3700
3831
  bcc_addresses?: string[];
3701
3832
  cc_addresses?: string[];
@@ -3718,6 +3849,7 @@ export type Database = {
3718
3849
  updated_at?: string;
3719
3850
  };
3720
3851
  Update: {
3852
+ attachments?: Json;
3721
3853
  attempts?: number;
3722
3854
  bcc_addresses?: string[];
3723
3855
  cc_addresses?: string[];
@@ -5722,6 +5854,105 @@ export type Database = {
5722
5854
  }
5723
5855
  ];
5724
5856
  };
5857
+ floriday_api_log: {
5858
+ Row: {
5859
+ action: string | null;
5860
+ caller: string | null;
5861
+ connection_id: string | null;
5862
+ created_at: string;
5863
+ cursor_from: number | null;
5864
+ direction: string;
5865
+ duration_ms: number | null;
5866
+ environment: string | null;
5867
+ error: string | null;
5868
+ floriday_id: string | null;
5869
+ floriday_reference: string | null;
5870
+ http_status: number;
5871
+ id: string;
5872
+ item_count: number | null;
5873
+ kind: string | null;
5874
+ local_id: string | null;
5875
+ local_reference: string | null;
5876
+ method: string;
5877
+ module: string | null;
5878
+ ok: boolean;
5879
+ path: string;
5880
+ request: Json | null;
5881
+ resource_type: string | null;
5882
+ response: Json | null;
5883
+ write_log_id: string | null;
5884
+ };
5885
+ Insert: {
5886
+ action?: string | null;
5887
+ caller?: string | null;
5888
+ connection_id?: string | null;
5889
+ created_at?: string;
5890
+ cursor_from?: number | null;
5891
+ direction: string;
5892
+ duration_ms?: number | null;
5893
+ environment?: string | null;
5894
+ error?: string | null;
5895
+ floriday_id?: string | null;
5896
+ floriday_reference?: string | null;
5897
+ http_status?: number;
5898
+ id?: string;
5899
+ item_count?: number | null;
5900
+ kind?: string | null;
5901
+ local_id?: string | null;
5902
+ local_reference?: string | null;
5903
+ method: string;
5904
+ module?: string | null;
5905
+ ok?: boolean;
5906
+ path: string;
5907
+ request?: Json | null;
5908
+ resource_type?: string | null;
5909
+ response?: Json | null;
5910
+ write_log_id?: string | null;
5911
+ };
5912
+ Update: {
5913
+ action?: string | null;
5914
+ caller?: string | null;
5915
+ connection_id?: string | null;
5916
+ created_at?: string;
5917
+ cursor_from?: number | null;
5918
+ direction?: string;
5919
+ duration_ms?: number | null;
5920
+ environment?: string | null;
5921
+ error?: string | null;
5922
+ floriday_id?: string | null;
5923
+ floriday_reference?: string | null;
5924
+ http_status?: number;
5925
+ id?: string;
5926
+ item_count?: number | null;
5927
+ kind?: string | null;
5928
+ local_id?: string | null;
5929
+ local_reference?: string | null;
5930
+ method?: string;
5931
+ module?: string | null;
5932
+ ok?: boolean;
5933
+ path?: string;
5934
+ request?: Json | null;
5935
+ resource_type?: string | null;
5936
+ response?: Json | null;
5937
+ write_log_id?: string | null;
5938
+ };
5939
+ Relationships: [
5940
+ {
5941
+ foreignKeyName: "floriday_api_log_connection_id_fkey";
5942
+ columns: ["connection_id"];
5943
+ isOneToOne: false;
5944
+ referencedRelation: "floriday_connections";
5945
+ referencedColumns: ["id"];
5946
+ },
5947
+ {
5948
+ foreignKeyName: "floriday_api_log_write_log_id_fkey";
5949
+ columns: ["write_log_id"];
5950
+ isOneToOne: false;
5951
+ referencedRelation: "floriday_write_log";
5952
+ referencedColumns: ["id"];
5953
+ }
5954
+ ];
5955
+ };
5725
5956
  floriday_auction_letters_cache: {
5726
5957
  Row: {
5727
5958
  auction_letter_code: string;
@@ -5939,6 +6170,86 @@ export type Database = {
5939
6170
  }
5940
6171
  ];
5941
6172
  };
6173
+ floriday_catalog_prices_cache: {
6174
+ Row: {
6175
+ connection_id: string;
6176
+ created_at: string;
6177
+ currency: string;
6178
+ id: string;
6179
+ is_deleted: boolean;
6180
+ price: number | null;
6181
+ price_group_id: string | null;
6182
+ price_group_name: string | null;
6183
+ price_type: string;
6184
+ raw: Json | null;
6185
+ sales_unit: string | null;
6186
+ sequence_number: number;
6187
+ supplier_article_code: string | null;
6188
+ supply_line_id: string;
6189
+ synced_at: string;
6190
+ trade_item_id: string | null;
6191
+ updated_at: string;
6192
+ valid_from: string | null;
6193
+ valid_to: string | null;
6194
+ week: number | null;
6195
+ year: number | null;
6196
+ };
6197
+ Insert: {
6198
+ connection_id: string;
6199
+ created_at?: string;
6200
+ currency?: string;
6201
+ id?: string;
6202
+ is_deleted?: boolean;
6203
+ price?: number | null;
6204
+ price_group_id?: string | null;
6205
+ price_group_name?: string | null;
6206
+ price_type?: string;
6207
+ raw?: Json | null;
6208
+ sales_unit?: string | null;
6209
+ sequence_number?: number;
6210
+ supplier_article_code?: string | null;
6211
+ supply_line_id: string;
6212
+ synced_at?: string;
6213
+ trade_item_id?: string | null;
6214
+ updated_at?: string;
6215
+ valid_from?: string | null;
6216
+ valid_to?: string | null;
6217
+ week?: number | null;
6218
+ year?: number | null;
6219
+ };
6220
+ Update: {
6221
+ connection_id?: string;
6222
+ created_at?: string;
6223
+ currency?: string;
6224
+ id?: string;
6225
+ is_deleted?: boolean;
6226
+ price?: number | null;
6227
+ price_group_id?: string | null;
6228
+ price_group_name?: string | null;
6229
+ price_type?: string;
6230
+ raw?: Json | null;
6231
+ sales_unit?: string | null;
6232
+ sequence_number?: number;
6233
+ supplier_article_code?: string | null;
6234
+ supply_line_id?: string;
6235
+ synced_at?: string;
6236
+ trade_item_id?: string | null;
6237
+ updated_at?: string;
6238
+ valid_from?: string | null;
6239
+ valid_to?: string | null;
6240
+ week?: number | null;
6241
+ year?: number | null;
6242
+ };
6243
+ Relationships: [
6244
+ {
6245
+ foreignKeyName: "floriday_catalog_prices_cache_connection_id_fkey";
6246
+ columns: ["connection_id"];
6247
+ isOneToOne: false;
6248
+ referencedRelation: "floriday_connections";
6249
+ referencedColumns: ["id"];
6250
+ }
6251
+ ];
6252
+ };
5942
6253
  floriday_clock_presales_cache: {
5943
6254
  Row: {
5944
6255
  buyer_organization_id: string | null;
@@ -6884,40 +7195,103 @@ export type Database = {
6884
7195
  }
6885
7196
  ];
6886
7197
  };
6887
- floriday_logistic_labels_cache: {
7198
+ floriday_link_templates: {
6888
7199
  Row: {
6889
- byte_size: number | null;
6890
- connection_id: string;
6891
- content_type: string;
6892
- fetched_at: string;
6893
- fulfillment_order_id: string;
6894
- id: string;
6895
- logistic_label_code: string;
6896
- storage_path: string;
7200
+ created_at: string;
7201
+ floriday_url_template: string | null;
7202
+ is_active: boolean;
7203
+ label: string;
7204
+ local_url_template: string | null;
7205
+ resource_type: string;
7206
+ updated_at: string;
6897
7207
  };
6898
7208
  Insert: {
6899
- byte_size?: number | null;
6900
- connection_id: string;
6901
- content_type?: string;
6902
- fetched_at?: string;
6903
- fulfillment_order_id: string;
6904
- id?: string;
6905
- logistic_label_code: string;
6906
- storage_path: string;
7209
+ created_at?: string;
7210
+ floriday_url_template?: string | null;
7211
+ is_active?: boolean;
7212
+ label: string;
7213
+ local_url_template?: string | null;
7214
+ resource_type: string;
7215
+ updated_at?: string;
6907
7216
  };
6908
7217
  Update: {
6909
- byte_size?: number | null;
6910
- connection_id?: string;
6911
- content_type?: string;
6912
- fetched_at?: string;
6913
- fulfillment_order_id?: string;
6914
- id?: string;
6915
- logistic_label_code?: string;
6916
- storage_path?: string;
6917
- };
6918
- Relationships: [
6919
- {
6920
- foreignKeyName: "floriday_logistic_labels_cache_connection_id_fkey";
7218
+ created_at?: string;
7219
+ floriday_url_template?: string | null;
7220
+ is_active?: boolean;
7221
+ label?: string;
7222
+ local_url_template?: string | null;
7223
+ resource_type?: string;
7224
+ updated_at?: string;
7225
+ };
7226
+ Relationships: [];
7227
+ };
7228
+ floriday_log_retention: {
7229
+ Row: {
7230
+ created_at: string;
7231
+ direction: string | null;
7232
+ id: string;
7233
+ keep_failed_days: number | null;
7234
+ keep_ok_days: number | null;
7235
+ note: string | null;
7236
+ resource_type: string | null;
7237
+ updated_at: string;
7238
+ };
7239
+ Insert: {
7240
+ created_at?: string;
7241
+ direction?: string | null;
7242
+ id?: string;
7243
+ keep_failed_days?: number | null;
7244
+ keep_ok_days?: number | null;
7245
+ note?: string | null;
7246
+ resource_type?: string | null;
7247
+ updated_at?: string;
7248
+ };
7249
+ Update: {
7250
+ created_at?: string;
7251
+ direction?: string | null;
7252
+ id?: string;
7253
+ keep_failed_days?: number | null;
7254
+ keep_ok_days?: number | null;
7255
+ note?: string | null;
7256
+ resource_type?: string | null;
7257
+ updated_at?: string;
7258
+ };
7259
+ Relationships: [];
7260
+ };
7261
+ floriday_logistic_labels_cache: {
7262
+ Row: {
7263
+ byte_size: number | null;
7264
+ connection_id: string;
7265
+ content_type: string;
7266
+ fetched_at: string;
7267
+ fulfillment_order_id: string;
7268
+ id: string;
7269
+ logistic_label_code: string;
7270
+ storage_path: string;
7271
+ };
7272
+ Insert: {
7273
+ byte_size?: number | null;
7274
+ connection_id: string;
7275
+ content_type?: string;
7276
+ fetched_at?: string;
7277
+ fulfillment_order_id: string;
7278
+ id?: string;
7279
+ logistic_label_code: string;
7280
+ storage_path: string;
7281
+ };
7282
+ Update: {
7283
+ byte_size?: number | null;
7284
+ connection_id?: string;
7285
+ content_type?: string;
7286
+ fetched_at?: string;
7287
+ fulfillment_order_id?: string;
7288
+ id?: string;
7289
+ logistic_label_code?: string;
7290
+ storage_path?: string;
7291
+ };
7292
+ Relationships: [
7293
+ {
7294
+ foreignKeyName: "floriday_logistic_labels_cache_connection_id_fkey";
6921
7295
  columns: ["connection_id"];
6922
7296
  isOneToOne: false;
6923
7297
  referencedRelation: "floriday_connections";
@@ -8654,8 +9028,48 @@ export type Database = {
8654
9028
  };
8655
9029
  Relationships: [];
8656
9030
  };
9031
+ itk_handover_afspraken: {
9032
+ Row: {
9033
+ afgesproken_door: string | null;
9034
+ afgesproken_op: string;
9035
+ besluit: string;
9036
+ created_at: string;
9037
+ item: string;
9038
+ modules: string[];
9039
+ sleutel: string;
9040
+ soort: string;
9041
+ updated_at: string;
9042
+ versie_vingerafdruk: string;
9043
+ };
9044
+ Insert: {
9045
+ afgesproken_door?: string | null;
9046
+ afgesproken_op?: string;
9047
+ besluit?: string;
9048
+ created_at?: string;
9049
+ item?: string;
9050
+ modules?: string[];
9051
+ sleutel: string;
9052
+ soort?: string;
9053
+ updated_at?: string;
9054
+ versie_vingerafdruk?: string;
9055
+ };
9056
+ Update: {
9057
+ afgesproken_door?: string | null;
9058
+ afgesproken_op?: string;
9059
+ besluit?: string;
9060
+ created_at?: string;
9061
+ item?: string;
9062
+ modules?: string[];
9063
+ sleutel?: string;
9064
+ soort?: string;
9065
+ updated_at?: string;
9066
+ versie_vingerafdruk?: string;
9067
+ };
9068
+ Relationships: [];
9069
+ };
8657
9070
  itk_handover_github_scan: {
8658
9071
  Row: {
9072
+ genegeerd_op: string | null;
8659
9073
  gescand_op: string;
8660
9074
  gevonden: boolean;
8661
9075
  melding: string | null;
@@ -8663,6 +9077,7 @@ export type Database = {
8663
9077
  repo: string;
8664
9078
  };
8665
9079
  Insert: {
9080
+ genegeerd_op?: string | null;
8666
9081
  gescand_op?: string;
8667
9082
  gevonden?: boolean;
8668
9083
  melding?: string | null;
@@ -8670,6 +9085,7 @@ export type Database = {
8670
9085
  repo: string;
8671
9086
  };
8672
9087
  Update: {
9088
+ genegeerd_op?: string | null;
8673
9089
  gescand_op?: string;
8674
9090
  gevonden?: boolean;
8675
9091
  melding?: string | null;
@@ -8678,13 +9094,45 @@ export type Database = {
8678
9094
  };
8679
9095
  Relationships: [];
8680
9096
  };
9097
+ itk_handover_github_voortgang: {
9098
+ Row: {
9099
+ bijgewerkt_op: string;
9100
+ huidige_repo: string | null;
9101
+ id: boolean;
9102
+ klaar: number;
9103
+ loopt: boolean;
9104
+ totaal: number;
9105
+ };
9106
+ Insert: {
9107
+ bijgewerkt_op?: string;
9108
+ huidige_repo?: string | null;
9109
+ id?: boolean;
9110
+ klaar?: number;
9111
+ loopt?: boolean;
9112
+ totaal?: number;
9113
+ };
9114
+ Update: {
9115
+ bijgewerkt_op?: string;
9116
+ huidige_repo?: string | null;
9117
+ id?: boolean;
9118
+ klaar?: number;
9119
+ loopt?: boolean;
9120
+ totaal?: number;
9121
+ };
9122
+ Relationships: [];
9123
+ };
8681
9124
  itk_handover_module_meta: {
8682
9125
  Row: {
8683
9126
  check_aangevraagd_op: string | null;
8684
9127
  check_nodig: boolean;
8685
9128
  check_reden: string | null;
8686
9129
  created_at: string;
9130
+ md_bron: boolean;
9131
+ md_bron_op: string | null;
9132
+ md_bron_pad: string | null;
8687
9133
  module_id: string;
9134
+ nieuw_gezien: boolean;
9135
+ nieuw_gezien_op: string | null;
8688
9136
  project_url: string | null;
8689
9137
  publicatie_url: string | null;
8690
9138
  updated_at: string;
@@ -8694,7 +9142,12 @@ export type Database = {
8694
9142
  check_nodig?: boolean;
8695
9143
  check_reden?: string | null;
8696
9144
  created_at?: string;
9145
+ md_bron?: boolean;
9146
+ md_bron_op?: string | null;
9147
+ md_bron_pad?: string | null;
8697
9148
  module_id: string;
9149
+ nieuw_gezien?: boolean;
9150
+ nieuw_gezien_op?: string | null;
8698
9151
  project_url?: string | null;
8699
9152
  publicatie_url?: string | null;
8700
9153
  updated_at?: string;
@@ -8704,13 +9157,45 @@ export type Database = {
8704
9157
  check_nodig?: boolean;
8705
9158
  check_reden?: string | null;
8706
9159
  created_at?: string;
9160
+ md_bron?: boolean;
9161
+ md_bron_op?: string | null;
9162
+ md_bron_pad?: string | null;
8707
9163
  module_id?: string;
9164
+ nieuw_gezien?: boolean;
9165
+ nieuw_gezien_op?: string | null;
8708
9166
  project_url?: string | null;
8709
9167
  publicatie_url?: string | null;
8710
9168
  updated_at?: string;
8711
9169
  };
8712
9170
  Relationships: [];
8713
9171
  };
9172
+ itk_handover_module_naam: {
9173
+ Row: {
9174
+ bron_repo: string;
9175
+ created_at: string;
9176
+ module_id: string;
9177
+ standaardnaam: string | null;
9178
+ updated_at: string;
9179
+ weergavenaam: string;
9180
+ };
9181
+ Insert: {
9182
+ bron_repo?: string;
9183
+ created_at?: string;
9184
+ module_id: string;
9185
+ standaardnaam?: string | null;
9186
+ updated_at?: string;
9187
+ weergavenaam: string;
9188
+ };
9189
+ Update: {
9190
+ bron_repo?: string;
9191
+ created_at?: string;
9192
+ module_id?: string;
9193
+ standaardnaam?: string | null;
9194
+ updated_at?: string;
9195
+ weergavenaam?: string;
9196
+ };
9197
+ Relationships: [];
9198
+ };
8714
9199
  itk_handover_project_modules: {
8715
9200
  Row: {
8716
9201
  created_at: string;
@@ -8826,6 +9311,7 @@ export type Database = {
8826
9311
  };
8827
9312
  itk_module_handovers: {
8828
9313
  Row: {
9314
+ bekende_risicos: string[];
8829
9315
  bevindingen: string | null;
8830
9316
  bezit_tabellen: string[];
8831
9317
  bron_commit: string | null;
@@ -8844,6 +9330,7 @@ export type Database = {
8844
9330
  inhoud_md: string;
8845
9331
  is_actueel: boolean;
8846
9332
  is_gearchiveerd: boolean;
9333
+ laatst_bevestigd_op: string | null;
8847
9334
  laatst_gecontroleerd_op: string | null;
8848
9335
  module_id: string;
8849
9336
  module_titel: string;
@@ -8853,6 +9340,7 @@ export type Database = {
8853
9340
  versie: number;
8854
9341
  };
8855
9342
  Insert: {
9343
+ bekende_risicos?: string[];
8856
9344
  bevindingen?: string | null;
8857
9345
  bezit_tabellen?: string[];
8858
9346
  bron_commit?: string | null;
@@ -8871,6 +9359,7 @@ export type Database = {
8871
9359
  inhoud_md: string;
8872
9360
  is_actueel?: boolean;
8873
9361
  is_gearchiveerd?: boolean;
9362
+ laatst_bevestigd_op?: string | null;
8874
9363
  laatst_gecontroleerd_op?: string | null;
8875
9364
  module_id: string;
8876
9365
  module_titel: string;
@@ -8880,6 +9369,7 @@ export type Database = {
8880
9369
  versie?: number;
8881
9370
  };
8882
9371
  Update: {
9372
+ bekende_risicos?: string[];
8883
9373
  bevindingen?: string | null;
8884
9374
  bezit_tabellen?: string[];
8885
9375
  bron_commit?: string | null;
@@ -8898,6 +9388,7 @@ export type Database = {
8898
9388
  inhoud_md?: string;
8899
9389
  is_actueel?: boolean;
8900
9390
  is_gearchiveerd?: boolean;
9391
+ laatst_bevestigd_op?: string | null;
8901
9392
  laatst_gecontroleerd_op?: string | null;
8902
9393
  module_id?: string;
8903
9394
  module_titel?: string;
@@ -9111,6 +9602,56 @@ export type Database = {
9111
9602
  };
9112
9603
  Relationships: [];
9113
9604
  };
9605
+ itk_offerte_werkbon_queue: {
9606
+ Row: {
9607
+ bron_werkbon_id: string | null;
9608
+ created_at: string;
9609
+ foutmelding: string | null;
9610
+ id: string;
9611
+ offerte_id: string;
9612
+ payload: Json;
9613
+ status: string;
9614
+ updated_at: string;
9615
+ verwerkt_op: string | null;
9616
+ werkbon_id: string | null;
9617
+ werkbon_nummer: string | null;
9618
+ };
9619
+ Insert: {
9620
+ bron_werkbon_id?: string | null;
9621
+ created_at?: string;
9622
+ foutmelding?: string | null;
9623
+ id?: string;
9624
+ offerte_id: string;
9625
+ payload?: Json;
9626
+ status?: string;
9627
+ updated_at?: string;
9628
+ verwerkt_op?: string | null;
9629
+ werkbon_id?: string | null;
9630
+ werkbon_nummer?: string | null;
9631
+ };
9632
+ Update: {
9633
+ bron_werkbon_id?: string | null;
9634
+ created_at?: string;
9635
+ foutmelding?: string | null;
9636
+ id?: string;
9637
+ offerte_id?: string;
9638
+ payload?: Json;
9639
+ status?: string;
9640
+ updated_at?: string;
9641
+ verwerkt_op?: string | null;
9642
+ werkbon_id?: string | null;
9643
+ werkbon_nummer?: string | null;
9644
+ };
9645
+ Relationships: [
9646
+ {
9647
+ foreignKeyName: "itk_offerte_werkbon_queue_offerte_id_fkey";
9648
+ columns: ["offerte_id"];
9649
+ isOneToOne: false;
9650
+ referencedRelation: "itk_offertes";
9651
+ referencedColumns: ["id"];
9652
+ }
9653
+ ];
9654
+ };
9114
9655
  itk_offertes: {
9115
9656
  Row: {
9116
9657
  ai_generated: boolean;
@@ -9313,6 +9854,30 @@ export type Database = {
9313
9854
  }
9314
9855
  ];
9315
9856
  };
9857
+ job_locks: {
9858
+ Row: {
9859
+ created_at: string;
9860
+ lock_key: string;
9861
+ locked_until: string;
9862
+ owner: string | null;
9863
+ updated_at: string;
9864
+ };
9865
+ Insert: {
9866
+ created_at?: string;
9867
+ lock_key: string;
9868
+ locked_until: string;
9869
+ owner?: string | null;
9870
+ updated_at?: string;
9871
+ };
9872
+ Update: {
9873
+ created_at?: string;
9874
+ lock_key?: string;
9875
+ locked_until?: string;
9876
+ owner?: string | null;
9877
+ updated_at?: string;
9878
+ };
9879
+ Relationships: [];
9880
+ };
9316
9881
  layout_logos: {
9317
9882
  Row: {
9318
9883
  bestand_url: string;
@@ -10308,6 +10873,36 @@ export type Database = {
10308
10873
  };
10309
10874
  Relationships: [];
10310
10875
  };
10876
+ logistics_floriday_push_refusals: {
10877
+ Row: {
10878
+ action: string | null;
10879
+ created_at: string;
10880
+ id: string;
10881
+ order_ref: string;
10882
+ reason: string;
10883
+ source_module: string | null;
10884
+ source_shell: string | null;
10885
+ };
10886
+ Insert: {
10887
+ action?: string | null;
10888
+ created_at?: string;
10889
+ id?: string;
10890
+ order_ref: string;
10891
+ reason: string;
10892
+ source_module?: string | null;
10893
+ source_shell?: string | null;
10894
+ };
10895
+ Update: {
10896
+ action?: string | null;
10897
+ created_at?: string;
10898
+ id?: string;
10899
+ order_ref?: string;
10900
+ reason?: string;
10901
+ source_module?: string | null;
10902
+ source_shell?: string | null;
10903
+ };
10904
+ Relationships: [];
10905
+ };
10311
10906
  logistics_floriday_pushes: {
10312
10907
  Row: {
10313
10908
  attempts: number;
@@ -10383,6 +10978,42 @@ export type Database = {
10383
10978
  };
10384
10979
  Relationships: [];
10385
10980
  };
10981
+ logistics_floriday_status_sends: {
10982
+ Row: {
10983
+ action: string;
10984
+ created_at: string;
10985
+ detail: string | null;
10986
+ http_status: number | null;
10987
+ id: string;
10988
+ ok: boolean;
10989
+ order_ref: string;
10990
+ source_module: string | null;
10991
+ source_shell: string | null;
10992
+ };
10993
+ Insert: {
10994
+ action: string;
10995
+ created_at?: string;
10996
+ detail?: string | null;
10997
+ http_status?: number | null;
10998
+ id?: string;
10999
+ ok?: boolean;
11000
+ order_ref: string;
11001
+ source_module?: string | null;
11002
+ source_shell?: string | null;
11003
+ };
11004
+ Update: {
11005
+ action?: string;
11006
+ created_at?: string;
11007
+ detail?: string | null;
11008
+ http_status?: number | null;
11009
+ id?: string;
11010
+ ok?: boolean;
11011
+ order_ref?: string;
11012
+ source_module?: string | null;
11013
+ source_shell?: string | null;
11014
+ };
11015
+ Relationships: [];
11016
+ };
10386
11017
  logistics_formulas: {
10387
11018
  Row: {
10388
11019
  created_at: string;
@@ -10457,52 +11088,215 @@ export type Database = {
10457
11088
  };
10458
11089
  Relationships: [];
10459
11090
  };
10460
- logistics_pickup_moments: {
11091
+ logistics_opening_exceptions: {
10461
11092
  Row: {
10462
- carrier_ref: string | null;
11093
+ closes: string | null;
10463
11094
  created_at: string;
11095
+ day: string;
10464
11096
  id: string;
10465
- label: string | null;
10466
- moment_date: string;
10467
- pickup_time: string;
10468
- sequence: number;
10469
- updated_at: string;
10470
- user_id: string;
11097
+ is_closed: boolean;
11098
+ note: string | null;
11099
+ opens: string | null;
10471
11100
  };
10472
11101
  Insert: {
10473
- carrier_ref?: string | null;
11102
+ closes?: string | null;
10474
11103
  created_at?: string;
11104
+ day: string;
10475
11105
  id?: string;
10476
- label?: string | null;
10477
- moment_date: string;
10478
- pickup_time: string;
10479
- sequence?: number;
10480
- updated_at?: string;
10481
- user_id?: string;
11106
+ is_closed?: boolean;
11107
+ note?: string | null;
11108
+ opens?: string | null;
10482
11109
  };
10483
11110
  Update: {
10484
- carrier_ref?: string | null;
11111
+ closes?: string | null;
10485
11112
  created_at?: string;
11113
+ day?: string;
10486
11114
  id?: string;
10487
- label?: string | null;
10488
- moment_date?: string;
10489
- pickup_time?: string;
10490
- sequence?: number;
10491
- updated_at?: string;
10492
- user_id?: string;
11115
+ is_closed?: boolean;
11116
+ note?: string | null;
11117
+ opens?: string | null;
10493
11118
  };
10494
11119
  Relationships: [];
10495
11120
  };
10496
- logistics_plan_queue: {
11121
+ logistics_opening_hours: {
10497
11122
  Row: {
10498
- attempts: number;
10499
- claimed_at: string | null;
10500
- enqueued_at: string;
10501
- error: string | null;
11123
+ closes: string;
11124
+ created_at: string;
10502
11125
  id: string;
10503
- next_attempt_at: string;
11126
+ is_active: boolean;
11127
+ note: string | null;
11128
+ opens: string;
11129
+ weekday: number;
11130
+ };
11131
+ Insert: {
11132
+ closes: string;
11133
+ created_at?: string;
11134
+ id?: string;
11135
+ is_active?: boolean;
11136
+ note?: string | null;
11137
+ opens: string;
11138
+ weekday: number;
11139
+ };
11140
+ Update: {
11141
+ closes?: string;
11142
+ created_at?: string;
11143
+ id?: string;
11144
+ is_active?: boolean;
11145
+ note?: string | null;
11146
+ opens?: string;
11147
+ weekday?: number;
11148
+ };
11149
+ Relationships: [];
11150
+ };
11151
+ logistics_order_merges: {
11152
+ Row: {
11153
+ group_key: string;
11154
+ id: string;
11155
+ items_moved: number;
11156
+ kept_order_id: string;
11157
+ kept_order_number: string | null;
11158
+ merged_at: string;
11159
+ merged_order_id: string;
11160
+ merged_order_number: string | null;
11161
+ sales_order_id: string | null;
11162
+ };
11163
+ Insert: {
11164
+ group_key: string;
11165
+ id?: string;
11166
+ items_moved?: number;
11167
+ kept_order_id: string;
11168
+ kept_order_number?: string | null;
11169
+ merged_at?: string;
11170
+ merged_order_id: string;
11171
+ merged_order_number?: string | null;
11172
+ sales_order_id?: string | null;
11173
+ };
11174
+ Update: {
11175
+ group_key?: string;
11176
+ id?: string;
11177
+ items_moved?: number;
11178
+ kept_order_id?: string;
11179
+ kept_order_number?: string | null;
11180
+ merged_at?: string;
11181
+ merged_order_id?: string;
11182
+ merged_order_number?: string | null;
11183
+ sales_order_id?: string | null;
11184
+ };
11185
+ Relationships: [];
11186
+ };
11187
+ logistics_pick_data_requests: {
11188
+ Row: {
11189
+ actions: Json;
11190
+ created_at: string;
11191
+ event_id: string | null;
11192
+ finished_at: string | null;
11193
+ id: string;
11194
+ missing: Json;
11195
+ order_ref: string;
11196
+ reason: string | null;
11197
+ result: Json | null;
11198
+ status: string;
11199
+ unit_ref: string | null;
11200
+ };
11201
+ Insert: {
11202
+ actions?: Json;
11203
+ created_at?: string;
11204
+ event_id?: string | null;
11205
+ finished_at?: string | null;
11206
+ id?: string;
11207
+ missing?: Json;
11208
+ order_ref: string;
11209
+ reason?: string | null;
11210
+ result?: Json | null;
11211
+ status?: string;
11212
+ unit_ref?: string | null;
11213
+ };
11214
+ Update: {
11215
+ actions?: Json;
11216
+ created_at?: string;
11217
+ event_id?: string | null;
11218
+ finished_at?: string | null;
11219
+ id?: string;
11220
+ missing?: Json;
11221
+ order_ref?: string;
11222
+ reason?: string | null;
11223
+ result?: Json | null;
11224
+ status?: string;
11225
+ unit_ref?: string | null;
11226
+ };
11227
+ Relationships: [];
11228
+ };
11229
+ logistics_pickup_moments: {
11230
+ Row: {
11231
+ carrier_ref: string | null;
11232
+ created_at: string;
11233
+ id: string;
11234
+ label: string | null;
11235
+ moment_date: string;
11236
+ pickup_time: string;
11237
+ sequence: number;
11238
+ updated_at: string;
11239
+ user_id: string;
11240
+ };
11241
+ Insert: {
11242
+ carrier_ref?: string | null;
11243
+ created_at?: string;
11244
+ id?: string;
11245
+ label?: string | null;
11246
+ moment_date: string;
11247
+ pickup_time: string;
11248
+ sequence?: number;
11249
+ updated_at?: string;
11250
+ user_id?: string;
11251
+ };
11252
+ Update: {
11253
+ carrier_ref?: string | null;
11254
+ created_at?: string;
11255
+ id?: string;
11256
+ label?: string | null;
11257
+ moment_date?: string;
11258
+ pickup_time?: string;
11259
+ sequence?: number;
11260
+ updated_at?: string;
11261
+ user_id?: string;
11262
+ };
11263
+ Relationships: [];
11264
+ };
11265
+ logistics_plan_locks: {
11266
+ Row: {
11267
+ created_at: string;
11268
+ lock_key: string;
11269
+ locked_until: string;
11270
+ owner: string | null;
11271
+ updated_at: string;
11272
+ };
11273
+ Insert: {
11274
+ created_at?: string;
11275
+ lock_key: string;
11276
+ locked_until: string;
11277
+ owner?: string | null;
11278
+ updated_at?: string;
11279
+ };
11280
+ Update: {
11281
+ created_at?: string;
11282
+ lock_key?: string;
11283
+ locked_until?: string;
11284
+ owner?: string | null;
11285
+ updated_at?: string;
11286
+ };
11287
+ Relationships: [];
11288
+ };
11289
+ logistics_plan_queue: {
11290
+ Row: {
11291
+ attempts: number;
11292
+ claimed_at: string | null;
11293
+ enqueued_at: string;
11294
+ error: string | null;
11295
+ id: string;
11296
+ next_attempt_at: string;
10504
11297
  order_id: string;
10505
11298
  reason: string;
11299
+ reason_code: string | null;
10506
11300
  status: string;
10507
11301
  updated_at: string;
10508
11302
  };
@@ -10515,6 +11309,7 @@ export type Database = {
10515
11309
  next_attempt_at?: string;
10516
11310
  order_id: string;
10517
11311
  reason?: string;
11312
+ reason_code?: string | null;
10518
11313
  status?: string;
10519
11314
  updated_at?: string;
10520
11315
  };
@@ -10527,6 +11322,7 @@ export type Database = {
10527
11322
  next_attempt_at?: string;
10528
11323
  order_id?: string;
10529
11324
  reason?: string;
11325
+ reason_code?: string | null;
10530
11326
  status?: string;
10531
11327
  updated_at?: string;
10532
11328
  };
@@ -10920,6 +11716,69 @@ export type Database = {
10920
11716
  };
10921
11717
  Relationships: [];
10922
11718
  };
11719
+ logistics_slip_shipping_note: {
11720
+ Row: {
11721
+ attempts: number;
11722
+ batch_key: string | null;
11723
+ cart_id: string | null;
11724
+ created_at: string;
11725
+ error: string | null;
11726
+ error_code: string | null;
11727
+ fulfillment_order_id: string | null;
11728
+ id: string;
11729
+ locked_until: string | null;
11730
+ next_attempt_at: string | null;
11731
+ order_id: string | null;
11732
+ order_number: string | null;
11733
+ print_job_id: string | null;
11734
+ printer_id: string | null;
11735
+ retry_class: string | null;
11736
+ slip_job_id: string;
11737
+ status: string;
11738
+ updated_at: string;
11739
+ };
11740
+ Insert: {
11741
+ attempts?: number;
11742
+ batch_key?: string | null;
11743
+ cart_id?: string | null;
11744
+ created_at?: string;
11745
+ error?: string | null;
11746
+ error_code?: string | null;
11747
+ fulfillment_order_id?: string | null;
11748
+ id?: string;
11749
+ locked_until?: string | null;
11750
+ next_attempt_at?: string | null;
11751
+ order_id?: string | null;
11752
+ order_number?: string | null;
11753
+ print_job_id?: string | null;
11754
+ printer_id?: string | null;
11755
+ retry_class?: string | null;
11756
+ slip_job_id: string;
11757
+ status?: string;
11758
+ updated_at?: string;
11759
+ };
11760
+ Update: {
11761
+ attempts?: number;
11762
+ batch_key?: string | null;
11763
+ cart_id?: string | null;
11764
+ created_at?: string;
11765
+ error?: string | null;
11766
+ error_code?: string | null;
11767
+ fulfillment_order_id?: string | null;
11768
+ id?: string;
11769
+ locked_until?: string | null;
11770
+ next_attempt_at?: string | null;
11771
+ order_id?: string | null;
11772
+ order_number?: string | null;
11773
+ print_job_id?: string | null;
11774
+ printer_id?: string | null;
11775
+ retry_class?: string | null;
11776
+ slip_job_id?: string;
11777
+ status?: string;
11778
+ updated_at?: string;
11779
+ };
11780
+ Relationships: [];
11781
+ };
10923
11782
  logistics_staff_planning: {
10924
11783
  Row: {
10925
11784
  created_at: string;
@@ -11244,92 +12103,365 @@ export type Database = {
11244
12103
  }
11245
12104
  ];
11246
12105
  };
11247
- logistics_variables: {
12106
+ logistics_tick_heartbeat: {
11248
12107
  Row: {
11249
- created_at: string;
11250
- default_value: string | null;
11251
- description: string | null;
11252
- id: string;
11253
- is_builtin: boolean;
11254
- key: string;
11255
- label: string;
11256
- updated_at: string;
11257
- user_id: string;
11258
- value_type: string;
12108
+ id: boolean;
12109
+ last_tick_at: string;
11259
12110
  };
11260
12111
  Insert: {
11261
- created_at?: string;
11262
- default_value?: string | null;
11263
- description?: string | null;
11264
- id?: string;
11265
- is_builtin?: boolean;
11266
- key: string;
11267
- label: string;
11268
- updated_at?: string;
11269
- user_id: string;
11270
- value_type: string;
12112
+ id?: boolean;
12113
+ last_tick_at?: string;
11271
12114
  };
11272
12115
  Update: {
11273
- created_at?: string;
11274
- default_value?: string | null;
11275
- description?: string | null;
11276
- id?: string;
11277
- is_builtin?: boolean;
11278
- key?: string;
11279
- label?: string;
11280
- updated_at?: string;
11281
- user_id?: string;
11282
- value_type?: string;
12116
+ id?: boolean;
12117
+ last_tick_at?: string;
11283
12118
  };
11284
12119
  Relationships: [];
11285
12120
  };
11286
- mailbox_ai_goal_prompts: {
12121
+ logistics_time_settings: {
11287
12122
  Row: {
11288
- created_at: string;
11289
- goal_key: string;
11290
- id: string;
11291
- system_prompt: string;
12123
+ id: boolean;
12124
+ timezone: string;
11292
12125
  updated_at: string;
11293
12126
  };
11294
12127
  Insert: {
11295
- created_at?: string;
11296
- goal_key: string;
11297
- id?: string;
11298
- system_prompt?: string;
12128
+ id?: boolean;
12129
+ timezone: string;
11299
12130
  updated_at?: string;
11300
12131
  };
11301
12132
  Update: {
11302
- created_at?: string;
11303
- goal_key?: string;
11304
- id?: string;
11305
- system_prompt?: string;
12133
+ id?: boolean;
12134
+ timezone?: string;
11306
12135
  updated_at?: string;
11307
12136
  };
11308
12137
  Relationships: [];
11309
12138
  };
11310
- mailbox_ai_settings: {
12139
+ logistics_trace_events: {
11311
12140
  Row: {
11312
- active_goal_key: string | null;
11313
- created_at: string;
11314
- enabled: boolean;
11315
- id: string;
11316
- required_fields: string[];
11317
- singleton: boolean;
11318
- system_prompt: string | null;
11319
- updated_at: string;
12141
+ actor: string | null;
12142
+ attempts: number;
12143
+ calc: Json | null;
12144
+ cart_ref: string | null;
12145
+ created_at: string;
12146
+ db_action: string | null;
12147
+ db_new: Json | null;
12148
+ db_old: Json | null;
12149
+ db_record: string | null;
12150
+ db_table: string | null;
12151
+ decision: string | null;
12152
+ duration_ms: number | null;
12153
+ error: string | null;
12154
+ error_class: string | null;
12155
+ external_action: string | null;
12156
+ external_ref: string | null;
12157
+ external_response: Json | null;
12158
+ external_status: string | null;
12159
+ external_system: string | null;
12160
+ id: string;
12161
+ input: Json | null;
12162
+ next_attempt_at: string | null;
12163
+ next_step: string | null;
12164
+ node_id: string | null;
12165
+ order_ref: string | null;
12166
+ order_source: string | null;
12167
+ output: Json | null;
12168
+ phase: string;
12169
+ reads: Json | null;
12170
+ reason: string | null;
12171
+ rule: string | null;
12172
+ slip_ref: string | null;
12173
+ status: string;
12174
+ step: string;
12175
+ trace_id: string;
12176
+ values_used: Json | null;
11320
12177
  };
11321
12178
  Insert: {
11322
- active_goal_key?: string | null;
11323
- created_at?: string;
11324
- enabled?: boolean;
11325
- id?: string;
11326
- required_fields?: string[];
11327
- singleton?: boolean;
11328
- system_prompt?: string | null;
11329
- updated_at?: string;
11330
- };
11331
- Update: {
11332
- active_goal_key?: string | null;
12179
+ actor?: string | null;
12180
+ attempts?: number;
12181
+ calc?: Json | null;
12182
+ cart_ref?: string | null;
12183
+ created_at?: string;
12184
+ db_action?: string | null;
12185
+ db_new?: Json | null;
12186
+ db_old?: Json | null;
12187
+ db_record?: string | null;
12188
+ db_table?: string | null;
12189
+ decision?: string | null;
12190
+ duration_ms?: number | null;
12191
+ error?: string | null;
12192
+ error_class?: string | null;
12193
+ external_action?: string | null;
12194
+ external_ref?: string | null;
12195
+ external_response?: Json | null;
12196
+ external_status?: string | null;
12197
+ external_system?: string | null;
12198
+ id?: string;
12199
+ input?: Json | null;
12200
+ next_attempt_at?: string | null;
12201
+ next_step?: string | null;
12202
+ node_id?: string | null;
12203
+ order_ref?: string | null;
12204
+ order_source?: string | null;
12205
+ output?: Json | null;
12206
+ phase: string;
12207
+ reads?: Json | null;
12208
+ reason?: string | null;
12209
+ rule?: string | null;
12210
+ slip_ref?: string | null;
12211
+ status: string;
12212
+ step: string;
12213
+ trace_id?: string;
12214
+ values_used?: Json | null;
12215
+ };
12216
+ Update: {
12217
+ actor?: string | null;
12218
+ attempts?: number;
12219
+ calc?: Json | null;
12220
+ cart_ref?: string | null;
12221
+ created_at?: string;
12222
+ db_action?: string | null;
12223
+ db_new?: Json | null;
12224
+ db_old?: Json | null;
12225
+ db_record?: string | null;
12226
+ db_table?: string | null;
12227
+ decision?: string | null;
12228
+ duration_ms?: number | null;
12229
+ error?: string | null;
12230
+ error_class?: string | null;
12231
+ external_action?: string | null;
12232
+ external_ref?: string | null;
12233
+ external_response?: Json | null;
12234
+ external_status?: string | null;
12235
+ external_system?: string | null;
12236
+ id?: string;
12237
+ input?: Json | null;
12238
+ next_attempt_at?: string | null;
12239
+ next_step?: string | null;
12240
+ node_id?: string | null;
12241
+ order_ref?: string | null;
12242
+ order_source?: string | null;
12243
+ output?: Json | null;
12244
+ phase?: string;
12245
+ reads?: Json | null;
12246
+ reason?: string | null;
12247
+ rule?: string | null;
12248
+ slip_ref?: string | null;
12249
+ status?: string;
12250
+ step?: string;
12251
+ trace_id?: string;
12252
+ values_used?: Json | null;
12253
+ };
12254
+ Relationships: [];
12255
+ };
12256
+ logistics_trace_events_archive: {
12257
+ Row: {
12258
+ actor: string | null;
12259
+ attempts: number;
12260
+ calc: Json | null;
12261
+ cart_ref: string | null;
12262
+ created_at: string;
12263
+ db_action: string | null;
12264
+ db_new: Json | null;
12265
+ db_old: Json | null;
12266
+ db_record: string | null;
12267
+ db_table: string | null;
12268
+ decision: string | null;
12269
+ duration_ms: number | null;
12270
+ error: string | null;
12271
+ error_class: string | null;
12272
+ external_action: string | null;
12273
+ external_ref: string | null;
12274
+ external_response: Json | null;
12275
+ external_status: string | null;
12276
+ external_system: string | null;
12277
+ id: string;
12278
+ input: Json | null;
12279
+ next_attempt_at: string | null;
12280
+ next_step: string | null;
12281
+ node_id: string | null;
12282
+ order_ref: string | null;
12283
+ order_source: string | null;
12284
+ output: Json | null;
12285
+ phase: string;
12286
+ reads: Json | null;
12287
+ reason: string | null;
12288
+ rule: string | null;
12289
+ slip_ref: string | null;
12290
+ status: string;
12291
+ step: string;
12292
+ superseded_at: string;
12293
+ superseded_reason: string | null;
12294
+ trace_id: string;
12295
+ values_used: Json | null;
12296
+ };
12297
+ Insert: {
12298
+ actor?: string | null;
12299
+ attempts?: number;
12300
+ calc?: Json | null;
12301
+ cart_ref?: string | null;
12302
+ created_at?: string;
12303
+ db_action?: string | null;
12304
+ db_new?: Json | null;
12305
+ db_old?: Json | null;
12306
+ db_record?: string | null;
12307
+ db_table?: string | null;
12308
+ decision?: string | null;
12309
+ duration_ms?: number | null;
12310
+ error?: string | null;
12311
+ error_class?: string | null;
12312
+ external_action?: string | null;
12313
+ external_ref?: string | null;
12314
+ external_response?: Json | null;
12315
+ external_status?: string | null;
12316
+ external_system?: string | null;
12317
+ id?: string;
12318
+ input?: Json | null;
12319
+ next_attempt_at?: string | null;
12320
+ next_step?: string | null;
12321
+ node_id?: string | null;
12322
+ order_ref?: string | null;
12323
+ order_source?: string | null;
12324
+ output?: Json | null;
12325
+ phase: string;
12326
+ reads?: Json | null;
12327
+ reason?: string | null;
12328
+ rule?: string | null;
12329
+ slip_ref?: string | null;
12330
+ status: string;
12331
+ step: string;
12332
+ superseded_at?: string;
12333
+ superseded_reason?: string | null;
12334
+ trace_id?: string;
12335
+ values_used?: Json | null;
12336
+ };
12337
+ Update: {
12338
+ actor?: string | null;
12339
+ attempts?: number;
12340
+ calc?: Json | null;
12341
+ cart_ref?: string | null;
12342
+ created_at?: string;
12343
+ db_action?: string | null;
12344
+ db_new?: Json | null;
12345
+ db_old?: Json | null;
12346
+ db_record?: string | null;
12347
+ db_table?: string | null;
12348
+ decision?: string | null;
12349
+ duration_ms?: number | null;
12350
+ error?: string | null;
12351
+ error_class?: string | null;
12352
+ external_action?: string | null;
12353
+ external_ref?: string | null;
12354
+ external_response?: Json | null;
12355
+ external_status?: string | null;
12356
+ external_system?: string | null;
12357
+ id?: string;
12358
+ input?: Json | null;
12359
+ next_attempt_at?: string | null;
12360
+ next_step?: string | null;
12361
+ node_id?: string | null;
12362
+ order_ref?: string | null;
12363
+ order_source?: string | null;
12364
+ output?: Json | null;
12365
+ phase?: string;
12366
+ reads?: Json | null;
12367
+ reason?: string | null;
12368
+ rule?: string | null;
12369
+ slip_ref?: string | null;
12370
+ status?: string;
12371
+ step?: string;
12372
+ superseded_at?: string;
12373
+ superseded_reason?: string | null;
12374
+ trace_id?: string;
12375
+ values_used?: Json | null;
12376
+ };
12377
+ Relationships: [];
12378
+ };
12379
+ logistics_variables: {
12380
+ Row: {
12381
+ created_at: string;
12382
+ default_value: string | null;
12383
+ description: string | null;
12384
+ id: string;
12385
+ is_builtin: boolean;
12386
+ key: string;
12387
+ label: string;
12388
+ updated_at: string;
12389
+ user_id: string;
12390
+ value_type: string;
12391
+ };
12392
+ Insert: {
12393
+ created_at?: string;
12394
+ default_value?: string | null;
12395
+ description?: string | null;
12396
+ id?: string;
12397
+ is_builtin?: boolean;
12398
+ key: string;
12399
+ label: string;
12400
+ updated_at?: string;
12401
+ user_id: string;
12402
+ value_type: string;
12403
+ };
12404
+ Update: {
12405
+ created_at?: string;
12406
+ default_value?: string | null;
12407
+ description?: string | null;
12408
+ id?: string;
12409
+ is_builtin?: boolean;
12410
+ key?: string;
12411
+ label?: string;
12412
+ updated_at?: string;
12413
+ user_id?: string;
12414
+ value_type?: string;
12415
+ };
12416
+ Relationships: [];
12417
+ };
12418
+ mailbox_ai_goal_prompts: {
12419
+ Row: {
12420
+ created_at: string;
12421
+ goal_key: string;
12422
+ id: string;
12423
+ system_prompt: string;
12424
+ updated_at: string;
12425
+ };
12426
+ Insert: {
12427
+ created_at?: string;
12428
+ goal_key: string;
12429
+ id?: string;
12430
+ system_prompt?: string;
12431
+ updated_at?: string;
12432
+ };
12433
+ Update: {
12434
+ created_at?: string;
12435
+ goal_key?: string;
12436
+ id?: string;
12437
+ system_prompt?: string;
12438
+ updated_at?: string;
12439
+ };
12440
+ Relationships: [];
12441
+ };
12442
+ mailbox_ai_settings: {
12443
+ Row: {
12444
+ active_goal_key: string | null;
12445
+ created_at: string;
12446
+ enabled: boolean;
12447
+ id: string;
12448
+ required_fields: string[];
12449
+ singleton: boolean;
12450
+ system_prompt: string | null;
12451
+ updated_at: string;
12452
+ };
12453
+ Insert: {
12454
+ active_goal_key?: string | null;
12455
+ created_at?: string;
12456
+ enabled?: boolean;
12457
+ id?: string;
12458
+ required_fields?: string[];
12459
+ singleton?: boolean;
12460
+ system_prompt?: string | null;
12461
+ updated_at?: string;
12462
+ };
12463
+ Update: {
12464
+ active_goal_key?: string | null;
11333
12465
  created_at?: string;
11334
12466
  enabled?: boolean;
11335
12467
  id?: string;
@@ -11391,6 +12523,7 @@ export type Database = {
11391
12523
  has_attachments: boolean;
11392
12524
  id: string;
11393
12525
  message_id: string | null;
12526
+ preview: string | null;
11394
12527
  profile_id: string | null;
11395
12528
  raw_size: number | null;
11396
12529
  received_at: string | null;
@@ -11414,6 +12547,7 @@ export type Database = {
11414
12547
  has_attachments?: boolean;
11415
12548
  id?: string;
11416
12549
  message_id?: string | null;
12550
+ preview?: string | null;
11417
12551
  profile_id?: string | null;
11418
12552
  raw_size?: number | null;
11419
12553
  received_at?: string | null;
@@ -11437,6 +12571,7 @@ export type Database = {
11437
12571
  has_attachments?: boolean;
11438
12572
  id?: string;
11439
12573
  message_id?: string | null;
12574
+ preview?: string | null;
11440
12575
  profile_id?: string | null;
11441
12576
  raw_size?: number | null;
11442
12577
  received_at?: string | null;
@@ -11472,6 +12607,7 @@ export type Database = {
11472
12607
  };
11473
12608
  mailbox_order_proposals: {
11474
12609
  Row: {
12610
+ ai_ok: boolean | null;
11475
12611
  ai_validation: Json | null;
11476
12612
  confidence: number | null;
11477
12613
  created_at: string;
@@ -11489,6 +12625,7 @@ export type Database = {
11489
12625
  updated_at: string;
11490
12626
  };
11491
12627
  Insert: {
12628
+ ai_ok?: boolean | null;
11492
12629
  ai_validation?: Json | null;
11493
12630
  confidence?: number | null;
11494
12631
  created_at?: string;
@@ -11506,6 +12643,7 @@ export type Database = {
11506
12643
  updated_at?: string;
11507
12644
  };
11508
12645
  Update: {
12646
+ ai_ok?: boolean | null;
11509
12647
  ai_validation?: Json | null;
11510
12648
  confidence?: number | null;
11511
12649
  created_at?: string;
@@ -13708,6 +14846,7 @@ export type Database = {
13708
14846
  customer_name: string;
13709
14847
  deleted_at: string | null;
13710
14848
  delivery_date: string | null;
14849
+ floriday_order_group_key: string | null;
13711
14850
  floriday_sales_order_id: string | null;
13712
14851
  id: string;
13713
14852
  invoice_due_at: string | null;
@@ -13735,6 +14874,7 @@ export type Database = {
13735
14874
  customer_name?: string;
13736
14875
  deleted_at?: string | null;
13737
14876
  delivery_date?: string | null;
14877
+ floriday_order_group_key?: string | null;
13738
14878
  floriday_sales_order_id?: string | null;
13739
14879
  id?: string;
13740
14880
  invoice_due_at?: string | null;
@@ -13762,6 +14902,7 @@ export type Database = {
13762
14902
  customer_name?: string;
13763
14903
  deleted_at?: string | null;
13764
14904
  delivery_date?: string | null;
14905
+ floriday_order_group_key?: string | null;
13765
14906
  floriday_sales_order_id?: string | null;
13766
14907
  id?: string;
13767
14908
  invoice_due_at?: string | null;
@@ -13958,6 +15099,27 @@ export type Database = {
13958
15099
  };
13959
15100
  Relationships: [];
13960
15101
  };
15102
+ pick_buffer_event_cursor: {
15103
+ Row: {
15104
+ created_at: string;
15105
+ id: boolean;
15106
+ last_event_at: string;
15107
+ updated_at: string;
15108
+ };
15109
+ Insert: {
15110
+ created_at?: string;
15111
+ id?: boolean;
15112
+ last_event_at?: string;
15113
+ updated_at?: string;
15114
+ };
15115
+ Update: {
15116
+ created_at?: string;
15117
+ id?: boolean;
15118
+ last_event_at?: string;
15119
+ updated_at?: string;
15120
+ };
15121
+ Relationships: [];
15122
+ };
13961
15123
  pick_countries: {
13962
15124
  Row: {
13963
15125
  active: boolean;
@@ -15085,6 +16247,128 @@ export type Database = {
15085
16247
  }
15086
16248
  ];
15087
16249
  };
16250
+ price_list_rows: {
16251
+ Row: {
16252
+ action: string;
16253
+ created_at: string;
16254
+ id: string;
16255
+ message: string | null;
16256
+ parsed: Json;
16257
+ price_list_id: string;
16258
+ raw: Json;
16259
+ row_number: number;
16260
+ supplier_product_id: string | null;
16261
+ };
16262
+ Insert: {
16263
+ action?: string;
16264
+ created_at?: string;
16265
+ id?: string;
16266
+ message?: string | null;
16267
+ parsed?: Json;
16268
+ price_list_id: string;
16269
+ raw?: Json;
16270
+ row_number: number;
16271
+ supplier_product_id?: string | null;
16272
+ };
16273
+ Update: {
16274
+ action?: string;
16275
+ created_at?: string;
16276
+ id?: string;
16277
+ message?: string | null;
16278
+ parsed?: Json;
16279
+ price_list_id?: string;
16280
+ raw?: Json;
16281
+ row_number?: number;
16282
+ supplier_product_id?: string | null;
16283
+ };
16284
+ Relationships: [
16285
+ {
16286
+ foreignKeyName: "price_list_rows_price_list_id_fkey";
16287
+ columns: ["price_list_id"];
16288
+ isOneToOne: false;
16289
+ referencedRelation: "price_lists";
16290
+ referencedColumns: ["id"];
16291
+ },
16292
+ {
16293
+ foreignKeyName: "price_list_rows_supplier_product_id_fkey";
16294
+ columns: ["supplier_product_id"];
16295
+ isOneToOne: false;
16296
+ referencedRelation: "supplier_products";
16297
+ referencedColumns: ["id"];
16298
+ }
16299
+ ];
16300
+ };
16301
+ price_lists: {
16302
+ Row: {
16303
+ created_at: string;
16304
+ created_by: string | null;
16305
+ file_hash: string | null;
16306
+ file_name: string;
16307
+ file_path: string | null;
16308
+ headers: string[];
16309
+ id: string;
16310
+ preview: Json;
16311
+ processed_at: string | null;
16312
+ reason: string | null;
16313
+ row_count: number;
16314
+ sheet_name: string | null;
16315
+ source: string;
16316
+ stats: Json;
16317
+ status: string;
16318
+ supplier_guess: string | null;
16319
+ supplier_id: string | null;
16320
+ updated_at: string;
16321
+ };
16322
+ Insert: {
16323
+ created_at?: string;
16324
+ created_by?: string | null;
16325
+ file_hash?: string | null;
16326
+ file_name: string;
16327
+ file_path?: string | null;
16328
+ headers?: string[];
16329
+ id?: string;
16330
+ preview?: Json;
16331
+ processed_at?: string | null;
16332
+ reason?: string | null;
16333
+ row_count?: number;
16334
+ sheet_name?: string | null;
16335
+ source?: string;
16336
+ stats?: Json;
16337
+ status?: string;
16338
+ supplier_guess?: string | null;
16339
+ supplier_id?: string | null;
16340
+ updated_at?: string;
16341
+ };
16342
+ Update: {
16343
+ created_at?: string;
16344
+ created_by?: string | null;
16345
+ file_hash?: string | null;
16346
+ file_name?: string;
16347
+ file_path?: string | null;
16348
+ headers?: string[];
16349
+ id?: string;
16350
+ preview?: Json;
16351
+ processed_at?: string | null;
16352
+ reason?: string | null;
16353
+ row_count?: number;
16354
+ sheet_name?: string | null;
16355
+ source?: string;
16356
+ stats?: Json;
16357
+ status?: string;
16358
+ supplier_guess?: string | null;
16359
+ supplier_id?: string | null;
16360
+ updated_at?: string;
16361
+ };
16362
+ Relationships: [
16363
+ {
16364
+ foreignKeyName: "price_lists_supplier_id_fkey";
16365
+ columns: ["supplier_id"];
16366
+ isOneToOne: false;
16367
+ referencedRelation: "suppliers";
16368
+ referencedColumns: ["id"];
16369
+ }
16370
+ ];
16371
+ };
15088
16372
  print_agents: {
15089
16373
  Row: {
15090
16374
  actief: boolean;
@@ -16699,30 +17983,111 @@ export type Database = {
16699
17983
  }
16700
17984
  ];
16701
17985
  };
16702
- purchase_order_items: {
17986
+ purchase_order_dispatches: {
16703
17987
  Row: {
16704
17988
  created_at: string;
16705
17989
  id: string;
16706
- product_id: string | null;
16707
- product_type: string;
17990
+ last_error: string | null;
17991
+ outbox_id: string | null;
16708
17992
  purchase_order_id: string;
16709
- quantity: number;
17993
+ status: string;
17994
+ supplier_id: string | null;
17995
+ supplier_name: string;
17996
+ to_address: string;
17997
+ updated_at: string;
16710
17998
  };
16711
17999
  Insert: {
16712
18000
  created_at?: string;
16713
18001
  id?: string;
16714
- product_id?: string | null;
16715
- product_type?: string;
18002
+ last_error?: string | null;
18003
+ outbox_id?: string | null;
16716
18004
  purchase_order_id: string;
16717
- quantity?: number;
16718
- };
16719
- Update: {
16720
- created_at?: string;
18005
+ status?: string;
18006
+ supplier_id?: string | null;
18007
+ supplier_name?: string;
18008
+ to_address: string;
18009
+ updated_at?: string;
18010
+ };
18011
+ Update: {
18012
+ created_at?: string;
18013
+ id?: string;
18014
+ last_error?: string | null;
18015
+ outbox_id?: string | null;
18016
+ purchase_order_id?: string;
18017
+ status?: string;
18018
+ supplier_id?: string | null;
18019
+ supplier_name?: string;
18020
+ to_address?: string;
18021
+ updated_at?: string;
18022
+ };
18023
+ Relationships: [
18024
+ {
18025
+ foreignKeyName: "purchase_order_dispatches_purchase_order_id_fkey";
18026
+ columns: ["purchase_order_id"];
18027
+ isOneToOne: false;
18028
+ referencedRelation: "purchase_orders";
18029
+ referencedColumns: ["id"];
18030
+ },
18031
+ {
18032
+ foreignKeyName: "purchase_order_dispatches_supplier_id_fkey";
18033
+ columns: ["supplier_id"];
18034
+ isOneToOne: false;
18035
+ referencedRelation: "suppliers";
18036
+ referencedColumns: ["id"];
18037
+ }
18038
+ ];
18039
+ };
18040
+ purchase_order_items: {
18041
+ Row: {
18042
+ article_number: string | null;
18043
+ created_at: string;
18044
+ delivery_date: string | null;
18045
+ id: string;
18046
+ name: string;
18047
+ note: string | null;
18048
+ pot_size: string | null;
18049
+ product_id: string | null;
18050
+ product_type: string;
18051
+ purchase_order_id: string;
18052
+ quantity: number;
18053
+ supplier_id: string | null;
18054
+ supplier_product_id: string | null;
18055
+ unit_price_cents: number;
18056
+ updated_at: string;
18057
+ };
18058
+ Insert: {
18059
+ article_number?: string | null;
18060
+ created_at?: string;
18061
+ delivery_date?: string | null;
18062
+ id?: string;
18063
+ name?: string;
18064
+ note?: string | null;
18065
+ pot_size?: string | null;
18066
+ product_id?: string | null;
18067
+ product_type?: string;
18068
+ purchase_order_id: string;
18069
+ quantity?: number;
18070
+ supplier_id?: string | null;
18071
+ supplier_product_id?: string | null;
18072
+ unit_price_cents?: number;
18073
+ updated_at?: string;
18074
+ };
18075
+ Update: {
18076
+ article_number?: string | null;
18077
+ created_at?: string;
18078
+ delivery_date?: string | null;
16721
18079
  id?: string;
18080
+ name?: string;
18081
+ note?: string | null;
18082
+ pot_size?: string | null;
16722
18083
  product_id?: string | null;
16723
18084
  product_type?: string;
16724
18085
  purchase_order_id?: string;
16725
18086
  quantity?: number;
18087
+ supplier_id?: string | null;
18088
+ supplier_product_id?: string | null;
18089
+ unit_price_cents?: number;
18090
+ updated_at?: string;
16726
18091
  };
16727
18092
  Relationships: [
16728
18093
  {
@@ -16745,44 +18110,73 @@ export type Database = {
16745
18110
  isOneToOne: false;
16746
18111
  referencedRelation: "purchase_orders";
16747
18112
  referencedColumns: ["id"];
18113
+ },
18114
+ {
18115
+ foreignKeyName: "purchase_order_items_supplier_id_fkey";
18116
+ columns: ["supplier_id"];
18117
+ isOneToOne: false;
18118
+ referencedRelation: "suppliers";
18119
+ referencedColumns: ["id"];
18120
+ },
18121
+ {
18122
+ foreignKeyName: "purchase_order_items_supplier_product_id_fkey";
18123
+ columns: ["supplier_product_id"];
18124
+ isOneToOne: false;
18125
+ referencedRelation: "supplier_products";
18126
+ referencedColumns: ["id"];
16748
18127
  }
16749
18128
  ];
16750
18129
  };
16751
18130
  purchase_orders: {
16752
18131
  Row: {
18132
+ contact_person: string | null;
16753
18133
  created_at: string;
18134
+ created_by: string | null;
16754
18135
  expected_delivery_date: string;
16755
18136
  id: string;
16756
18137
  location_id: string | null;
16757
18138
  notes: string | null;
16758
18139
  order_number: string;
18140
+ reference: string | null;
18141
+ sent_at: string | null;
16759
18142
  status: string;
16760
18143
  supplier_id: string | null;
16761
18144
  supplier_name: string;
18145
+ total_cents: number;
16762
18146
  updated_at: string;
16763
18147
  };
16764
18148
  Insert: {
18149
+ contact_person?: string | null;
16765
18150
  created_at?: string;
16766
- expected_delivery_date: string;
18151
+ created_by?: string | null;
18152
+ expected_delivery_date?: string;
16767
18153
  id?: string;
16768
18154
  location_id?: string | null;
16769
18155
  notes?: string | null;
16770
- order_number: string;
18156
+ order_number?: string;
18157
+ reference?: string | null;
18158
+ sent_at?: string | null;
16771
18159
  status?: string;
16772
18160
  supplier_id?: string | null;
16773
18161
  supplier_name?: string;
18162
+ total_cents?: number;
16774
18163
  updated_at?: string;
16775
18164
  };
16776
18165
  Update: {
18166
+ contact_person?: string | null;
16777
18167
  created_at?: string;
18168
+ created_by?: string | null;
16778
18169
  expected_delivery_date?: string;
16779
18170
  id?: string;
16780
18171
  location_id?: string | null;
16781
18172
  notes?: string | null;
16782
18173
  order_number?: string;
18174
+ reference?: string | null;
18175
+ sent_at?: string | null;
16783
18176
  status?: string;
16784
18177
  supplier_id?: string | null;
16785
18178
  supplier_name?: string;
18179
+ total_cents?: number;
16786
18180
  updated_at?: string;
16787
18181
  };
16788
18182
  Relationships: [
@@ -17693,15 +19087,167 @@ export type Database = {
17693
19087
  };
17694
19088
  Relationships: [];
17695
19089
  };
19090
+ supplier_contacts: {
19091
+ Row: {
19092
+ created_at: string;
19093
+ email: string | null;
19094
+ id: string;
19095
+ is_primary: boolean;
19096
+ name: string;
19097
+ phone: string | null;
19098
+ role: string | null;
19099
+ supplier_id: string;
19100
+ updated_at: string;
19101
+ };
19102
+ Insert: {
19103
+ created_at?: string;
19104
+ email?: string | null;
19105
+ id?: string;
19106
+ is_primary?: boolean;
19107
+ name: string;
19108
+ phone?: string | null;
19109
+ role?: string | null;
19110
+ supplier_id: string;
19111
+ updated_at?: string;
19112
+ };
19113
+ Update: {
19114
+ created_at?: string;
19115
+ email?: string | null;
19116
+ id?: string;
19117
+ is_primary?: boolean;
19118
+ name?: string;
19119
+ phone?: string | null;
19120
+ role?: string | null;
19121
+ supplier_id?: string;
19122
+ updated_at?: string;
19123
+ };
19124
+ Relationships: [
19125
+ {
19126
+ foreignKeyName: "supplier_contacts_supplier_id_fkey";
19127
+ columns: ["supplier_id"];
19128
+ isOneToOne: false;
19129
+ referencedRelation: "suppliers";
19130
+ referencedColumns: ["id"];
19131
+ }
19132
+ ];
19133
+ };
19134
+ supplier_price_history: {
19135
+ Row: {
19136
+ created_at: string;
19137
+ id: string;
19138
+ new_price_cents: number;
19139
+ old_price_cents: number | null;
19140
+ price_list_id: string | null;
19141
+ supplier_id: string | null;
19142
+ supplier_product_id: string;
19143
+ };
19144
+ Insert: {
19145
+ created_at?: string;
19146
+ id?: string;
19147
+ new_price_cents: number;
19148
+ old_price_cents?: number | null;
19149
+ price_list_id?: string | null;
19150
+ supplier_id?: string | null;
19151
+ supplier_product_id: string;
19152
+ };
19153
+ Update: {
19154
+ created_at?: string;
19155
+ id?: string;
19156
+ new_price_cents?: number;
19157
+ old_price_cents?: number | null;
19158
+ price_list_id?: string | null;
19159
+ supplier_id?: string | null;
19160
+ supplier_product_id?: string;
19161
+ };
19162
+ Relationships: [
19163
+ {
19164
+ foreignKeyName: "supplier_price_history_price_list_id_fkey";
19165
+ columns: ["price_list_id"];
19166
+ isOneToOne: false;
19167
+ referencedRelation: "price_lists";
19168
+ referencedColumns: ["id"];
19169
+ },
19170
+ {
19171
+ foreignKeyName: "supplier_price_history_supplier_product_id_fkey";
19172
+ columns: ["supplier_product_id"];
19173
+ isOneToOne: false;
19174
+ referencedRelation: "supplier_products";
19175
+ referencedColumns: ["id"];
19176
+ }
19177
+ ];
19178
+ };
19179
+ supplier_price_list_mappings: {
19180
+ Row: {
19181
+ column_map: Json;
19182
+ created_at: string;
19183
+ deactivate_missing: boolean;
19184
+ decimal_separator: string;
19185
+ expected_headers: string[];
19186
+ extract_pot_from_name: boolean;
19187
+ header_row: number;
19188
+ id: string;
19189
+ max_error_ratio: number;
19190
+ price_is_cents: boolean;
19191
+ sheet_name: string | null;
19192
+ supplier_id: string;
19193
+ updated_at: string;
19194
+ };
19195
+ Insert: {
19196
+ column_map?: Json;
19197
+ created_at?: string;
19198
+ deactivate_missing?: boolean;
19199
+ decimal_separator?: string;
19200
+ expected_headers?: string[];
19201
+ extract_pot_from_name?: boolean;
19202
+ header_row?: number;
19203
+ id?: string;
19204
+ max_error_ratio?: number;
19205
+ price_is_cents?: boolean;
19206
+ sheet_name?: string | null;
19207
+ supplier_id: string;
19208
+ updated_at?: string;
19209
+ };
19210
+ Update: {
19211
+ column_map?: Json;
19212
+ created_at?: string;
19213
+ deactivate_missing?: boolean;
19214
+ decimal_separator?: string;
19215
+ expected_headers?: string[];
19216
+ extract_pot_from_name?: boolean;
19217
+ header_row?: number;
19218
+ id?: string;
19219
+ max_error_ratio?: number;
19220
+ price_is_cents?: boolean;
19221
+ sheet_name?: string | null;
19222
+ supplier_id?: string;
19223
+ updated_at?: string;
19224
+ };
19225
+ Relationships: [
19226
+ {
19227
+ foreignKeyName: "supplier_price_list_mappings_supplier_id_fkey";
19228
+ columns: ["supplier_id"];
19229
+ isOneToOne: true;
19230
+ referencedRelation: "suppliers";
19231
+ referencedColumns: ["id"];
19232
+ }
19233
+ ];
19234
+ };
17696
19235
  supplier_products: {
17697
19236
  Row: {
17698
19237
  article_number: string | null;
19238
+ available_quantity: number;
17699
19239
  created_at: string;
19240
+ height: string | null;
17700
19241
  id: string;
19242
+ is_active: boolean;
19243
+ min_order: number;
17701
19244
  name: string;
17702
19245
  notes: string | null;
19246
+ order_unit: number;
17703
19247
  pot_size: string | null;
17704
19248
  price: number | null;
19249
+ price_cents: number;
19250
+ quality: string | null;
17705
19251
  quantity: number | null;
17706
19252
  supplier_id: string;
17707
19253
  unit: string;
@@ -17709,12 +19255,19 @@ export type Database = {
17709
19255
  };
17710
19256
  Insert: {
17711
19257
  article_number?: string | null;
19258
+ available_quantity?: number;
17712
19259
  created_at?: string;
19260
+ height?: string | null;
17713
19261
  id?: string;
19262
+ is_active?: boolean;
19263
+ min_order?: number;
17714
19264
  name: string;
17715
19265
  notes?: string | null;
19266
+ order_unit?: number;
17716
19267
  pot_size?: string | null;
17717
19268
  price?: number | null;
19269
+ price_cents?: number;
19270
+ quality?: string | null;
17718
19271
  quantity?: number | null;
17719
19272
  supplier_id: string;
17720
19273
  unit?: string;
@@ -17722,12 +19275,19 @@ export type Database = {
17722
19275
  };
17723
19276
  Update: {
17724
19277
  article_number?: string | null;
19278
+ available_quantity?: number;
17725
19279
  created_at?: string;
19280
+ height?: string | null;
17726
19281
  id?: string;
19282
+ is_active?: boolean;
19283
+ min_order?: number;
17727
19284
  name?: string;
17728
19285
  notes?: string | null;
19286
+ order_unit?: number;
17729
19287
  pot_size?: string | null;
17730
19288
  price?: number | null;
19289
+ price_cents?: number;
19290
+ quality?: string | null;
17731
19291
  quantity?: number | null;
17732
19292
  supplier_id?: string;
17733
19293
  unit?: string;
@@ -17746,6 +19306,7 @@ export type Database = {
17746
19306
  suppliers: {
17747
19307
  Row: {
17748
19308
  address: string | null;
19309
+ category: string | null;
17749
19310
  column_mappings: Json | null;
17750
19311
  contact_person: string | null;
17751
19312
  created_at: string;
@@ -17753,13 +19314,24 @@ export type Database = {
17753
19314
  email: string | null;
17754
19315
  id: string;
17755
19316
  imported_file_name: string | null;
19317
+ is_preferred: boolean;
19318
+ kvk_number: string | null;
19319
+ lead_time_days: number | null;
19320
+ min_order_amount_cents: number;
17756
19321
  name: string;
17757
19322
  notes: string | null;
19323
+ order_days: string[];
19324
+ order_email: string | null;
19325
+ payment_terms_days: number | null;
17758
19326
  phone: string | null;
19327
+ status: string;
17759
19328
  updated_at: string;
19329
+ vat_number: string | null;
19330
+ website: string | null;
17760
19331
  };
17761
19332
  Insert: {
17762
19333
  address?: string | null;
19334
+ category?: string | null;
17763
19335
  column_mappings?: Json | null;
17764
19336
  contact_person?: string | null;
17765
19337
  created_at?: string;
@@ -17767,13 +19339,24 @@ export type Database = {
17767
19339
  email?: string | null;
17768
19340
  id?: string;
17769
19341
  imported_file_name?: string | null;
19342
+ is_preferred?: boolean;
19343
+ kvk_number?: string | null;
19344
+ lead_time_days?: number | null;
19345
+ min_order_amount_cents?: number;
17770
19346
  name: string;
17771
19347
  notes?: string | null;
19348
+ order_days?: string[];
19349
+ order_email?: string | null;
19350
+ payment_terms_days?: number | null;
17772
19351
  phone?: string | null;
19352
+ status?: string;
17773
19353
  updated_at?: string;
19354
+ vat_number?: string | null;
19355
+ website?: string | null;
17774
19356
  };
17775
19357
  Update: {
17776
19358
  address?: string | null;
19359
+ category?: string | null;
17777
19360
  column_mappings?: Json | null;
17778
19361
  contact_person?: string | null;
17779
19362
  created_at?: string;
@@ -17781,10 +19364,20 @@ export type Database = {
17781
19364
  email?: string | null;
17782
19365
  id?: string;
17783
19366
  imported_file_name?: string | null;
19367
+ is_preferred?: boolean;
19368
+ kvk_number?: string | null;
19369
+ lead_time_days?: number | null;
19370
+ min_order_amount_cents?: number;
17784
19371
  name?: string;
17785
19372
  notes?: string | null;
19373
+ order_days?: string[];
19374
+ order_email?: string | null;
19375
+ payment_terms_days?: number | null;
17786
19376
  phone?: string | null;
19377
+ status?: string;
17787
19378
  updated_at?: string;
19379
+ vat_number?: string | null;
19380
+ website?: string | null;
17788
19381
  };
17789
19382
  Relationships: [];
17790
19383
  };
@@ -18806,11 +20399,13 @@ export type Database = {
18806
20399
  auto_invoice_trigger_statuses: string[];
18807
20400
  created_at: string;
18808
20401
  debtor_gl_account: string;
20402
+ default_article_code: string | null;
18809
20403
  default_credit_invoice_type: string | null;
18810
20404
  default_gl_account: string;
18811
20405
  default_invoice_type: string;
18812
20406
  default_payment_term_days: number;
18813
20407
  default_vat_code: string;
20408
+ email_purpose: string | null;
18814
20409
  home_country_code: string;
18815
20410
  invoice_enabled_ao: boolean;
18816
20411
  invoice_enabled_fo: boolean;
@@ -18832,11 +20427,13 @@ export type Database = {
18832
20427
  auto_invoice_trigger_statuses?: string[];
18833
20428
  created_at?: string;
18834
20429
  debtor_gl_account?: string;
20430
+ default_article_code?: string | null;
18835
20431
  default_credit_invoice_type?: string | null;
18836
20432
  default_gl_account?: string;
18837
20433
  default_invoice_type?: string;
18838
20434
  default_payment_term_days?: number;
18839
20435
  default_vat_code?: string;
20436
+ email_purpose?: string | null;
18840
20437
  home_country_code?: string;
18841
20438
  invoice_enabled_ao?: boolean;
18842
20439
  invoice_enabled_fo?: boolean;
@@ -18858,11 +20455,13 @@ export type Database = {
18858
20455
  auto_invoice_trigger_statuses?: string[];
18859
20456
  created_at?: string;
18860
20457
  debtor_gl_account?: string;
20458
+ default_article_code?: string | null;
18861
20459
  default_credit_invoice_type?: string | null;
18862
20460
  default_gl_account?: string;
18863
20461
  default_invoice_type?: string;
18864
20462
  default_payment_term_days?: number;
18865
20463
  default_vat_code?: string;
20464
+ email_purpose?: string | null;
18866
20465
  home_country_code?: string;
18867
20466
  invoice_enabled_ao?: boolean;
18868
20467
  invoice_enabled_fo?: boolean;
@@ -19771,6 +21370,36 @@ export type Database = {
19771
21370
  }
19772
21371
  ];
19773
21372
  };
21373
+ voorraad_buffer_state: {
21374
+ Row: {
21375
+ buffer_id: string;
21376
+ buffer_key: string | null;
21377
+ closed_at: string | null;
21378
+ created_at: string;
21379
+ detached_orders: Json;
21380
+ reason: string | null;
21381
+ updated_at: string;
21382
+ };
21383
+ Insert: {
21384
+ buffer_id: string;
21385
+ buffer_key?: string | null;
21386
+ closed_at?: string | null;
21387
+ created_at?: string;
21388
+ detached_orders?: Json;
21389
+ reason?: string | null;
21390
+ updated_at?: string;
21391
+ };
21392
+ Update: {
21393
+ buffer_id?: string;
21394
+ buffer_key?: string | null;
21395
+ closed_at?: string | null;
21396
+ created_at?: string;
21397
+ detached_orders?: Json;
21398
+ reason?: string | null;
21399
+ updated_at?: string;
21400
+ };
21401
+ Relationships: [];
21402
+ };
19774
21403
  voorraad_custom_fields: {
19775
21404
  Row: {
19776
21405
  created_at: string;
@@ -19813,20 +21442,50 @@ export type Database = {
19813
21442
  };
19814
21443
  Relationships: [];
19815
21444
  };
19816
- voorraad_media_upload_failures: {
21445
+ voorraad_logistics_event_log: {
19817
21446
  Row: {
19818
- action: string;
19819
- attempt_number: number;
19820
- caller: string;
19821
- client_user_id: string | null;
19822
- content_type: string | null;
19823
21447
  created_at: string;
19824
- environment: string;
19825
- error_message: string | null;
19826
- filename: string | null;
19827
- id: string;
19828
- idempotency_key: string | null;
19829
- module: string;
21448
+ event_id: string;
21449
+ event_type: string;
21450
+ order_ref: string | null;
21451
+ processed_at: string;
21452
+ result: Json;
21453
+ updated_at: string;
21454
+ };
21455
+ Insert: {
21456
+ created_at?: string;
21457
+ event_id: string;
21458
+ event_type: string;
21459
+ order_ref?: string | null;
21460
+ processed_at?: string;
21461
+ result?: Json;
21462
+ updated_at?: string;
21463
+ };
21464
+ Update: {
21465
+ created_at?: string;
21466
+ event_id?: string;
21467
+ event_type?: string;
21468
+ order_ref?: string | null;
21469
+ processed_at?: string;
21470
+ result?: Json;
21471
+ updated_at?: string;
21472
+ };
21473
+ Relationships: [];
21474
+ };
21475
+ voorraad_media_upload_failures: {
21476
+ Row: {
21477
+ action: string;
21478
+ attempt_number: number;
21479
+ caller: string;
21480
+ client_user_id: string | null;
21481
+ content_type: string | null;
21482
+ created_at: string;
21483
+ environment: string;
21484
+ error_message: string | null;
21485
+ filename: string | null;
21486
+ id: string;
21487
+ idempotency_key: string | null;
21488
+ module: string;
19830
21489
  path: string;
19831
21490
  reference_id: string | null;
19832
21491
  request_body_hash: string | null;
@@ -20082,6 +21741,44 @@ export type Database = {
20082
21741
  }
20083
21742
  ];
20084
21743
  };
21744
+ werkbon_email_state: {
21745
+ Row: {
21746
+ created_at: string;
21747
+ event_id: string;
21748
+ id: string;
21749
+ is_archived: boolean;
21750
+ is_read: boolean;
21751
+ updated_at: string;
21752
+ werkbon_id: string | null;
21753
+ };
21754
+ Insert: {
21755
+ created_at?: string;
21756
+ event_id: string;
21757
+ id?: string;
21758
+ is_archived?: boolean;
21759
+ is_read?: boolean;
21760
+ updated_at?: string;
21761
+ werkbon_id?: string | null;
21762
+ };
21763
+ Update: {
21764
+ created_at?: string;
21765
+ event_id?: string;
21766
+ id?: string;
21767
+ is_archived?: boolean;
21768
+ is_read?: boolean;
21769
+ updated_at?: string;
21770
+ werkbon_id?: string | null;
21771
+ };
21772
+ Relationships: [
21773
+ {
21774
+ foreignKeyName: "werkbon_email_state_event_id_fkey";
21775
+ columns: ["event_id"];
21776
+ isOneToOne: true;
21777
+ referencedRelation: "email_auth_events";
21778
+ referencedColumns: ["id"];
21779
+ }
21780
+ ];
21781
+ };
20085
21782
  werkbon_export_runs: {
20086
21783
  Row: {
20087
21784
  created_at: string;
@@ -20238,6 +21935,147 @@ export type Database = {
20238
21935
  };
20239
21936
  Relationships: [];
20240
21937
  };
21938
+ werkbon_mail_ai_settings: {
21939
+ Row: {
21940
+ created_at: string;
21941
+ id: boolean;
21942
+ required_fields: string[];
21943
+ system_prompt: string;
21944
+ updated_at: string;
21945
+ updated_by: string | null;
21946
+ };
21947
+ Insert: {
21948
+ created_at?: string;
21949
+ id?: boolean;
21950
+ required_fields?: string[];
21951
+ system_prompt?: string;
21952
+ updated_at?: string;
21953
+ updated_by?: string | null;
21954
+ };
21955
+ Update: {
21956
+ created_at?: string;
21957
+ id?: boolean;
21958
+ required_fields?: string[];
21959
+ system_prompt?: string;
21960
+ updated_at?: string;
21961
+ updated_by?: string | null;
21962
+ };
21963
+ Relationships: [];
21964
+ };
21965
+ werkbon_mail_bodies: {
21966
+ Row: {
21967
+ created_at: string;
21968
+ event_id: string;
21969
+ fetch_error: string | null;
21970
+ fetched_at: string | null;
21971
+ html: string | null;
21972
+ updated_at: string;
21973
+ };
21974
+ Insert: {
21975
+ created_at?: string;
21976
+ event_id: string;
21977
+ fetch_error?: string | null;
21978
+ fetched_at?: string | null;
21979
+ html?: string | null;
21980
+ updated_at?: string;
21981
+ };
21982
+ Update: {
21983
+ created_at?: string;
21984
+ event_id?: string;
21985
+ fetch_error?: string | null;
21986
+ fetched_at?: string | null;
21987
+ html?: string | null;
21988
+ updated_at?: string;
21989
+ };
21990
+ Relationships: [];
21991
+ };
21992
+ werkbon_mail_inline_assets: {
21993
+ Row: {
21994
+ content_id: string | null;
21995
+ created_at: string;
21996
+ event_id: string;
21997
+ filename: string | null;
21998
+ id: string;
21999
+ is_inline: boolean;
22000
+ mime_type: string | null;
22001
+ size_bytes: number | null;
22002
+ storage_path: string;
22003
+ };
22004
+ Insert: {
22005
+ content_id?: string | null;
22006
+ created_at?: string;
22007
+ event_id: string;
22008
+ filename?: string | null;
22009
+ id?: string;
22010
+ is_inline?: boolean;
22011
+ mime_type?: string | null;
22012
+ size_bytes?: number | null;
22013
+ storage_path: string;
22014
+ };
22015
+ Update: {
22016
+ content_id?: string | null;
22017
+ created_at?: string;
22018
+ event_id?: string;
22019
+ filename?: string | null;
22020
+ id?: string;
22021
+ is_inline?: boolean;
22022
+ mime_type?: string | null;
22023
+ size_bytes?: number | null;
22024
+ storage_path?: string;
22025
+ };
22026
+ Relationships: [];
22027
+ };
22028
+ werkbon_mail_settings: {
22029
+ Row: {
22030
+ connection_id: string | null;
22031
+ connection_ids: string[];
22032
+ created_at: string;
22033
+ id: boolean;
22034
+ purposes: string[];
22035
+ source: string;
22036
+ updated_at: string;
22037
+ };
22038
+ Insert: {
22039
+ connection_id?: string | null;
22040
+ connection_ids?: string[];
22041
+ created_at?: string;
22042
+ id?: boolean;
22043
+ purposes?: string[];
22044
+ source?: string;
22045
+ updated_at?: string;
22046
+ };
22047
+ Update: {
22048
+ connection_id?: string | null;
22049
+ connection_ids?: string[];
22050
+ created_at?: string;
22051
+ id?: boolean;
22052
+ purposes?: string[];
22053
+ source?: string;
22054
+ updated_at?: string;
22055
+ };
22056
+ Relationships: [];
22057
+ };
22058
+ werkbon_mail_user_settings: {
22059
+ Row: {
22060
+ created_at: string;
22061
+ email_purpose: string | null;
22062
+ updated_at: string;
22063
+ user_id: string;
22064
+ };
22065
+ Insert: {
22066
+ created_at?: string;
22067
+ email_purpose?: string | null;
22068
+ updated_at?: string;
22069
+ user_id: string;
22070
+ };
22071
+ Update: {
22072
+ created_at?: string;
22073
+ email_purpose?: string | null;
22074
+ updated_at?: string;
22075
+ user_id?: string;
22076
+ };
22077
+ Relationships: [];
22078
+ };
20241
22079
  werkbon_materials: {
20242
22080
  Row: {
20243
22081
  article_number: string | null;
@@ -20594,100 +22432,259 @@ export type Database = {
20594
22432
  }
20595
22433
  ];
20596
22434
  };
20597
- werkbon_time_logs: {
22435
+ werkbon_proposal_lines: {
20598
22436
  Row: {
20599
- activity: string;
22437
+ article_number: string | null;
20600
22438
  created_at: string;
20601
- ended_at: string | null;
22439
+ description: string | null;
20602
22440
  id: string;
22441
+ line_type: string;
20603
22442
  note: string | null;
20604
- started_at: string;
20605
- user_id: string;
20606
- werkbon_id: string;
22443
+ package_id: string | null;
22444
+ proposal_id: string;
22445
+ quantity: number | null;
22446
+ sort_order: number;
22447
+ unit: string | null;
22448
+ updated_at: string;
20607
22449
  };
20608
22450
  Insert: {
20609
- activity: string;
22451
+ article_number?: string | null;
20610
22452
  created_at?: string;
20611
- ended_at?: string | null;
22453
+ description?: string | null;
20612
22454
  id?: string;
22455
+ line_type?: string;
20613
22456
  note?: string | null;
20614
- started_at?: string;
20615
- user_id: string;
20616
- werkbon_id: string;
22457
+ package_id?: string | null;
22458
+ proposal_id: string;
22459
+ quantity?: number | null;
22460
+ sort_order?: number;
22461
+ unit?: string | null;
22462
+ updated_at?: string;
20617
22463
  };
20618
22464
  Update: {
20619
- activity?: string;
22465
+ article_number?: string | null;
20620
22466
  created_at?: string;
20621
- ended_at?: string | null;
22467
+ description?: string | null;
20622
22468
  id?: string;
22469
+ line_type?: string;
20623
22470
  note?: string | null;
20624
- started_at?: string;
20625
- user_id?: string;
20626
- werkbon_id?: string;
22471
+ package_id?: string | null;
22472
+ proposal_id?: string;
22473
+ quantity?: number | null;
22474
+ sort_order?: number;
22475
+ unit?: string | null;
22476
+ updated_at?: string;
20627
22477
  };
20628
22478
  Relationships: [
20629
22479
  {
20630
- foreignKeyName: "werkbon_time_logs_werkbon_id_fkey";
20631
- columns: ["werkbon_id"];
20632
- isOneToOne: false;
20633
- referencedRelation: "werkbonnen";
20634
- referencedColumns: ["id"];
20635
- },
20636
- {
20637
- foreignKeyName: "werkbon_time_logs_werkbon_id_fkey";
20638
- columns: ["werkbon_id"];
22480
+ foreignKeyName: "werkbon_proposal_lines_proposal_id_fkey";
22481
+ columns: ["proposal_id"];
20639
22482
  isOneToOne: false;
20640
- referencedRelation: "wo_overview";
22483
+ referencedRelation: "werkbon_proposals";
20641
22484
  referencedColumns: ["id"];
20642
22485
  }
20643
22486
  ];
20644
22487
  };
20645
- werkbonnen: {
22488
+ werkbon_proposals: {
20646
22489
  Row: {
20647
- assigned_user_id: string | null;
22490
+ analysed: boolean;
20648
22491
  budget_mandate_cents: number;
20649
22492
  complaint_description: string | null;
22493
+ contact_id: string | null;
20650
22494
  created_at: string;
20651
- created_by: string | null;
22495
+ created_werkbon_id: string | null;
20652
22496
  customer_id: string | null;
22497
+ deadline_date: string | null;
22498
+ estimated_days: number | null;
22499
+ estimated_duration_minutes: number | null;
22500
+ event_id: string;
22501
+ external_id: string | null;
20653
22502
  externe_referentie: string | null;
20654
- extra_costs_cents: number;
20655
- first_time_fix: boolean | null;
22503
+ from_email: string | null;
22504
+ from_name: string | null;
20656
22505
  id: string;
20657
22506
  internal_notes: string | null;
20658
- needs_detail_review: boolean;
20659
- parent_werkbon_id: string | null;
20660
- parsed_payload: Json | null;
20661
- planning_status: string;
20662
- project_number: string | null;
20663
- review_reasons: string[];
22507
+ parsed_payload: Json;
22508
+ received_at: string | null;
22509
+ reviewed_at: string | null;
22510
+ reviewed_by: string | null;
20664
22511
  room_number: string | null;
20665
22512
  scheduled_end_time: string | null;
20666
22513
  scheduled_start_time: string | null;
20667
- sequence_number: number;
20668
- signature_accepted_at: string | null;
20669
- signature_by_user_id: string | null;
20670
- signature_name: string | null;
20671
- source_email_meta: Json | null;
20672
- source_mailbox_message_id: string | null;
20673
- source_pdf_path: string | null;
20674
- source_type: string;
20675
22514
  status: string;
22515
+ subject: string | null;
20676
22516
  technician_id: string | null;
20677
- technician_notes: string | null;
20678
- technician_notes_raw: string | null;
20679
22517
  technician_task_description: string | null;
20680
22518
  updated_at: string;
20681
- version: number;
20682
22519
  work_address: string | null;
20683
22520
  };
20684
22521
  Insert: {
20685
- assigned_user_id?: string | null;
22522
+ analysed?: boolean;
20686
22523
  budget_mandate_cents?: number;
20687
22524
  complaint_description?: string | null;
22525
+ contact_id?: string | null;
20688
22526
  created_at?: string;
20689
- created_by?: string | null;
22527
+ created_werkbon_id?: string | null;
20690
22528
  customer_id?: string | null;
22529
+ deadline_date?: string | null;
22530
+ estimated_days?: number | null;
22531
+ estimated_duration_minutes?: number | null;
22532
+ event_id: string;
22533
+ external_id?: string | null;
22534
+ externe_referentie?: string | null;
22535
+ from_email?: string | null;
22536
+ from_name?: string | null;
22537
+ id?: string;
22538
+ internal_notes?: string | null;
22539
+ parsed_payload?: Json;
22540
+ received_at?: string | null;
22541
+ reviewed_at?: string | null;
22542
+ reviewed_by?: string | null;
22543
+ room_number?: string | null;
22544
+ scheduled_end_time?: string | null;
22545
+ scheduled_start_time?: string | null;
22546
+ status?: string;
22547
+ subject?: string | null;
22548
+ technician_id?: string | null;
22549
+ technician_task_description?: string | null;
22550
+ updated_at?: string;
22551
+ work_address?: string | null;
22552
+ };
22553
+ Update: {
22554
+ analysed?: boolean;
22555
+ budget_mandate_cents?: number;
22556
+ complaint_description?: string | null;
22557
+ contact_id?: string | null;
22558
+ created_at?: string;
22559
+ created_werkbon_id?: string | null;
22560
+ customer_id?: string | null;
22561
+ deadline_date?: string | null;
22562
+ estimated_days?: number | null;
22563
+ estimated_duration_minutes?: number | null;
22564
+ event_id?: string;
22565
+ external_id?: string | null;
22566
+ externe_referentie?: string | null;
22567
+ from_email?: string | null;
22568
+ from_name?: string | null;
22569
+ id?: string;
22570
+ internal_notes?: string | null;
22571
+ parsed_payload?: Json;
22572
+ received_at?: string | null;
22573
+ reviewed_at?: string | null;
22574
+ reviewed_by?: string | null;
22575
+ room_number?: string | null;
22576
+ scheduled_end_time?: string | null;
22577
+ scheduled_start_time?: string | null;
22578
+ status?: string;
22579
+ subject?: string | null;
22580
+ technician_id?: string | null;
22581
+ technician_task_description?: string | null;
22582
+ updated_at?: string;
22583
+ work_address?: string | null;
22584
+ };
22585
+ Relationships: [];
22586
+ };
22587
+ werkbon_time_logs: {
22588
+ Row: {
22589
+ activity: string;
22590
+ created_at: string;
22591
+ ended_at: string | null;
22592
+ id: string;
22593
+ note: string | null;
22594
+ started_at: string;
22595
+ user_id: string;
22596
+ werkbon_id: string;
22597
+ };
22598
+ Insert: {
22599
+ activity: string;
22600
+ created_at?: string;
22601
+ ended_at?: string | null;
22602
+ id?: string;
22603
+ note?: string | null;
22604
+ started_at?: string;
22605
+ user_id: string;
22606
+ werkbon_id: string;
22607
+ };
22608
+ Update: {
22609
+ activity?: string;
22610
+ created_at?: string;
22611
+ ended_at?: string | null;
22612
+ id?: string;
22613
+ note?: string | null;
22614
+ started_at?: string;
22615
+ user_id?: string;
22616
+ werkbon_id?: string;
22617
+ };
22618
+ Relationships: [
22619
+ {
22620
+ foreignKeyName: "werkbon_time_logs_werkbon_id_fkey";
22621
+ columns: ["werkbon_id"];
22622
+ isOneToOne: false;
22623
+ referencedRelation: "werkbonnen";
22624
+ referencedColumns: ["id"];
22625
+ },
22626
+ {
22627
+ foreignKeyName: "werkbon_time_logs_werkbon_id_fkey";
22628
+ columns: ["werkbon_id"];
22629
+ isOneToOne: false;
22630
+ referencedRelation: "wo_overview";
22631
+ referencedColumns: ["id"];
22632
+ }
22633
+ ];
22634
+ };
22635
+ werkbonnen: {
22636
+ Row: {
22637
+ assigned_user_id: string | null;
22638
+ budget_mandate_cents: number;
22639
+ complaint_description: string | null;
22640
+ created_at: string;
22641
+ created_by: string | null;
22642
+ customer_id: string | null;
22643
+ deadline_date: string | null;
22644
+ estimated_days: number | null;
22645
+ estimated_duration_minutes: number | null;
22646
+ externe_referentie: string | null;
22647
+ extra_costs_cents: number;
22648
+ first_time_fix: boolean | null;
22649
+ id: string;
22650
+ internal_notes: string | null;
22651
+ needs_detail_review: boolean;
22652
+ parent_werkbon_id: string | null;
22653
+ parsed_payload: Json | null;
22654
+ planning_status: string;
22655
+ project_number: string | null;
22656
+ review_reasons: string[];
22657
+ room_number: string | null;
22658
+ scheduled_end_time: string | null;
22659
+ scheduled_start_time: string | null;
22660
+ sequence_number: number;
22661
+ signature_accepted_at: string | null;
22662
+ signature_by_user_id: string | null;
22663
+ signature_name: string | null;
22664
+ source_email_meta: Json | null;
22665
+ source_mailbox_message_id: string | null;
22666
+ source_pdf_path: string | null;
22667
+ source_type: string;
22668
+ status: string;
22669
+ technician_id: string | null;
22670
+ technician_notes: string | null;
22671
+ technician_notes_raw: string | null;
22672
+ technician_task_description: string | null;
22673
+ updated_at: string;
22674
+ version: number;
22675
+ work_address: string | null;
22676
+ workday_hours: number | null;
22677
+ };
22678
+ Insert: {
22679
+ assigned_user_id?: string | null;
22680
+ budget_mandate_cents?: number;
22681
+ complaint_description?: string | null;
22682
+ created_at?: string;
22683
+ created_by?: string | null;
22684
+ customer_id?: string | null;
22685
+ deadline_date?: string | null;
22686
+ estimated_days?: number | null;
22687
+ estimated_duration_minutes?: number | null;
20691
22688
  externe_referentie?: string | null;
20692
22689
  extra_costs_cents?: number;
20693
22690
  first_time_fix?: boolean | null;
@@ -20718,6 +22715,7 @@ export type Database = {
20718
22715
  updated_at?: string;
20719
22716
  version?: number;
20720
22717
  work_address?: string | null;
22718
+ workday_hours?: number | null;
20721
22719
  };
20722
22720
  Update: {
20723
22721
  assigned_user_id?: string | null;
@@ -20726,6 +22724,9 @@ export type Database = {
20726
22724
  created_at?: string;
20727
22725
  created_by?: string | null;
20728
22726
  customer_id?: string | null;
22727
+ deadline_date?: string | null;
22728
+ estimated_days?: number | null;
22729
+ estimated_duration_minutes?: number | null;
20729
22730
  externe_referentie?: string | null;
20730
22731
  extra_costs_cents?: number;
20731
22732
  first_time_fix?: boolean | null;
@@ -20756,6 +22757,7 @@ export type Database = {
20756
22757
  updated_at?: string;
20757
22758
  version?: number;
20758
22759
  work_address?: string | null;
22760
+ workday_hours?: number | null;
20759
22761
  };
20760
22762
  Relationships: [
20761
22763
  {
@@ -21998,6 +24000,10 @@ export type Database = {
21998
24000
  };
21999
24001
  Returns: string;
22000
24002
  };
24003
+ backfill_cart_numbers_day_seq: {
24004
+ Args: never;
24005
+ Returns: number;
24006
+ };
22001
24007
  backfill_open_order_reservations: {
22002
24008
  Args: never;
22003
24009
  Returns: {
@@ -22036,6 +24042,15 @@ export type Database = {
22036
24042
  Args: never;
22037
24043
  Returns: boolean;
22038
24044
  };
24045
+ cancel_open_print_jobs: {
24046
+ Args: {
24047
+ _cutoff: string;
24048
+ };
24049
+ Returns: {
24050
+ extern_job_id: string;
24051
+ id: string;
24052
+ }[];
24053
+ };
22039
24054
  check_offer_product_available_stock: {
22040
24055
  Args: {
22041
24056
  p_campaign_product_id: string;
@@ -22475,8 +24490,6 @@ export type Database = {
22475
24490
  cart_index: number;
22476
24491
  cart_number: string;
22477
24492
  cart_number_id: string;
22478
- cart_seq: number;
22479
- cart_total: number;
22480
24493
  order_id: string;
22481
24494
  order_number: string;
22482
24495
  order_source: string;
@@ -22701,6 +24714,17 @@ export type Database = {
22701
24714
  };
22702
24715
  Returns: boolean;
22703
24716
  };
24717
+ floriday_adopt_connection: {
24718
+ Args: {
24719
+ p_new: string;
24720
+ p_old: string;
24721
+ };
24722
+ Returns: Json;
24723
+ };
24724
+ floriday_autoheal_connections: {
24725
+ Args: never;
24726
+ Returns: Json;
24727
+ };
22704
24728
  floriday_capture_stock_snapshot: {
22705
24729
  Args: never;
22706
24730
  Returns: number;
@@ -22758,6 +24782,12 @@ export type Database = {
22758
24782
  };
22759
24783
  Returns: undefined;
22760
24784
  };
24785
+ floriday_relink_products: {
24786
+ Args: {
24787
+ p_connection_id?: string;
24788
+ };
24789
+ Returns: Json;
24790
+ };
22761
24791
  floriday_requeue_dead_letters: {
22762
24792
  Args: {
22763
24793
  p_connection_id?: string;
@@ -22980,6 +25010,27 @@ export type Database = {
22980
25010
  Args: never;
22981
25011
  Returns: string;
22982
25012
  };
25013
+ handover_afspraak_intrekken: {
25014
+ Args: {
25015
+ _sleutel: string;
25016
+ };
25017
+ Returns: boolean;
25018
+ };
25019
+ handover_afspraak_zetten: {
25020
+ Args: {
25021
+ _besluit: string;
25022
+ _item: string;
25023
+ _modules: string[];
25024
+ _sleutel: string;
25025
+ _soort: string;
25026
+ _versie_vingerafdruk: string;
25027
+ };
25028
+ Returns: boolean;
25029
+ };
25030
+ handover_afspraken: {
25031
+ Args: never;
25032
+ Returns: Json;
25033
+ };
22983
25034
  handover_archief_lijst: {
22984
25035
  Args: never;
22985
25036
  Returns: Json;
@@ -22997,6 +25048,12 @@ export type Database = {
22997
25048
  };
22998
25049
  Returns: boolean;
22999
25050
  };
25051
+ handover_check_afronden_na_scan: {
25052
+ Args: {
25053
+ _module_ids: string[];
25054
+ };
25055
+ Returns: number;
25056
+ };
23000
25057
  handover_check_markeren: {
23001
25058
  Args: {
23002
25059
  _module_ids: string[];
@@ -23040,6 +25097,14 @@ export type Database = {
23040
25097
  };
23041
25098
  Returns: boolean;
23042
25099
  };
25100
+ handover_md_bron_zetten: {
25101
+ Args: {
25102
+ _md: boolean;
25103
+ _module_id: string;
25104
+ _pad?: string;
25105
+ };
25106
+ Returns: boolean;
25107
+ };
23043
25108
  handover_module_meta_zetten: {
23044
25109
  Args: {
23045
25110
  _module_id: string;
@@ -23048,6 +25113,24 @@ export type Database = {
23048
25113
  };
23049
25114
  Returns: boolean;
23050
25115
  };
25116
+ handover_naam_zetten: {
25117
+ Args: {
25118
+ _bron_repo?: string;
25119
+ _module_id: string;
25120
+ _weergavenaam?: string;
25121
+ };
25122
+ Returns: boolean;
25123
+ };
25124
+ handover_namen: {
25125
+ Args: never;
25126
+ Returns: Json;
25127
+ };
25128
+ handover_nieuw_gezien: {
25129
+ Args: {
25130
+ _module_id: string;
25131
+ };
25132
+ Returns: boolean;
25133
+ };
23051
25134
  handover_norm_naam: {
23052
25135
  Args: {
23053
25136
  _naam: string;
@@ -23084,6 +25167,24 @@ export type Database = {
23084
25167
  _versie_label?: string;
23085
25168
  };
23086
25169
  Returns: Json;
25170
+ } | {
25171
+ Args: {
25172
+ _bekende_risicos?: string[];
25173
+ _bezit_tabellen?: string[];
25174
+ _bron_soort?: string;
25175
+ _commit?: string;
25176
+ _contractfuncties?: string[];
25177
+ _inhoud_md: string;
25178
+ _laatst_bevestigd_op?: string;
25179
+ _module_id: string;
25180
+ _module_titel: string;
25181
+ _ontbrekende_contracten?: string[];
25182
+ _pad?: string;
25183
+ _repo?: string;
25184
+ _samenvatting?: string;
25185
+ _versie_label?: string;
25186
+ };
25187
+ Returns: Json;
23087
25188
  };
23088
25189
  handover_publish_via_token: {
23089
25190
  Args: {
@@ -23181,6 +25282,27 @@ export type Database = {
23181
25282
  Args: never;
23182
25283
  Returns: boolean;
23183
25284
  };
25285
+ inkoop_apply_price_list: {
25286
+ Args: {
25287
+ _price_list_id: string;
25288
+ _rows: Json;
25289
+ };
25290
+ Returns: Json;
25291
+ };
25292
+ inkoop_next_order_number: {
25293
+ Args: never;
25294
+ Returns: string;
25295
+ };
25296
+ inkoop_send_order: {
25297
+ Args: {
25298
+ _order_id: string;
25299
+ };
25300
+ Returns: {
25301
+ outbox_id: string;
25302
+ supplier_name: string;
25303
+ to_address: string;
25304
+ }[];
25305
+ };
23184
25306
  instructie_get: {
23185
25307
  Args: {
23186
25308
  _sleutel: string;
@@ -23240,6 +25362,13 @@ export type Database = {
23240
25362
  };
23241
25363
  Returns: Json;
23242
25364
  };
25365
+ invoice_source_lines: {
25366
+ Args: {
25367
+ _source_id: string;
25368
+ _source_type: string;
25369
+ };
25370
+ Returns: Json;
25371
+ };
23243
25372
  is_authenticated: {
23244
25373
  Args: never;
23245
25374
  Returns: boolean;
@@ -23379,6 +25508,10 @@ export type Database = {
23379
25508
  };
23380
25509
  Returns: string;
23381
25510
  };
25511
+ logistics_active_layout_method: {
25512
+ Args: never;
25513
+ Returns: string;
25514
+ };
23382
25515
  logistics_active_pick_workdays: {
23383
25516
  Args: never;
23384
25517
  Returns: string[];
@@ -23430,21 +25563,78 @@ export type Database = {
23430
25563
  };
23431
25564
  Returns: Json;
23432
25565
  };
23433
- logistics_buffer_criteria: {
23434
- Args: {
23435
- p_settings: Json;
23436
- };
23437
- Returns: string[];
23438
- };
23439
- logistics_buffer_decision: {
25566
+ logistics_block_reason_code: {
23440
25567
  Args: {
23441
- p_order?: Json;
23442
- p_strategy_id?: string;
23443
- p_user_id?: string;
25568
+ p_details?: Json;
25569
+ p_reason: string;
23444
25570
  };
23445
- Returns: Json;
25571
+ Returns: string;
23446
25572
  };
23447
- logistics_buffer_simulate: {
25573
+ logistics_blocked_orders: {
25574
+ Args: never;
25575
+ Returns: {
25576
+ attempts: number;
25577
+ blocked_since: string;
25578
+ delivery_date: string;
25579
+ order_id: string;
25580
+ order_ref: string;
25581
+ queue_id: string;
25582
+ reason: string;
25583
+ reason_code: string;
25584
+ }[];
25585
+ };
25586
+ logistics_blocked_overview: {
25587
+ Args: never;
25588
+ Returns: Json;
25589
+ };
25590
+ logistics_buffer_criteria: {
25591
+ Args: {
25592
+ p_settings: Json;
25593
+ };
25594
+ Returns: string[];
25595
+ };
25596
+ logistics_buffer_decision: {
25597
+ Args: {
25598
+ p_order?: Json;
25599
+ p_strategy_id?: string;
25600
+ p_user_id?: string;
25601
+ };
25602
+ Returns: Json;
25603
+ };
25604
+ logistics_buffer_detach_late_orders: {
25605
+ Args: {
25606
+ p_buffer?: string;
25607
+ };
25608
+ Returns: Json;
25609
+ };
25610
+ logistics_buffer_frozen_order: {
25611
+ Args: {
25612
+ p_order_id: string;
25613
+ };
25614
+ Returns: boolean;
25615
+ };
25616
+ logistics_buffer_handled: {
25617
+ Args: {
25618
+ p_buffer: string;
25619
+ };
25620
+ Returns: boolean;
25621
+ };
25622
+ logistics_buffer_notify: {
25623
+ Args: {
25624
+ p_event_type: string;
25625
+ p_idempotency_key: string;
25626
+ p_order_ref: string;
25627
+ p_payload: Json;
25628
+ };
25629
+ Returns: string;
25630
+ };
25631
+ logistics_buffer_open_key: {
25632
+ Args: {
25633
+ p_base_key: string;
25634
+ };
25635
+ Returns: string;
25636
+ };
25637
+ logistics_buffer_simulate: {
23448
25638
  Args: {
23449
25639
  p_orders?: Json;
23450
25640
  p_strategy_id?: string;
@@ -23496,6 +25686,12 @@ export type Database = {
23496
25686
  };
23497
25687
  Returns: string;
23498
25688
  };
25689
+ logistics_cart_checkin_at: {
25690
+ Args: {
25691
+ p_cart_id: string;
25692
+ };
25693
+ Returns: string;
25694
+ };
23499
25695
  logistics_cart_handled: {
23500
25696
  Args: {
23501
25697
  p_cart_index: number;
@@ -23529,10 +25725,22 @@ export type Database = {
23529
25725
  task_status: string;
23530
25726
  }[];
23531
25727
  };
25728
+ logistics_cart_is_full: {
25729
+ Args: {
25730
+ p_cart_id: string;
25731
+ };
25732
+ Returns: boolean;
25733
+ };
23532
25734
  logistics_cart_layout_method: {
23533
25735
  Args: never;
23534
25736
  Returns: Json;
23535
25737
  };
25738
+ logistics_cart_order_refs: {
25739
+ Args: {
25740
+ p_cart_id: string;
25741
+ };
25742
+ Returns: string[];
25743
+ };
23536
25744
  logistics_cart_plan_overview: {
23537
25745
  Args: {
23538
25746
  p_days?: number;
@@ -23552,6 +25760,24 @@ export type Database = {
23552
25760
  };
23553
25761
  Returns: Json;
23554
25762
  };
25763
+ logistics_cart_plan_status_core: {
25764
+ Args: {
25765
+ p_ref: string;
25766
+ };
25767
+ Returns: Json;
25768
+ };
25769
+ logistics_cart_release_reason: {
25770
+ Args: {
25771
+ p_cart_id: string;
25772
+ };
25773
+ Returns: string;
25774
+ };
25775
+ logistics_cart_released: {
25776
+ Args: {
25777
+ p_cart_id: string;
25778
+ };
25779
+ Returns: boolean;
25780
+ };
23555
25781
  logistics_cart_seq: {
23556
25782
  Args: {
23557
25783
  p_order_uuid?: string;
@@ -23602,6 +25828,10 @@ export type Database = {
23602
25828
  unit_ref: string;
23603
25829
  }[];
23604
25830
  };
25831
+ logistics_carts_per_print: {
25832
+ Args: never;
25833
+ Returns: number;
25834
+ };
23605
25835
  logistics_check_order_allowed: {
23606
25836
  Args: {
23607
25837
  p_lines: Json;
@@ -23705,6 +25935,16 @@ export type Database = {
23705
25935
  isSetofReturn: false;
23706
25936
  };
23707
25937
  };
25938
+ logistics_cleanup_orphan_print_jobs: {
25939
+ Args: never;
25940
+ Returns: Json;
25941
+ };
25942
+ logistics_cleanup_tasks: {
25943
+ Args: {
25944
+ p_limit?: number;
25945
+ };
25946
+ Returns: Json;
25947
+ };
23708
25948
  logistics_complete_task: {
23709
25949
  Args: {
23710
25950
  p_result?: Json;
@@ -23767,6 +26007,12 @@ export type Database = {
23767
26007
  station_carts: number;
23768
26008
  }[];
23769
26009
  };
26010
+ logistics_control_complete_cart: {
26011
+ Args: {
26012
+ p_cart_id: string;
26013
+ };
26014
+ Returns: number;
26015
+ };
23770
26016
  logistics_control_scan_approve: {
23771
26017
  Args: {
23772
26018
  p_allow_reprint?: boolean;
@@ -23846,6 +26092,15 @@ export type Database = {
23846
26092
  Args: never;
23847
26093
  Returns: Json;
23848
26094
  };
26095
+ logistics_day_windows: {
26096
+ Args: {
26097
+ p_day: string;
26098
+ };
26099
+ Returns: {
26100
+ win_end: string;
26101
+ win_start: string;
26102
+ }[];
26103
+ };
23849
26104
  logistics_delay_customer_email: {
23850
26105
  Args: {
23851
26106
  p_customer: string;
@@ -23913,6 +26168,17 @@ export type Database = {
23913
26168
  };
23914
26169
  Returns: Json;
23915
26170
  };
26171
+ logistics_enqueue_shipping_note_with_slip: {
26172
+ Args: {
26173
+ _cart_id: string;
26174
+ _is_herprint: boolean;
26175
+ _printer_id: string;
26176
+ _queue_item_id: string;
26177
+ _session_id: string;
26178
+ _slip_job_id: string;
26179
+ };
26180
+ Returns: string;
26181
+ };
23916
26182
  logistics_enqueue_sticker_with_slip: {
23917
26183
  Args: {
23918
26184
  _cart_id: string;
@@ -23930,6 +26196,20 @@ export type Database = {
23930
26196
  };
23931
26197
  Returns: string;
23932
26198
  };
26199
+ logistics_ensure_pick_data: {
26200
+ Args: {
26201
+ p_event_id?: string;
26202
+ p_missing?: Json;
26203
+ p_ref: string;
26204
+ };
26205
+ Returns: Json;
26206
+ };
26207
+ logistics_ensure_shipping_notes: {
26208
+ Args: {
26209
+ p_limit?: number;
26210
+ };
26211
+ Returns: Json;
26212
+ };
23933
26213
  logistics_fail_task: {
23934
26214
  Args: {
23935
26215
  p_error: string;
@@ -23975,6 +26255,10 @@ export type Database = {
23975
26255
  isSetofReturn: false;
23976
26256
  };
23977
26257
  };
26258
+ logistics_fix_wrong_shipping_notes: {
26259
+ Args: never;
26260
+ Returns: Json;
26261
+ };
23978
26262
  logistics_floriday_cart_plan: {
23979
26263
  Args: {
23980
26264
  p_order_id: string;
@@ -24002,6 +26286,10 @@ export type Database = {
24002
26286
  revision: number;
24003
26287
  }[];
24004
26288
  };
26289
+ logistics_floriday_delivery_note_create_enabled: {
26290
+ Args: never;
26291
+ Returns: boolean;
26292
+ };
24005
26293
  logistics_floriday_finish_push: {
24006
26294
  Args: {
24007
26295
  _error?: string;
@@ -24051,6 +26339,38 @@ export type Database = {
24051
26339
  };
24052
26340
  Returns: string;
24053
26341
  };
26342
+ logistics_floriday_gate_status: {
26343
+ Args: never;
26344
+ Returns: Json;
26345
+ };
26346
+ logistics_floriday_log_refusal: {
26347
+ Args: {
26348
+ _action?: string;
26349
+ _module?: string;
26350
+ _order_ref: string;
26351
+ _reason: string;
26352
+ _shell?: string;
26353
+ };
26354
+ Returns: undefined;
26355
+ };
26356
+ logistics_floriday_log_send: {
26357
+ Args: {
26358
+ _action: string;
26359
+ _detail?: string;
26360
+ _http_status?: number;
26361
+ _module?: string;
26362
+ _ok: boolean;
26363
+ _order_ref: string;
26364
+ _shell?: string;
26365
+ };
26366
+ Returns: undefined;
26367
+ };
26368
+ logistics_floriday_order_approved: {
26369
+ Args: {
26370
+ _order_ref: string;
26371
+ };
26372
+ Returns: boolean;
26373
+ };
24054
26374
  logistics_floriday_prune_pushes: {
24055
26375
  Args: {
24056
26376
  _days?: number;
@@ -24065,6 +26385,20 @@ export type Database = {
24065
26385
  };
24066
26386
  Returns: string;
24067
26387
  };
26388
+ logistics_floriday_status_updates_enabled: {
26389
+ Args: never;
26390
+ Returns: boolean;
26391
+ };
26392
+ logistics_floriday_stock_updates_enabled: {
26393
+ Args: never;
26394
+ Returns: boolean;
26395
+ };
26396
+ logistics_floriday_write_allowed: {
26397
+ Args: {
26398
+ _action: string;
26399
+ };
26400
+ Returns: boolean;
26401
+ };
24068
26402
  logistics_fulfill_barcode_requests: {
24069
26403
  Args: {
24070
26404
  p_limit?: number;
@@ -24085,6 +26419,16 @@ export type Database = {
24085
26419
  };
24086
26420
  Returns: boolean;
24087
26421
  };
26422
+ logistics_layout_method_status: {
26423
+ Args: never;
26424
+ Returns: Json;
26425
+ };
26426
+ logistics_link_order_items: {
26427
+ Args: {
26428
+ p_order?: string;
26429
+ };
26430
+ Returns: Json;
26431
+ };
24088
26432
  logistics_live_carriers: {
24089
26433
  Args: {
24090
26434
  p_order_ref: string;
@@ -24097,6 +26441,22 @@ export type Database = {
24097
26441
  };
24098
26442
  Returns: number;
24099
26443
  };
26444
+ logistics_merge_floriday_lines: {
26445
+ Args: {
26446
+ p_order_id: string;
26447
+ };
26448
+ Returns: string;
26449
+ };
26450
+ logistics_merge_lines_enabled: {
26451
+ Args: never;
26452
+ Returns: boolean;
26453
+ };
26454
+ logistics_merge_partial_carts: {
26455
+ Args: {
26456
+ p_limit?: number;
26457
+ };
26458
+ Returns: Json;
26459
+ };
24100
26460
  logistics_next_workday_date: {
24101
26461
  Args: {
24102
26462
  p_date: string;
@@ -24111,18 +26471,62 @@ export type Database = {
24111
26471
  };
24112
26472
  Returns: string;
24113
26473
  };
26474
+ logistics_normalize_product_label: {
26475
+ Args: {
26476
+ p_label: string;
26477
+ };
26478
+ Returns: string;
26479
+ };
24114
26480
  logistics_not_past: {
24115
26481
  Args: {
24116
26482
  p_ts: string;
24117
26483
  };
24118
26484
  Returns: string;
24119
26485
  };
26486
+ logistics_opening_timezone: {
26487
+ Args: never;
26488
+ Returns: string;
26489
+ };
26490
+ logistics_order_cart_approval: {
26491
+ Args: {
26492
+ _order_ref: string;
26493
+ };
26494
+ Returns: {
26495
+ approved: number;
26496
+ total: number;
26497
+ }[];
26498
+ };
24120
26499
  logistics_order_cart_count: {
24121
26500
  Args: {
24122
26501
  p_order_ref: string;
24123
26502
  };
24124
26503
  Returns: number;
24125
26504
  };
26505
+ logistics_order_changed: {
26506
+ Args: {
26507
+ p_order_id: string;
26508
+ p_reason?: string;
26509
+ };
26510
+ Returns: undefined;
26511
+ };
26512
+ logistics_order_documents_ready: {
26513
+ Args: {
26514
+ p_order_ref: string;
26515
+ };
26516
+ Returns: Json;
26517
+ };
26518
+ logistics_order_documents_ready_bool: {
26519
+ Args: {
26520
+ p_order_ref: string;
26521
+ };
26522
+ Returns: boolean;
26523
+ };
26524
+ logistics_order_frozen: {
26525
+ Args: {
26526
+ p_order_id: string;
26527
+ };
26528
+ Returns: boolean;
26529
+ };
24126
26530
  logistics_order_handled: {
24127
26531
  Args: {
24128
26532
  p_order_uuid: string;
@@ -24136,6 +26540,18 @@ export type Database = {
24136
26540
  };
24137
26541
  Returns: boolean;
24138
26542
  };
26543
+ logistics_order_merge_key: {
26544
+ Args: {
26545
+ p_group_key: string;
26546
+ };
26547
+ Returns: string;
26548
+ };
26549
+ logistics_order_mergeable: {
26550
+ Args: {
26551
+ p_order_id: string;
26552
+ };
26553
+ Returns: boolean;
26554
+ };
24139
26555
  logistics_order_overview: {
24140
26556
  Args: {
24141
26557
  p_from?: string;
@@ -24173,6 +26589,12 @@ export type Database = {
24173
26589
  };
24174
26590
  Returns: string;
24175
26591
  };
26592
+ logistics_payload_is_floriday: {
26593
+ Args: {
26594
+ _payload: Json;
26595
+ };
26596
+ Returns: boolean;
26597
+ };
24176
26598
  logistics_pick_agenda: {
24177
26599
  Args: {
24178
26600
  p_from?: string;
@@ -24201,6 +26623,10 @@ export type Database = {
24201
26623
  Args: never;
24202
26624
  Returns: Json;
24203
26625
  };
26626
+ logistics_pick_partial_mode: {
26627
+ Args: never;
26628
+ Returns: string;
26629
+ };
24204
26630
  logistics_pick_start_estimate: {
24205
26631
  Args: {
24206
26632
  p_order: Json;
@@ -24250,6 +26676,12 @@ export type Database = {
24250
26676
  order_id: string;
24251
26677
  }[];
24252
26678
  };
26679
+ logistics_plan_defer: {
26680
+ Args: {
26681
+ p_id: string;
26682
+ };
26683
+ Returns: undefined;
26684
+ };
24253
26685
  logistics_plan_enqueue: {
24254
26686
  Args: {
24255
26687
  p_order_id: string;
@@ -24263,6 +26695,18 @@ export type Database = {
24263
26695
  };
24264
26696
  Returns: boolean;
24265
26697
  };
26698
+ logistics_plan_error_class: {
26699
+ Args: {
26700
+ p_error: string;
26701
+ };
26702
+ Returns: string;
26703
+ };
26704
+ logistics_plan_error_text: {
26705
+ Args: {
26706
+ p_error: string;
26707
+ };
26708
+ Returns: string;
26709
+ };
24266
26710
  logistics_plan_finish: {
24267
26711
  Args: {
24268
26712
  p_error?: string;
@@ -24291,20 +26735,108 @@ export type Database = {
24291
26735
  Args: never;
24292
26736
  Returns: undefined;
24293
26737
  };
24294
- logistics_plan_prune: {
24295
- Args: never;
24296
- Returns: number;
24297
- };
24298
- logistics_plan_release_stale: {
24299
- Args: never;
24300
- Returns: number;
24301
- };
24302
- logistics_plan_setting: {
26738
+ logistics_plan_lock_acquire: {
24303
26739
  Args: {
24304
- p_default: number;
24305
- p_key: string;
26740
+ _key: string;
26741
+ _owner?: string;
26742
+ _ttl_seconds?: number;
24306
26743
  };
24307
- Returns: number;
26744
+ Returns: boolean;
26745
+ };
26746
+ logistics_plan_lock_release: {
26747
+ Args: {
26748
+ _key: string;
26749
+ _owner?: string;
26750
+ };
26751
+ Returns: undefined;
26752
+ };
26753
+ logistics_plan_progress: {
26754
+ Args: {
26755
+ p_refs: string[];
26756
+ };
26757
+ Returns: {
26758
+ cart_plan_ready: boolean;
26759
+ cart_plan_reason: string;
26760
+ cart_plan_released: boolean;
26761
+ plan_progress: number;
26762
+ plan_state: string;
26763
+ plan_state_since: string;
26764
+ unit_ref: string;
26765
+ }[];
26766
+ };
26767
+ logistics_plan_progress_pct: {
26768
+ Args: {
26769
+ p_order_id: string;
26770
+ };
26771
+ Returns: number;
26772
+ };
26773
+ logistics_plan_prune: {
26774
+ Args: never;
26775
+ Returns: number;
26776
+ };
26777
+ logistics_plan_queue_list: {
26778
+ Args: {
26779
+ p_limit?: number;
26780
+ };
26781
+ Returns: {
26782
+ attempts: number;
26783
+ claimed_at: string;
26784
+ customer_name: string;
26785
+ enqueued_at: string;
26786
+ error_class: string;
26787
+ error_raw: string;
26788
+ error_text: string;
26789
+ id: string;
26790
+ max_attempts: number;
26791
+ next_attempt_at: string;
26792
+ order_created_at: string;
26793
+ order_id: string;
26794
+ order_number: string;
26795
+ progress_pct: number;
26796
+ reason: string;
26797
+ stand: string;
26798
+ status: string;
26799
+ updated_at: string;
26800
+ }[];
26801
+ };
26802
+ logistics_plan_release_stale: {
26803
+ Args: never;
26804
+ Returns: number;
26805
+ };
26806
+ logistics_plan_reset_queue: {
26807
+ Args: {
26808
+ p_scope?: string;
26809
+ };
26810
+ Returns: number;
26811
+ };
26812
+ logistics_plan_retry: {
26813
+ Args: {
26814
+ p_order_ids: string[];
26815
+ };
26816
+ Returns: number;
26817
+ };
26818
+ logistics_plan_setting: {
26819
+ Args: {
26820
+ p_default: number;
26821
+ p_key: string;
26822
+ };
26823
+ Returns: number;
26824
+ };
26825
+ logistics_plan_state_for: {
26826
+ Args: {
26827
+ p_ref: string;
26828
+ };
26829
+ Returns: Json;
26830
+ };
26831
+ logistics_plan_timeout_running: {
26832
+ Args: never;
26833
+ Returns: number;
26834
+ };
26835
+ logistics_prepare_pick_documents: {
26836
+ Args: {
26837
+ p_limit?: number;
26838
+ };
26839
+ Returns: Json;
24308
26840
  };
24309
26841
  logistics_prune_buffer_member_queue: {
24310
26842
  Args: never;
@@ -24346,12 +26878,42 @@ export type Database = {
24346
26878
  Args: never;
24347
26879
  Returns: Json;
24348
26880
  };
26881
+ logistics_refresh_pick_queue_status: {
26882
+ Args: {
26883
+ p_ref: string;
26884
+ };
26885
+ Returns: number;
26886
+ };
24349
26887
  logistics_refresh_pickup_moments: {
24350
26888
  Args: {
24351
26889
  p_weeks?: number;
24352
26890
  };
24353
26891
  Returns: Json;
24354
26892
  };
26893
+ logistics_refresh_plan_state: {
26894
+ Args: {
26895
+ p_limit?: number;
26896
+ };
26897
+ Returns: Json;
26898
+ };
26899
+ logistics_replan_all: {
26900
+ Args: {
26901
+ p_reason?: string;
26902
+ };
26903
+ Returns: Json;
26904
+ };
26905
+ logistics_replan_all_force: {
26906
+ Args: {
26907
+ p_reason?: string;
26908
+ };
26909
+ Returns: Json;
26910
+ };
26911
+ logistics_replan_order_journey: {
26912
+ Args: {
26913
+ p_order_ref: string;
26914
+ };
26915
+ Returns: Json;
26916
+ };
24355
26917
  logistics_report_delay: {
24356
26918
  Args: {
24357
26919
  p_expected_date?: string;
@@ -24405,6 +26967,12 @@ export type Database = {
24405
26967
  };
24406
26968
  Returns: Json;
24407
26969
  };
26970
+ logistics_resolve_product_id: {
26971
+ Args: {
26972
+ p_label: string;
26973
+ };
26974
+ Returns: string;
26975
+ };
24408
26976
  logistics_resolve_settings: {
24409
26977
  Args: {
24410
26978
  p_config_id: string;
@@ -24448,91 +27016,361 @@ export type Database = {
24448
27016
  };
24449
27017
  Returns: Json;
24450
27018
  };
24451
- logistics_scan_delays: {
24452
- Args: never;
24453
- Returns: number;
24454
- };
24455
- logistics_scan_order_stock: {
27019
+ logistics_scan_delays: {
27020
+ Args: never;
27021
+ Returns: number;
27022
+ };
27023
+ logistics_scan_order_stock: {
27024
+ Args: {
27025
+ p_order_id: string;
27026
+ };
27027
+ Returns: string;
27028
+ };
27029
+ logistics_scan_resolve: {
27030
+ Args: {
27031
+ p_code: string;
27032
+ };
27033
+ Returns: Json;
27034
+ };
27035
+ logistics_schedule_tasks: {
27036
+ Args: never;
27037
+ Returns: number;
27038
+ } | {
27039
+ Args: {
27040
+ p_order_ref?: string;
27041
+ };
27042
+ Returns: number;
27043
+ };
27044
+ logistics_set_order_priority: {
27045
+ Args: {
27046
+ p_order_ref: string;
27047
+ p_priority: number;
27048
+ p_user_id?: string;
27049
+ };
27050
+ Returns: number;
27051
+ };
27052
+ logistics_set_pick_day: {
27053
+ Args: {
27054
+ p_order_ref: string;
27055
+ p_pick_day: string;
27056
+ };
27057
+ Returns: Json;
27058
+ };
27059
+ logistics_shift_to_workday: {
27060
+ Args: {
27061
+ p_days: string[];
27062
+ p_ts: string;
27063
+ };
27064
+ Returns: string;
27065
+ };
27066
+ logistics_shipping_note_diagnose: {
27067
+ Args: {
27068
+ p_order_number: string;
27069
+ };
27070
+ Returns: Json;
27071
+ };
27072
+ logistics_shipping_note_follows_slip: {
27073
+ Args: never;
27074
+ Returns: boolean;
27075
+ };
27076
+ logistics_shipping_note_from_barcode: {
27077
+ Args: {
27078
+ p_allow_reprint?: boolean;
27079
+ p_barcode: string;
27080
+ p_station_id?: string;
27081
+ };
27082
+ Returns: Json;
27083
+ };
27084
+ logistics_shipping_note_job_for_slip: {
27085
+ Args: {
27086
+ _slip_job_id: string;
27087
+ };
27088
+ Returns: string;
27089
+ };
27090
+ logistics_shipping_notes_wake_all: {
27091
+ Args: never;
27092
+ Returns: Json;
27093
+ };
27094
+ logistics_slip_is_floriday: {
27095
+ Args: {
27096
+ _slip_job_id: string;
27097
+ };
27098
+ Returns: boolean;
27099
+ };
27100
+ logistics_slip_note_claim: {
27101
+ Args: {
27102
+ _lease_seconds?: number;
27103
+ _limit?: number;
27104
+ };
27105
+ Returns: {
27106
+ attempts: number;
27107
+ batch_key: string | null;
27108
+ cart_id: string | null;
27109
+ created_at: string;
27110
+ error: string | null;
27111
+ error_code: string | null;
27112
+ fulfillment_order_id: string | null;
27113
+ id: string;
27114
+ locked_until: string | null;
27115
+ next_attempt_at: string | null;
27116
+ order_id: string | null;
27117
+ order_number: string | null;
27118
+ print_job_id: string | null;
27119
+ printer_id: string | null;
27120
+ retry_class: string | null;
27121
+ slip_job_id: string;
27122
+ status: string;
27123
+ updated_at: string;
27124
+ }[];
27125
+ SetofOptions: {
27126
+ from: "*";
27127
+ to: "logistics_slip_shipping_note";
27128
+ isOneToOne: false;
27129
+ isSetofReturn: true;
27130
+ };
27131
+ };
27132
+ logistics_slip_note_finish: {
27133
+ Args: {
27134
+ _error?: string;
27135
+ _error_code?: string;
27136
+ _fulfillment_order_id?: string;
27137
+ _id: string;
27138
+ _ok: boolean;
27139
+ _print_job_id?: string;
27140
+ _status?: string;
27141
+ };
27142
+ Returns: undefined;
27143
+ };
27144
+ logistics_slip_note_keep_waiting: {
27145
+ Args: {
27146
+ _class?: string;
27147
+ _id: string;
27148
+ _reason: string;
27149
+ };
27150
+ Returns: undefined;
27151
+ };
27152
+ logistics_sticker_follows_slip: {
27153
+ Args: never;
27154
+ Returns: boolean;
27155
+ };
27156
+ logistics_subtract_working_minutes: {
27157
+ Args: {
27158
+ p_deadline: string;
27159
+ p_max_workdays?: number;
27160
+ p_minutes: number;
27161
+ };
27162
+ Returns: Json;
27163
+ };
27164
+ logistics_supersede_stale_tasks: {
27165
+ Args: {
27166
+ p_keep: string[];
27167
+ p_order_ref: string;
27168
+ p_run_id: string;
27169
+ p_user_id: string;
27170
+ };
27171
+ Returns: number;
27172
+ };
27173
+ logistics_sync_pick_queue: {
27174
+ Args: never;
27175
+ Returns: Json;
27176
+ };
27177
+ logistics_sync_task_carriers: {
27178
+ Args: {
27179
+ p_order_ref?: string;
27180
+ };
27181
+ Returns: number;
27182
+ };
27183
+ logistics_task_owner: {
27184
+ Args: {
27185
+ p_task_type: string;
27186
+ };
27187
+ Returns: string;
27188
+ };
27189
+ logistics_task_pick_minutes: {
27190
+ Args: {
27191
+ p_payload: Json;
27192
+ p_settings: Json;
27193
+ };
27194
+ Returns: number;
27195
+ };
27196
+ logistics_task_retention_days: {
27197
+ Args: never;
27198
+ Returns: number;
27199
+ };
27200
+ logistics_tick_ping: {
27201
+ Args: never;
27202
+ Returns: string;
27203
+ };
27204
+ logistics_timezone_options: {
27205
+ Args: never;
27206
+ Returns: {
27207
+ name: string;
27208
+ }[];
27209
+ };
27210
+ logistics_trace: {
27211
+ Args: {
27212
+ p: Json;
27213
+ };
27214
+ Returns: string;
27215
+ };
27216
+ logistics_trace_all_orders: {
27217
+ Args: {
27218
+ p_limit?: number;
27219
+ p_search?: string;
27220
+ };
27221
+ Returns: Json;
27222
+ };
27223
+ logistics_trace_archive_order: {
27224
+ Args: {
27225
+ p_order_ref: string;
27226
+ p_reason: string;
27227
+ };
27228
+ Returns: number;
27229
+ };
27230
+ logistics_trace_batch: {
27231
+ Args: {
27232
+ p: Json;
27233
+ };
27234
+ Returns: number;
27235
+ };
27236
+ logistics_trace_derive: {
27237
+ Args: {
27238
+ p: Json;
27239
+ };
27240
+ Returns: number;
27241
+ };
27242
+ logistics_trace_node: {
27243
+ Args: {
27244
+ p_op?: string;
27245
+ p_status?: string;
27246
+ p_table: string;
27247
+ };
27248
+ Returns: string;
27249
+ };
27250
+ logistics_trace_order_journey_start: {
27251
+ Args: {
27252
+ p_order_id: string;
27253
+ p_reason?: string;
27254
+ };
27255
+ Returns: string;
27256
+ };
27257
+ logistics_trace_order_origin: {
27258
+ Args: {
27259
+ p_order_id: string;
27260
+ };
27261
+ Returns: undefined;
27262
+ };
27263
+ logistics_trace_order_overview: {
27264
+ Args: {
27265
+ p_error_class?: string;
27266
+ p_limit?: number;
27267
+ p_search?: string;
27268
+ p_since?: string;
27269
+ p_source?: string;
27270
+ p_state?: string;
27271
+ p_step?: string;
27272
+ };
27273
+ Returns: Json;
27274
+ };
27275
+ logistics_trace_order_state: {
27276
+ Args: {
27277
+ p_order_ref: string;
27278
+ };
27279
+ Returns: Json;
27280
+ };
27281
+ logistics_trace_order_step: {
27282
+ Args: {
27283
+ p_class?: string;
27284
+ p_decision?: string;
27285
+ p_error?: string;
27286
+ p_next_step?: string;
27287
+ p_node: string;
27288
+ p_order_id: string;
27289
+ p_reason?: string;
27290
+ p_status: string;
27291
+ p_step: string;
27292
+ };
27293
+ Returns: undefined;
27294
+ };
27295
+ logistics_trace_orders: {
27296
+ Args: {
27297
+ p_limit?: number;
27298
+ p_search?: string;
27299
+ p_since?: string;
27300
+ p_status?: string;
27301
+ };
27302
+ Returns: Json;
27303
+ };
27304
+ logistics_trace_pick_state: {
24456
27305
  Args: {
24457
- p_order_id: string;
27306
+ p_order_number: string;
24458
27307
  };
24459
- Returns: string;
27308
+ Returns: undefined;
24460
27309
  };
24461
- logistics_scan_resolve: {
27310
+ logistics_trace_progress: {
24462
27311
  Args: {
24463
- p_code: string;
27312
+ p_limit?: number;
24464
27313
  };
24465
27314
  Returns: Json;
24466
27315
  };
24467
- logistics_schedule_tasks: {
24468
- Args: never;
24469
- Returns: number;
24470
- };
24471
- logistics_set_order_priority: {
27316
+ logistics_trace_progress_order: {
24472
27317
  Args: {
24473
27318
  p_order_ref: string;
24474
- p_priority: number;
24475
- p_user_id?: string;
24476
27319
  };
24477
- Returns: number;
27320
+ Returns: Json;
24478
27321
  };
24479
- logistics_set_pick_day: {
27322
+ logistics_trace_redact: {
24480
27323
  Args: {
24481
- p_order_ref: string;
24482
- p_pick_day: string;
27324
+ p: Json;
24483
27325
  };
24484
27326
  Returns: Json;
24485
27327
  };
24486
- logistics_shift_to_workday: {
27328
+ logistics_trace_source_node: {
24487
27329
  Args: {
24488
- p_days: string[];
24489
- p_ts: string;
27330
+ p_source: string;
24490
27331
  };
24491
27332
  Returns: string;
24492
27333
  };
24493
- logistics_shipping_note_from_barcode: {
27334
+ logistics_trace_step_once: {
24494
27335
  Args: {
24495
- p_allow_reprint?: boolean;
24496
- p_barcode: string;
24497
- p_station_id?: string;
27336
+ p_decision: string;
27337
+ p_next_step?: string;
27338
+ p_node: string;
27339
+ p_order_id: string;
27340
+ p_reason: string;
27341
+ p_status: string;
27342
+ p_step: string;
24498
27343
  };
24499
- Returns: Json;
24500
- };
24501
- logistics_sticker_follows_slip: {
24502
- Args: never;
24503
- Returns: boolean;
27344
+ Returns: undefined;
24504
27345
  };
24505
- logistics_supersede_stale_tasks: {
27346
+ logistics_trace_stock_check: {
24506
27347
  Args: {
24507
- p_keep: string[];
24508
- p_order_ref: string;
24509
- p_run_id: string;
24510
- p_user_id: string;
27348
+ p_order_id: string;
24511
27349
  };
24512
- Returns: number;
24513
- };
24514
- logistics_sync_pick_queue: {
24515
- Args: never;
24516
- Returns: Json;
27350
+ Returns: undefined;
24517
27351
  };
24518
- logistics_sync_task_carriers: {
27352
+ logistics_trace_timeline: {
24519
27353
  Args: {
24520
- p_order_ref?: string;
27354
+ p_limit?: number;
27355
+ p_order_ref: string;
24521
27356
  };
24522
- Returns: number;
27357
+ Returns: Json;
24523
27358
  };
24524
- logistics_task_owner: {
27359
+ logistics_trace_version_events: {
24525
27360
  Args: {
24526
- p_task_type: string;
27361
+ p_from?: string;
27362
+ p_limit?: number;
27363
+ p_order_ref: string;
27364
+ p_to?: string;
27365
+ p_version_id: string;
24527
27366
  };
24528
- Returns: string;
27367
+ Returns: Json;
24529
27368
  };
24530
- logistics_task_pick_minutes: {
27369
+ logistics_trace_versions: {
24531
27370
  Args: {
24532
- p_payload: Json;
24533
- p_settings: Json;
27371
+ p_order_ref: string;
24534
27372
  };
24535
- Returns: number;
27373
+ Returns: Json;
24536
27374
  };
24537
27375
  logistics_upsert_task: {
24538
27376
  Args: {
@@ -24553,6 +27391,16 @@ export type Database = {
24553
27391
  };
24554
27392
  Returns: string;
24555
27393
  };
27394
+ logistics_valid_timezone: {
27395
+ Args: {
27396
+ _tz: string;
27397
+ };
27398
+ Returns: boolean;
27399
+ };
27400
+ logistics_working_hours_status: {
27401
+ Args: never;
27402
+ Returns: Json;
27403
+ };
24556
27404
  logistics_write_buffer_layer_positions: {
24557
27405
  Args: {
24558
27406
  p_buffer_id: string;
@@ -24718,6 +27566,10 @@ export type Database = {
24718
27566
  online: boolean;
24719
27567
  }[];
24720
27568
  };
27569
+ pick_apply_buffer_events: {
27570
+ Args: never;
27571
+ Returns: Json;
27572
+ };
24721
27573
  pick_available_pick_days: {
24722
27574
  Args: {
24723
27575
  _max_days?: number;
@@ -25561,6 +28413,18 @@ export type Database = {
25561
28413
  };
25562
28414
  Returns: undefined;
25563
28415
  };
28416
+ prune_floriday_api_log: {
28417
+ Args: never;
28418
+ Returns: number;
28419
+ };
28420
+ quote_ack_work_order: {
28421
+ Args: {
28422
+ _queue_id: string;
28423
+ _werkbon_id: string;
28424
+ _werkbon_nummer?: string;
28425
+ };
28426
+ Returns: boolean;
28427
+ };
25564
28428
  quote_create_from_source: {
25565
28429
  Args: {
25566
28430
  _payload?: Json;
@@ -25569,6 +28433,13 @@ export type Database = {
25569
28433
  };
25570
28434
  Returns: string;
25571
28435
  };
28436
+ quote_fail_work_order: {
28437
+ Args: {
28438
+ _foutmelding: string;
28439
+ _queue_id: string;
28440
+ };
28441
+ Returns: boolean;
28442
+ };
25572
28443
  quote_get_billable_lines: {
25573
28444
  Args: {
25574
28445
  _quotation_id: string;
@@ -25585,6 +28456,12 @@ export type Database = {
25585
28456
  Args: never;
25586
28457
  Returns: Json;
25587
28458
  };
28459
+ quote_list_pending_work_orders: {
28460
+ Args: {
28461
+ _limit?: number;
28462
+ };
28463
+ Returns: Json;
28464
+ };
25588
28465
  quote_list_sources: {
25589
28466
  Args: {
25590
28467
  _limit?: number;
@@ -25592,6 +28469,12 @@ export type Database = {
25592
28469
  };
25593
28470
  Returns: Json;
25594
28471
  };
28472
+ quote_queue_follow_up: {
28473
+ Args: {
28474
+ _offerte_id: string;
28475
+ };
28476
+ Returns: string;
28477
+ };
25595
28478
  recompute_all_reserved_stock: {
25596
28479
  Args: never;
25597
28480
  Returns: undefined;
@@ -25645,6 +28528,12 @@ export type Database = {
25645
28528
  };
25646
28529
  Returns: boolean;
25647
28530
  };
28531
+ release_job_lock: {
28532
+ Args: {
28533
+ _key: string;
28534
+ };
28535
+ Returns: undefined;
28536
+ };
25648
28537
  release_local_pdf_job: {
25649
28538
  Args: {
25650
28539
  _job_id: string;
@@ -25988,6 +28877,13 @@ export type Database = {
25988
28877
  };
25989
28878
  Returns: number;
25990
28879
  };
28880
+ schedule_floriday_catalog_prices_sync: {
28881
+ Args: {
28882
+ p_apikey: string;
28883
+ p_url: string;
28884
+ };
28885
+ Returns: number;
28886
+ };
25991
28887
  schedule_floriday_clock_presales_sync: {
25992
28888
  Args: {
25993
28889
  p_apikey: string;
@@ -26260,6 +29156,52 @@ export type Database = {
26260
29156
  p_end_time: string;
26261
29157
  };
26262
29158
  Returns: Json;
29159
+ } | {
29160
+ Args: {
29161
+ p_end_lat?: number;
29162
+ p_end_lng?: number;
29163
+ p_log_id: string;
29164
+ };
29165
+ Returns: {
29166
+ auto_stop_reason: string | null;
29167
+ auto_stopped: boolean;
29168
+ created_at: string;
29169
+ current_latitude: number | null;
29170
+ current_longitude: number | null;
29171
+ current_position_updated_at: string | null;
29172
+ employee_id: string;
29173
+ end_latitude: number | null;
29174
+ end_longitude: number | null;
29175
+ end_time: string | null;
29176
+ eta_distance_km: number | null;
29177
+ eta_minutes: number | null;
29178
+ eta_updated_at: string | null;
29179
+ hour_category: string | null;
29180
+ id: string;
29181
+ last_reminder_at: string | null;
29182
+ notes: string | null;
29183
+ overtime_hours: number;
29184
+ overtime_type: string | null;
29185
+ regular_hours: number;
29186
+ reminder_count: number;
29187
+ requires_review: boolean;
29188
+ start_latitude: number | null;
29189
+ start_longitude: number | null;
29190
+ start_time: string;
29191
+ travel_cost: number | null;
29192
+ travel_distance_km: number | null;
29193
+ travel_duration_min: number | null;
29194
+ travel_time_minutes: number | null;
29195
+ type: string;
29196
+ updated_at: string;
29197
+ work_order_id: string | null;
29198
+ };
29199
+ SetofOptions: {
29200
+ from: "*";
29201
+ to: "time_logs";
29202
+ isOneToOne: true;
29203
+ isSetofReturn: false;
29204
+ };
26263
29205
  };
26264
29206
  swap_cart_layer_positions: {
26265
29207
  Args: {
@@ -26288,6 +29230,10 @@ export type Database = {
26288
29230
  };
26289
29231
  Returns: undefined;
26290
29232
  };
29233
+ sync_floriday_prices_into_price_groups: {
29234
+ Args: never;
29235
+ Returns: number;
29236
+ };
26291
29237
  sync_layer_stock: {
26292
29238
  Args: {
26293
29239
  p_product_id: string;
@@ -26333,6 +29279,14 @@ export type Database = {
26333
29279
  row_count: number;
26334
29280
  }[];
26335
29281
  };
29282
+ try_acquire_job_lock: {
29283
+ Args: {
29284
+ _key: string;
29285
+ _owner?: string;
29286
+ _seconds?: number;
29287
+ };
29288
+ Returns: boolean;
29289
+ };
26336
29290
  try_debtor_lock: {
26337
29291
  Args: {
26338
29292
  _group_key: string;
@@ -26404,14 +29358,99 @@ export type Database = {
26404
29358
  };
26405
29359
  Returns: undefined;
26406
29360
  };
29361
+ uren_employee_day_hours: {
29362
+ Args: {
29363
+ _day: string;
29364
+ _employee_id: string;
29365
+ };
29366
+ Returns: number;
29367
+ };
26407
29368
  uren_is_beheerder: {
26408
29369
  Args: never;
26409
29370
  Returns: boolean;
26410
29371
  };
29372
+ uren_list_medewerkers: {
29373
+ Args: never;
29374
+ Returns: {
29375
+ avatar_url: string;
29376
+ color: string;
29377
+ display_name: string;
29378
+ email: string;
29379
+ hours_fri: number;
29380
+ hours_mon: number;
29381
+ hours_thu: number;
29382
+ hours_tue: number;
29383
+ hours_wed: number;
29384
+ id: string;
29385
+ is_active: boolean;
29386
+ leave_balance_hours: number;
29387
+ persnr: string;
29388
+ phone: string;
29389
+ roles: string[];
29390
+ }[];
29391
+ };
26411
29392
  uren_my_monteur_id: {
26412
29393
  Args: never;
26413
29394
  Returns: string;
26414
29395
  };
29396
+ uren_planning_dagagenda: {
29397
+ Args: {
29398
+ _tot: string;
29399
+ _van: string;
29400
+ };
29401
+ Returns: {
29402
+ end_at: string;
29403
+ id: string;
29404
+ is_tweede_man: boolean;
29405
+ notes: string;
29406
+ start_at: string;
29407
+ status: Database["public"]["Enums"]["planning_item_status"];
29408
+ werkbon_id: string;
29409
+ }[];
29410
+ };
29411
+ uren_set_planning_item_status: {
29412
+ Args: {
29413
+ _id: string;
29414
+ _status: Database["public"]["Enums"]["planning_item_status"];
29415
+ };
29416
+ Returns: undefined;
29417
+ };
29418
+ uren_set_planning_status: {
29419
+ Args: {
29420
+ p_status: Database["public"]["Enums"]["planning_item_status"];
29421
+ p_werkbon_id: string;
29422
+ };
29423
+ Returns: number;
29424
+ };
29425
+ uren_stop_time_log: {
29426
+ Args: {
29427
+ p_employee_id: string;
29428
+ p_end_lat?: number;
29429
+ p_end_lng?: number;
29430
+ p_end_time: string;
29431
+ };
29432
+ Returns: Json;
29433
+ };
29434
+ uren_switch_time_log: {
29435
+ Args: {
29436
+ p_employee_id: string;
29437
+ p_start_lat?: number;
29438
+ p_start_lng?: number;
29439
+ p_type: string;
29440
+ p_work_order_id?: string;
29441
+ };
29442
+ Returns: Json;
29443
+ };
29444
+ uren_sync_sick_time_off: {
29445
+ Args: {
29446
+ _period_id: string;
29447
+ };
29448
+ Returns: number;
29449
+ };
29450
+ voorraad_cleanup_old_rows: {
29451
+ Args: never;
29452
+ Returns: Json;
29453
+ };
26415
29454
  wake_print_queue: {
26416
29455
  Args: {
26417
29456
  _min_interval_ms?: number;
@@ -26450,6 +29489,25 @@ export type Database = {
26450
29489
  };
26451
29490
  Returns: Json;
26452
29491
  };
29492
+ wo_list_offerte_requests: {
29493
+ Args: {
29494
+ _status?: string;
29495
+ };
29496
+ Returns: Json;
29497
+ };
29498
+ wo_process_offerte_request: {
29499
+ Args: {
29500
+ _queue_id: string;
29501
+ };
29502
+ Returns: Json;
29503
+ };
29504
+ wo_reject_offerte_request: {
29505
+ Args: {
29506
+ _queue_id: string;
29507
+ _reden?: string;
29508
+ };
29509
+ Returns: Json;
29510
+ };
26453
29511
  wo_set_status: {
26454
29512
  Args: {
26455
29513
  _reason?: string;