@flowselections/floriday-voorraad 1.0.14 → 1.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist-lib/components/voorraad/ArtikelWizard.d.ts.map +1 -1
  2. package/dist-lib/components/voorraad/ArtikelWizard.js +48 -7
  3. package/dist-lib/components/voorraad/ExcelExportButton.d.ts +2 -1
  4. package/dist-lib/components/voorraad/ExcelExportButton.d.ts.map +1 -1
  5. package/dist-lib/components/voorraad/ExcelExportButton.js +24 -5
  6. package/dist-lib/components/voorraad/ProductLinkCard.d.ts +13 -0
  7. package/dist-lib/components/voorraad/ProductLinkCard.d.ts.map +1 -0
  8. package/dist-lib/components/voorraad/ProductLinkCard.js +159 -0
  9. package/dist-lib/components/voorraad/StockBulkButtons.d.ts.map +1 -1
  10. package/dist-lib/components/voorraad/StockBulkButtons.js +88 -7
  11. package/dist-lib/hooks/useTradeItemSpec.d.ts.map +1 -1
  12. package/dist-lib/hooks/useTradeItemSpec.js +4 -1
  13. package/dist-lib/hooks/useVoorraadData.d.ts +5 -4
  14. package/dist-lib/hooks/useVoorraadData.d.ts.map +1 -1
  15. package/dist-lib/hooks/useVoorraadData.js +40 -6
  16. package/dist-lib/index.d.ts +1 -0
  17. package/dist-lib/index.d.ts.map +1 -1
  18. package/dist-lib/index.js +1 -0
  19. package/dist-lib/integrations/supabase/auth-middleware.d.ts +743 -0
  20. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  21. package/dist-lib/integrations/supabase/client.d.ts +743 -0
  22. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  23. package/dist-lib/integrations/supabase/client.server.d.ts +743 -0
  24. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  25. package/dist-lib/integrations/supabase/types.d.ts +763 -0
  26. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  27. package/dist-lib/lib/ensure-article-codes.d.ts +8 -0
  28. package/dist-lib/lib/ensure-article-codes.d.ts.map +1 -0
  29. package/dist-lib/lib/ensure-article-codes.js +78 -0
  30. package/dist-lib/lib/floricode-required-features.functions.d.ts +743 -0
  31. package/dist-lib/lib/floricode-required-features.functions.d.ts.map +1 -1
  32. package/dist-lib/lib/floriday-client.d.ts +6 -0
  33. package/dist-lib/lib/floriday-client.d.ts.map +1 -1
  34. package/dist-lib/lib/floriday-gateway.functions.d.ts +2972 -0
  35. package/dist-lib/lib/floriday-gateway.functions.d.ts.map +1 -1
  36. package/dist-lib/lib/floriday-payload.d.ts +19 -5
  37. package/dist-lib/lib/floriday-payload.d.ts.map +1 -1
  38. package/dist-lib/lib/floriday-payload.js +106 -33
  39. package/dist-lib/lib/floriday-warehouse.functions.d.ts +32228 -0
  40. package/dist-lib/lib/floriday-warehouse.functions.d.ts.map +1 -0
  41. package/dist-lib/lib/floriday-warehouse.functions.js +98 -0
  42. package/dist-lib/lib/floriday-writes.functions.d.ts +1616 -130
  43. package/dist-lib/lib/floriday-writes.functions.d.ts.map +1 -1
  44. package/dist-lib/lib/floriday-writes.functions.js +34 -6
  45. package/package.json +7 -1
@@ -3719,6 +3719,51 @@ export type Database = {
3719
3719
  }
3720
3720
  ];
3721
3721
  };
3722
+ floriday_continuous_stock_queue: {
3723
+ Row: {
3724
+ attempts: number;
3725
+ connection_id: string;
3726
+ created_at: string;
3727
+ gateway_attempt_id: string | null;
3728
+ id: string;
3729
+ last_error: string | null;
3730
+ number_of_pieces: number;
3731
+ sent_at: string | null;
3732
+ status: string;
3733
+ trade_item_id: string;
3734
+ updated_at: string;
3735
+ user_id: string;
3736
+ };
3737
+ Insert: {
3738
+ attempts?: number;
3739
+ connection_id: string;
3740
+ created_at?: string;
3741
+ gateway_attempt_id?: string | null;
3742
+ id?: string;
3743
+ last_error?: string | null;
3744
+ number_of_pieces?: number;
3745
+ sent_at?: string | null;
3746
+ status?: string;
3747
+ trade_item_id: string;
3748
+ updated_at?: string;
3749
+ user_id: string;
3750
+ };
3751
+ Update: {
3752
+ attempts?: number;
3753
+ connection_id?: string;
3754
+ created_at?: string;
3755
+ gateway_attempt_id?: string | null;
3756
+ id?: string;
3757
+ last_error?: string | null;
3758
+ number_of_pieces?: number;
3759
+ sent_at?: string | null;
3760
+ status?: string;
3761
+ trade_item_id?: string;
3762
+ updated_at?: string;
3763
+ user_id?: string;
3764
+ };
3765
+ Relationships: [];
3766
+ };
3722
3767
  floriday_contract_trade_item_groups_cache: {
3723
3768
  Row: {
3724
3769
  connection_id: string;
@@ -5162,6 +5207,216 @@ export type Database = {
5162
5207
  };
5163
5208
  Relationships: [];
5164
5209
  };
5210
+ local_customer_agreements: {
5211
+ Row: {
5212
+ base_price: number | null;
5213
+ created_at: string;
5214
+ currency: string;
5215
+ customer_id: string;
5216
+ id: string;
5217
+ min_quantity: number;
5218
+ net_price: number;
5219
+ notes: string | null;
5220
+ product_category_id: string | null;
5221
+ product_id: string | null;
5222
+ updated_at: string;
5223
+ valid_from: string | null;
5224
+ valid_until: string | null;
5225
+ };
5226
+ Insert: {
5227
+ base_price?: number | null;
5228
+ created_at?: string;
5229
+ currency?: string;
5230
+ customer_id: string;
5231
+ id?: string;
5232
+ min_quantity?: number;
5233
+ net_price: number;
5234
+ notes?: string | null;
5235
+ product_category_id?: string | null;
5236
+ product_id?: string | null;
5237
+ updated_at?: string;
5238
+ valid_from?: string | null;
5239
+ valid_until?: string | null;
5240
+ };
5241
+ Update: {
5242
+ base_price?: number | null;
5243
+ created_at?: string;
5244
+ currency?: string;
5245
+ customer_id?: string;
5246
+ id?: string;
5247
+ min_quantity?: number;
5248
+ net_price?: number;
5249
+ notes?: string | null;
5250
+ product_category_id?: string | null;
5251
+ product_id?: string | null;
5252
+ updated_at?: string;
5253
+ valid_from?: string | null;
5254
+ valid_until?: string | null;
5255
+ };
5256
+ Relationships: [
5257
+ {
5258
+ foreignKeyName: "local_customer_agreements_customer_id_fkey";
5259
+ columns: ["customer_id"];
5260
+ isOneToOne: false;
5261
+ referencedRelation: "customers";
5262
+ referencedColumns: ["id"];
5263
+ },
5264
+ {
5265
+ foreignKeyName: "local_customer_agreements_product_category_id_fkey";
5266
+ columns: ["product_category_id"];
5267
+ isOneToOne: false;
5268
+ referencedRelation: "product_categories";
5269
+ referencedColumns: ["id"];
5270
+ },
5271
+ {
5272
+ foreignKeyName: "local_customer_agreements_product_id_fkey";
5273
+ columns: ["product_id"];
5274
+ isOneToOne: false;
5275
+ referencedRelation: "products";
5276
+ referencedColumns: ["id"];
5277
+ }
5278
+ ];
5279
+ };
5280
+ local_customer_price_groups: {
5281
+ Row: {
5282
+ created_at: string;
5283
+ currency: string;
5284
+ customer_id: string;
5285
+ discount_type: string;
5286
+ discount_value: number;
5287
+ id: string;
5288
+ min_quantity: number;
5289
+ notes: string | null;
5290
+ product_category_id: string | null;
5291
+ product_id: string | null;
5292
+ updated_at: string;
5293
+ valid_from: string | null;
5294
+ valid_until: string | null;
5295
+ };
5296
+ Insert: {
5297
+ created_at?: string;
5298
+ currency?: string;
5299
+ customer_id: string;
5300
+ discount_type: string;
5301
+ discount_value: number;
5302
+ id?: string;
5303
+ min_quantity?: number;
5304
+ notes?: string | null;
5305
+ product_category_id?: string | null;
5306
+ product_id?: string | null;
5307
+ updated_at?: string;
5308
+ valid_from?: string | null;
5309
+ valid_until?: string | null;
5310
+ };
5311
+ Update: {
5312
+ created_at?: string;
5313
+ currency?: string;
5314
+ customer_id?: string;
5315
+ discount_type?: string;
5316
+ discount_value?: number;
5317
+ id?: string;
5318
+ min_quantity?: number;
5319
+ notes?: string | null;
5320
+ product_category_id?: string | null;
5321
+ product_id?: string | null;
5322
+ updated_at?: string;
5323
+ valid_from?: string | null;
5324
+ valid_until?: string | null;
5325
+ };
5326
+ Relationships: [
5327
+ {
5328
+ foreignKeyName: "local_customer_price_groups_customer_id_fkey";
5329
+ columns: ["customer_id"];
5330
+ isOneToOne: false;
5331
+ referencedRelation: "customers";
5332
+ referencedColumns: ["id"];
5333
+ },
5334
+ {
5335
+ foreignKeyName: "local_customer_price_groups_product_category_id_fkey";
5336
+ columns: ["product_category_id"];
5337
+ isOneToOne: false;
5338
+ referencedRelation: "product_categories";
5339
+ referencedColumns: ["id"];
5340
+ },
5341
+ {
5342
+ foreignKeyName: "local_customer_price_groups_product_id_fkey";
5343
+ columns: ["product_id"];
5344
+ isOneToOne: false;
5345
+ referencedRelation: "products";
5346
+ referencedColumns: ["id"];
5347
+ }
5348
+ ];
5349
+ };
5350
+ local_customer_sales_strategies: {
5351
+ Row: {
5352
+ created_at: string;
5353
+ currency: string;
5354
+ customer_id: string;
5355
+ discount_type: string;
5356
+ discount_value: number;
5357
+ id: string;
5358
+ min_quantity: number;
5359
+ notes: string | null;
5360
+ product_category_id: string | null;
5361
+ product_id: string | null;
5362
+ updated_at: string;
5363
+ valid_from: string | null;
5364
+ valid_until: string | null;
5365
+ };
5366
+ Insert: {
5367
+ created_at?: string;
5368
+ currency?: string;
5369
+ customer_id: string;
5370
+ discount_type: string;
5371
+ discount_value: number;
5372
+ id?: string;
5373
+ min_quantity?: number;
5374
+ notes?: string | null;
5375
+ product_category_id?: string | null;
5376
+ product_id?: string | null;
5377
+ updated_at?: string;
5378
+ valid_from?: string | null;
5379
+ valid_until?: string | null;
5380
+ };
5381
+ Update: {
5382
+ created_at?: string;
5383
+ currency?: string;
5384
+ customer_id?: string;
5385
+ discount_type?: string;
5386
+ discount_value?: number;
5387
+ id?: string;
5388
+ min_quantity?: number;
5389
+ notes?: string | null;
5390
+ product_category_id?: string | null;
5391
+ product_id?: string | null;
5392
+ updated_at?: string;
5393
+ valid_from?: string | null;
5394
+ valid_until?: string | null;
5395
+ };
5396
+ Relationships: [
5397
+ {
5398
+ foreignKeyName: "local_customer_sales_strategies_customer_id_fkey";
5399
+ columns: ["customer_id"];
5400
+ isOneToOne: false;
5401
+ referencedRelation: "customers";
5402
+ referencedColumns: ["id"];
5403
+ },
5404
+ {
5405
+ foreignKeyName: "local_customer_sales_strategies_product_category_id_fkey";
5406
+ columns: ["product_category_id"];
5407
+ isOneToOne: false;
5408
+ referencedRelation: "product_categories";
5409
+ referencedColumns: ["id"];
5410
+ },
5411
+ {
5412
+ foreignKeyName: "local_customer_sales_strategies_product_id_fkey";
5413
+ columns: ["product_id"];
5414
+ isOneToOne: false;
5415
+ referencedRelation: "products";
5416
+ referencedColumns: ["id"];
5417
+ }
5418
+ ];
5419
+ };
5165
5420
  locations: {
5166
5421
  Row: {
5167
5422
  created_at: string;
@@ -5688,6 +5943,281 @@ export type Database = {
5688
5943
  }
5689
5944
  ];
5690
5945
  };
5946
+ nmbrs_component_mapping: {
5947
+ Row: {
5948
+ created_at: string;
5949
+ id: string;
5950
+ source_kind: string;
5951
+ source_value: string | null;
5952
+ updated_at: string;
5953
+ wage_code: string;
5954
+ };
5955
+ Insert: {
5956
+ created_at?: string;
5957
+ id?: string;
5958
+ source_kind: string;
5959
+ source_value?: string | null;
5960
+ updated_at?: string;
5961
+ wage_code: string;
5962
+ };
5963
+ Update: {
5964
+ created_at?: string;
5965
+ id?: string;
5966
+ source_kind?: string;
5967
+ source_value?: string | null;
5968
+ updated_at?: string;
5969
+ wage_code?: string;
5970
+ };
5971
+ Relationships: [
5972
+ {
5973
+ foreignKeyName: "nmbrs_component_mapping_wage_code_fkey";
5974
+ columns: ["wage_code"];
5975
+ isOneToOne: false;
5976
+ referencedRelation: "nmbrs_wage_components";
5977
+ referencedColumns: ["code"];
5978
+ }
5979
+ ];
5980
+ };
5981
+ nmbrs_employee_mapping: {
5982
+ Row: {
5983
+ active_from: string | null;
5984
+ active_to: string | null;
5985
+ contract_hours_per_week: number | null;
5986
+ created_at: string;
5987
+ hourly_wage: number | null;
5988
+ id: string;
5989
+ monteur_id: string;
5990
+ nmbrs_company_code: string | null;
5991
+ nmbrs_employee_number: string;
5992
+ updated_at: string;
5993
+ };
5994
+ Insert: {
5995
+ active_from?: string | null;
5996
+ active_to?: string | null;
5997
+ contract_hours_per_week?: number | null;
5998
+ created_at?: string;
5999
+ hourly_wage?: number | null;
6000
+ id?: string;
6001
+ monteur_id: string;
6002
+ nmbrs_company_code?: string | null;
6003
+ nmbrs_employee_number: string;
6004
+ updated_at?: string;
6005
+ };
6006
+ Update: {
6007
+ active_from?: string | null;
6008
+ active_to?: string | null;
6009
+ contract_hours_per_week?: number | null;
6010
+ created_at?: string;
6011
+ hourly_wage?: number | null;
6012
+ id?: string;
6013
+ monteur_id?: string;
6014
+ nmbrs_company_code?: string | null;
6015
+ nmbrs_employee_number?: string;
6016
+ updated_at?: string;
6017
+ };
6018
+ Relationships: [
6019
+ {
6020
+ foreignKeyName: "nmbrs_employee_mapping_monteur_id_fkey";
6021
+ columns: ["monteur_id"];
6022
+ isOneToOne: true;
6023
+ referencedRelation: "monteurs";
6024
+ referencedColumns: ["id"];
6025
+ }
6026
+ ];
6027
+ };
6028
+ nmbrs_export_lines: {
6029
+ Row: {
6030
+ amount: number;
6031
+ created_at: string;
6032
+ entry_date: string;
6033
+ hours: number;
6034
+ id: string;
6035
+ monteur_id: string;
6036
+ nmbrs_employee_number: string | null;
6037
+ notes: string | null;
6038
+ run_id: string;
6039
+ source_kind: string | null;
6040
+ source_ref_id: string | null;
6041
+ updated_at: string;
6042
+ wage_code: string;
6043
+ };
6044
+ Insert: {
6045
+ amount?: number;
6046
+ created_at?: string;
6047
+ entry_date: string;
6048
+ hours?: number;
6049
+ id?: string;
6050
+ monteur_id: string;
6051
+ nmbrs_employee_number?: string | null;
6052
+ notes?: string | null;
6053
+ run_id: string;
6054
+ source_kind?: string | null;
6055
+ source_ref_id?: string | null;
6056
+ updated_at?: string;
6057
+ wage_code: string;
6058
+ };
6059
+ Update: {
6060
+ amount?: number;
6061
+ created_at?: string;
6062
+ entry_date?: string;
6063
+ hours?: number;
6064
+ id?: string;
6065
+ monteur_id?: string;
6066
+ nmbrs_employee_number?: string | null;
6067
+ notes?: string | null;
6068
+ run_id?: string;
6069
+ source_kind?: string | null;
6070
+ source_ref_id?: string | null;
6071
+ updated_at?: string;
6072
+ wage_code?: string;
6073
+ };
6074
+ Relationships: [
6075
+ {
6076
+ foreignKeyName: "nmbrs_export_lines_monteur_id_fkey";
6077
+ columns: ["monteur_id"];
6078
+ isOneToOne: false;
6079
+ referencedRelation: "monteurs";
6080
+ referencedColumns: ["id"];
6081
+ },
6082
+ {
6083
+ foreignKeyName: "nmbrs_export_lines_run_id_fkey";
6084
+ columns: ["run_id"];
6085
+ isOneToOne: false;
6086
+ referencedRelation: "nmbrs_export_runs";
6087
+ referencedColumns: ["id"];
6088
+ },
6089
+ {
6090
+ foreignKeyName: "nmbrs_export_lines_wage_code_fkey";
6091
+ columns: ["wage_code"];
6092
+ isOneToOne: false;
6093
+ referencedRelation: "nmbrs_wage_components";
6094
+ referencedColumns: ["code"];
6095
+ }
6096
+ ];
6097
+ };
6098
+ nmbrs_export_runs: {
6099
+ Row: {
6100
+ created_at: string;
6101
+ file_name: string | null;
6102
+ generated_at: string;
6103
+ generated_by: string | null;
6104
+ id: string;
6105
+ notes: string | null;
6106
+ period_end: string;
6107
+ period_label: string;
6108
+ period_start: string;
6109
+ status: string;
6110
+ total_hours: number;
6111
+ total_lines: number;
6112
+ updated_at: string;
6113
+ };
6114
+ Insert: {
6115
+ created_at?: string;
6116
+ file_name?: string | null;
6117
+ generated_at?: string;
6118
+ generated_by?: string | null;
6119
+ id?: string;
6120
+ notes?: string | null;
6121
+ period_end: string;
6122
+ period_label: string;
6123
+ period_start: string;
6124
+ status?: string;
6125
+ total_hours?: number;
6126
+ total_lines?: number;
6127
+ updated_at?: string;
6128
+ };
6129
+ Update: {
6130
+ created_at?: string;
6131
+ file_name?: string | null;
6132
+ generated_at?: string;
6133
+ generated_by?: string | null;
6134
+ id?: string;
6135
+ notes?: string | null;
6136
+ period_end?: string;
6137
+ period_label?: string;
6138
+ period_start?: string;
6139
+ status?: string;
6140
+ total_hours?: number;
6141
+ total_lines?: number;
6142
+ updated_at?: string;
6143
+ };
6144
+ Relationships: [];
6145
+ };
6146
+ nmbrs_settings: {
6147
+ Row: {
6148
+ created_at: string;
6149
+ default_company_code: string | null;
6150
+ id: boolean;
6151
+ include_travel: boolean;
6152
+ overtime_threshold_daily: number;
6153
+ overtime_threshold_weekly: number;
6154
+ period_type: string;
6155
+ updated_at: string;
6156
+ updated_by: string | null;
6157
+ week_start_day: number;
6158
+ };
6159
+ Insert: {
6160
+ created_at?: string;
6161
+ default_company_code?: string | null;
6162
+ id?: boolean;
6163
+ include_travel?: boolean;
6164
+ overtime_threshold_daily?: number;
6165
+ overtime_threshold_weekly?: number;
6166
+ period_type?: string;
6167
+ updated_at?: string;
6168
+ updated_by?: string | null;
6169
+ week_start_day?: number;
6170
+ };
6171
+ Update: {
6172
+ created_at?: string;
6173
+ default_company_code?: string | null;
6174
+ id?: boolean;
6175
+ include_travel?: boolean;
6176
+ overtime_threshold_daily?: number;
6177
+ overtime_threshold_weekly?: number;
6178
+ period_type?: string;
6179
+ updated_at?: string;
6180
+ updated_by?: string | null;
6181
+ week_start_day?: number;
6182
+ };
6183
+ Relationships: [];
6184
+ };
6185
+ nmbrs_wage_components: {
6186
+ Row: {
6187
+ category: string;
6188
+ code: string;
6189
+ created_at: string;
6190
+ id: string;
6191
+ is_active: boolean;
6192
+ label: string;
6193
+ sort_order: number;
6194
+ unit: string;
6195
+ updated_at: string;
6196
+ };
6197
+ Insert: {
6198
+ category: string;
6199
+ code: string;
6200
+ created_at?: string;
6201
+ id?: string;
6202
+ is_active?: boolean;
6203
+ label: string;
6204
+ sort_order?: number;
6205
+ unit: string;
6206
+ updated_at?: string;
6207
+ };
6208
+ Update: {
6209
+ category?: string;
6210
+ code?: string;
6211
+ created_at?: string;
6212
+ id?: string;
6213
+ is_active?: boolean;
6214
+ label?: string;
6215
+ sort_order?: number;
6216
+ unit?: string;
6217
+ updated_at?: string;
6218
+ };
6219
+ Relationships: [];
6220
+ };
5691
6221
  notifications: {
5692
6222
  Row: {
5693
6223
  created_at: string;
@@ -7600,6 +8130,48 @@ export type Database = {
7600
8130
  };
7601
8131
  Relationships: [];
7602
8132
  };
8133
+ stock_import_runs: {
8134
+ Row: {
8135
+ connection_id: string | null;
8136
+ created_at: string;
8137
+ created_rows: number;
8138
+ errors: Json;
8139
+ filename: string | null;
8140
+ id: string;
8141
+ mutations: Json;
8142
+ skipped_rows: number;
8143
+ total_rows: number;
8144
+ updated_rows: number;
8145
+ user_id: string;
8146
+ };
8147
+ Insert: {
8148
+ connection_id?: string | null;
8149
+ created_at?: string;
8150
+ created_rows?: number;
8151
+ errors?: Json;
8152
+ filename?: string | null;
8153
+ id?: string;
8154
+ mutations?: Json;
8155
+ skipped_rows?: number;
8156
+ total_rows?: number;
8157
+ updated_rows?: number;
8158
+ user_id: string;
8159
+ };
8160
+ Update: {
8161
+ connection_id?: string | null;
8162
+ created_at?: string;
8163
+ created_rows?: number;
8164
+ errors?: Json;
8165
+ filename?: string | null;
8166
+ id?: string;
8167
+ mutations?: Json;
8168
+ skipped_rows?: number;
8169
+ total_rows?: number;
8170
+ updated_rows?: number;
8171
+ user_id?: string;
8172
+ };
8173
+ Relationships: [];
8174
+ };
7603
8175
  stock_mutation_log: {
7604
8176
  Row: {
7605
8177
  connection_id: string | null;
@@ -9261,6 +9833,44 @@ export type Database = {
9261
9833
  };
9262
9834
  Relationships: [];
9263
9835
  };
9836
+ floriday_customer_discounts: {
9837
+ Row: {
9838
+ base_price: number | null;
9839
+ buyer_organization_id: string | null;
9840
+ currency: string | null;
9841
+ discount_type: string | null;
9842
+ discount_value: number | null;
9843
+ min_quantity: number | null;
9844
+ net_price: number | null;
9845
+ product_group_id: string | null;
9846
+ raw: Json | null;
9847
+ source: string | null;
9848
+ source_id: string | null;
9849
+ trade_item_id: string | null;
9850
+ valid_from: string | null;
9851
+ valid_until: string | null;
9852
+ };
9853
+ Relationships: [];
9854
+ };
9855
+ local_customer_discounts: {
9856
+ Row: {
9857
+ base_price: number | null;
9858
+ currency: string | null;
9859
+ customer_id: string | null;
9860
+ discount_type: string | null;
9861
+ discount_value: number | null;
9862
+ min_quantity: number | null;
9863
+ net_price: number | null;
9864
+ product_category_id: string | null;
9865
+ product_id: string | null;
9866
+ product_name: string | null;
9867
+ source: string | null;
9868
+ source_id: string | null;
9869
+ valid_from: string | null;
9870
+ valid_until: string | null;
9871
+ };
9872
+ Relationships: [];
9873
+ };
9264
9874
  manufacture_product_possible_stock_view: {
9265
9875
  Row: {
9266
9876
  component_count: number | null;
@@ -9557,6 +10167,32 @@ export type Database = {
9557
10167
  };
9558
10168
  Returns: number;
9559
10169
  };
10170
+ afh_city_code: {
10171
+ Args: {
10172
+ _city: string;
10173
+ _country: string;
10174
+ };
10175
+ Returns: string;
10176
+ };
10177
+ afh_normalize_country: {
10178
+ Args: {
10179
+ _raw: string;
10180
+ };
10181
+ Returns: string;
10182
+ };
10183
+ afh_normalize_nl_province: {
10184
+ Args: {
10185
+ _raw: string;
10186
+ };
10187
+ Returns: string;
10188
+ };
10189
+ afh_subtract_workdays: {
10190
+ Args: {
10191
+ _date: string;
10192
+ _days: number;
10193
+ };
10194
+ Returns: string;
10195
+ };
9560
10196
  apply_stock_consumption: {
9561
10197
  Args: {
9562
10198
  p_order_id: string;
@@ -9602,12 +10238,40 @@ export type Database = {
9602
10238
  order_number: string;
9603
10239
  }[];
9604
10240
  };
10241
+ backfill_open_order_reservations: {
10242
+ Args: never;
10243
+ Returns: {
10244
+ processed_items: number;
10245
+ }[];
10246
+ };
9605
10247
  call_exact_route: {
9606
10248
  Args: {
9607
10249
  path: string;
9608
10250
  };
9609
10251
  Returns: number;
9610
10252
  };
10253
+ check_offer_product_available_stock: {
10254
+ Args: {
10255
+ p_campaign_product_id: string;
10256
+ p_code: string;
10257
+ p_needed_qty?: number;
10258
+ p_product_name?: string;
10259
+ };
10260
+ Returns: Json;
10261
+ };
10262
+ check_trade_item_available_stock: {
10263
+ Args: {
10264
+ p_connection_id?: string;
10265
+ p_context?: string;
10266
+ p_needed_qty?: number;
10267
+ p_order_id?: string;
10268
+ p_order_item_id?: string;
10269
+ p_owner_id?: string;
10270
+ p_product_name?: string;
10271
+ p_trade_item_key: string;
10272
+ };
10273
+ Returns: Json;
10274
+ };
9611
10275
  cleanup_old_bookings: {
9612
10276
  Args: never;
9613
10277
  Returns: number;
@@ -9651,6 +10315,12 @@ export type Database = {
9651
10315
  table_name: string;
9652
10316
  }[];
9653
10317
  };
10318
+ dispatch_carrier_signups_sql: {
10319
+ Args: {
10320
+ _catchup?: string;
10321
+ };
10322
+ Returns: Json;
10323
+ };
9654
10324
  email_auth_decrypt: {
9655
10325
  Args: {
9656
10326
  cipher: string;
@@ -9686,6 +10356,12 @@ export type Database = {
9686
10356
  status: string;
9687
10357
  }[];
9688
10358
  };
10359
+ ensure_trade_item_stock_row: {
10360
+ Args: {
10361
+ p_key: string;
10362
+ };
10363
+ Returns: undefined;
10364
+ };
9689
10365
  ensure_user_tenant: {
9690
10366
  Args: never;
9691
10367
  Returns: string;
@@ -9723,6 +10399,31 @@ export type Database = {
9723
10399
  };
9724
10400
  Returns: boolean;
9725
10401
  };
10402
+ find_trade_item_key: {
10403
+ Args: {
10404
+ p_barcode: string;
10405
+ p_name: string;
10406
+ p_product_id: string;
10407
+ };
10408
+ Returns: string;
10409
+ };
10410
+ floriday_effective_price: {
10411
+ Args: {
10412
+ _buyer_id: string;
10413
+ _on_date?: string;
10414
+ _quantity?: number;
10415
+ _trade_item_id: string;
10416
+ };
10417
+ Returns: {
10418
+ base_price: number;
10419
+ currency: string;
10420
+ discount_type: string;
10421
+ discount_value: number;
10422
+ net_price: number;
10423
+ source: string;
10424
+ source_id: string;
10425
+ }[];
10426
+ };
9726
10427
  format_cart_number: {
9727
10428
  Args: {
9728
10429
  p_pick_date: string;
@@ -9743,6 +10444,13 @@ export type Database = {
9743
10444
  preferred_warehouse_name: string;
9744
10445
  }[];
9745
10446
  };
10447
+ get_active_floriday_context: {
10448
+ Args: never;
10449
+ Returns: {
10450
+ connection_id: string;
10451
+ user_id: string;
10452
+ }[];
10453
+ };
9746
10454
  get_active_twinfield_public: {
9747
10455
  Args: never;
9748
10456
  Returns: {
@@ -9845,6 +10553,18 @@ export type Database = {
9845
10553
  };
9846
10554
  Returns: Json;
9847
10555
  };
10556
+ get_offer_recipient_by_code: {
10557
+ Args: {
10558
+ p_code: string;
10559
+ };
10560
+ Returns: {
10561
+ campaign_id: string;
10562
+ clicked_at: string;
10563
+ customer_id: string;
10564
+ id: string;
10565
+ ordered_at: string;
10566
+ }[];
10567
+ };
9848
10568
  get_or_assign_floriday_order_number: {
9849
10569
  Args: {
9850
10570
  p_floriday_id: string;
@@ -9897,6 +10617,34 @@ export type Database = {
9897
10617
  Args: never;
9898
10618
  Returns: boolean;
9899
10619
  };
10620
+ local_effective_price: {
10621
+ Args: {
10622
+ _customer_id: string;
10623
+ _on_date?: string;
10624
+ _product_id: string;
10625
+ _quantity?: number;
10626
+ };
10627
+ Returns: {
10628
+ currency: string;
10629
+ discount_type: string;
10630
+ discount_value: number;
10631
+ net_price: number;
10632
+ source: string;
10633
+ source_id: string;
10634
+ }[];
10635
+ };
10636
+ mark_offer_clicked: {
10637
+ Args: {
10638
+ p_code: string;
10639
+ };
10640
+ Returns: undefined;
10641
+ };
10642
+ mark_offer_ordered: {
10643
+ Args: {
10644
+ p_code: string;
10645
+ };
10646
+ Returns: undefined;
10647
+ };
9900
10648
  next_order_number: {
9901
10649
  Args: {
9902
10650
  p_prefix: string;
@@ -9916,6 +10664,14 @@ export type Database = {
9916
10664
  };
9917
10665
  Returns: string;
9918
10666
  };
10667
+ offer_recipient_matches: {
10668
+ Args: {
10669
+ _campaign_id: string;
10670
+ _customer_id: string;
10671
+ _recipient_id: string;
10672
+ };
10673
+ Returns: boolean;
10674
+ };
9919
10675
  pickstation_get_orders_raw: {
9920
10676
  Args: never;
9921
10677
  Returns: Json;
@@ -9943,6 +10699,13 @@ export type Database = {
9943
10699
  };
9944
10700
  Returns: undefined;
9945
10701
  };
10702
+ promote_trade_item_key: {
10703
+ Args: {
10704
+ p_new: string;
10705
+ p_old: string;
10706
+ };
10707
+ Returns: undefined;
10708
+ };
9946
10709
  refresh_floricode_derived_code_lists: {
9947
10710
  Args: never;
9948
10711
  Returns: {