@flowselections/floriday-afhandeling-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.
Files changed (33) hide show
  1. package/dist-lib/components/afhandeling/LeveringenPage.d.ts.map +1 -1
  2. package/dist-lib/components/afhandeling/LeveringenPage.js +23 -2
  3. package/dist-lib/components/afhandeling/NieuweLeveringPage.d.ts +2 -0
  4. package/dist-lib/components/afhandeling/NieuweLeveringPage.d.ts.map +1 -0
  5. package/dist-lib/components/afhandeling/NieuweLeveringPage.js +7 -0
  6. package/dist-lib/components/afhandeling/VervoerderForm.d.ts +6 -0
  7. package/dist-lib/components/afhandeling/VervoerderForm.d.ts.map +1 -0
  8. package/dist-lib/components/afhandeling/VervoerderForm.js +136 -0
  9. package/dist-lib/components/afhandeling/VervoerdersPage.d.ts +2 -0
  10. package/dist-lib/components/afhandeling/VervoerdersPage.d.ts.map +1 -0
  11. package/dist-lib/components/afhandeling/VervoerdersPage.js +41 -0
  12. package/dist-lib/index.d.ts +2 -0
  13. package/dist-lib/index.d.ts.map +1 -1
  14. package/dist-lib/index.js +6 -3
  15. package/dist-lib/integrations/supabase/auth-middleware.d.ts +3038 -234
  16. package/dist-lib/integrations/supabase/auth-middleware.d.ts.map +1 -1
  17. package/dist-lib/integrations/supabase/client.d.ts +3038 -234
  18. package/dist-lib/integrations/supabase/client.d.ts.map +1 -1
  19. package/dist-lib/integrations/supabase/client.server.d.ts +3038 -234
  20. package/dist-lib/integrations/supabase/client.server.d.ts.map +1 -1
  21. package/dist-lib/integrations/supabase/types.d.ts +3170 -296
  22. package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
  23. package/dist-lib/integrations/supabase/types.js +18 -1
  24. package/dist-lib/lib/carriers.functions.d.ts +26576 -0
  25. package/dist-lib/lib/carriers.functions.d.ts.map +1 -0
  26. package/dist-lib/lib/carriers.functions.js +131 -0
  27. package/dist-lib/lib/countries.d.ts +7 -0
  28. package/dist-lib/lib/countries.d.ts.map +1 -0
  29. package/dist-lib/lib/countries.js +47 -0
  30. package/dist-lib/lib/floriday.functions.d.ts +3040 -235
  31. package/dist-lib/lib/floriday.functions.d.ts.map +1 -1
  32. package/dist-lib/lib/floriday.functions.js +4 -5
  33. package/package.json +8 -3
@@ -1,3 +1,4 @@
1
+ import type { SupabaseClient } from "@supabase/supabase-js";
1
2
  export interface FloridayOrder {
2
3
  id: string;
3
4
  orderNumber: string;
@@ -10,7 +11,7 @@ export interface FloridayOrder {
10
11
  currency: string | null;
11
12
  }
12
13
  export declare const getFloridayOrders: import("@tanstack/start-client-core").OptionalFetcher<readonly [import("@tanstack/start-client-core").FunctionMiddlewareAfterServer<{}, unknown, undefined, {
13
- supabase: import("@supabase/supabase-js").SupabaseClient<import("../integrations/supabase/types").Database, "public", "public", {
14
+ supabase: SupabaseClient<import("../integrations/supabase/types").Database, "public", "public", {
14
15
  Tables: {
15
16
  agenda_connections: {
16
17
  Row: {
@@ -198,6 +199,153 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
198
199
  };
199
200
  Relationships: [];
200
201
  };
202
+ app_settings: {
203
+ Row: {
204
+ created_at: string;
205
+ id: string;
206
+ key: string;
207
+ updated_at: string;
208
+ value: string | null;
209
+ };
210
+ Insert: {
211
+ created_at?: string;
212
+ id?: string;
213
+ key: string;
214
+ updated_at?: string;
215
+ value?: string | null;
216
+ };
217
+ Update: {
218
+ created_at?: string;
219
+ id?: string;
220
+ key?: string;
221
+ updated_at?: string;
222
+ value?: string | null;
223
+ };
224
+ Relationships: [];
225
+ };
226
+ booking_items: {
227
+ Row: {
228
+ booking_id: string;
229
+ created_at: string;
230
+ extra_id: string;
231
+ id: string;
232
+ quantity: number;
233
+ total_price: number;
234
+ unit_price: number;
235
+ };
236
+ Insert: {
237
+ booking_id: string;
238
+ created_at?: string;
239
+ extra_id: string;
240
+ id?: string;
241
+ quantity?: number;
242
+ total_price?: number;
243
+ unit_price?: number;
244
+ };
245
+ Update: {
246
+ booking_id?: string;
247
+ created_at?: string;
248
+ extra_id?: string;
249
+ id?: string;
250
+ quantity?: number;
251
+ total_price?: number;
252
+ unit_price?: number;
253
+ };
254
+ Relationships: [{
255
+ foreignKeyName: "booking_items_booking_id_fkey";
256
+ columns: ["booking_id"];
257
+ isOneToOne: false;
258
+ referencedRelation: "bookings";
259
+ referencedColumns: ["id"];
260
+ }, {
261
+ foreignKeyName: "booking_items_extra_id_fkey";
262
+ columns: ["extra_id"];
263
+ isOneToOne: false;
264
+ referencedRelation: "extras";
265
+ referencedColumns: ["id"];
266
+ }];
267
+ };
268
+ bookings: {
269
+ Row: {
270
+ company_name: string | null;
271
+ conflict_checked_at: string | null;
272
+ conflict_reason: string | null;
273
+ created_at: string;
274
+ created_by_role: string | null;
275
+ customer_email: string | null;
276
+ customer_name: string | null;
277
+ end_time: string;
278
+ exact_debiteur_id: string | null;
279
+ has_conflict: boolean;
280
+ id: string;
281
+ invoice_run_id: string | null;
282
+ invoice_status: string | null;
283
+ invoiced_at: string | null;
284
+ number_of_people: number;
285
+ room_id: string;
286
+ start_time: string;
287
+ status: string;
288
+ total_excl_vat: number | null;
289
+ total_incl_vat: number | null;
290
+ user_id: string | null;
291
+ vat_amount: number | null;
292
+ };
293
+ Insert: {
294
+ company_name?: string | null;
295
+ conflict_checked_at?: string | null;
296
+ conflict_reason?: string | null;
297
+ created_at?: string;
298
+ created_by_role?: string | null;
299
+ customer_email?: string | null;
300
+ customer_name?: string | null;
301
+ end_time: string;
302
+ exact_debiteur_id?: string | null;
303
+ has_conflict?: boolean;
304
+ id?: string;
305
+ invoice_run_id?: string | null;
306
+ invoice_status?: string | null;
307
+ invoiced_at?: string | null;
308
+ number_of_people?: number;
309
+ room_id: string;
310
+ start_time: string;
311
+ status?: string;
312
+ total_excl_vat?: number | null;
313
+ total_incl_vat?: number | null;
314
+ user_id?: string | null;
315
+ vat_amount?: number | null;
316
+ };
317
+ Update: {
318
+ company_name?: string | null;
319
+ conflict_checked_at?: string | null;
320
+ conflict_reason?: string | null;
321
+ created_at?: string;
322
+ created_by_role?: string | null;
323
+ customer_email?: string | null;
324
+ customer_name?: string | null;
325
+ end_time?: string;
326
+ exact_debiteur_id?: string | null;
327
+ has_conflict?: boolean;
328
+ id?: string;
329
+ invoice_run_id?: string | null;
330
+ invoice_status?: string | null;
331
+ invoiced_at?: string | null;
332
+ number_of_people?: number;
333
+ room_id?: string;
334
+ start_time?: string;
335
+ status?: string;
336
+ total_excl_vat?: number | null;
337
+ total_incl_vat?: number | null;
338
+ user_id?: string | null;
339
+ vat_amount?: number | null;
340
+ };
341
+ Relationships: [{
342
+ foreignKeyName: "bookings_room_id_fkey";
343
+ columns: ["room_id"];
344
+ isOneToOne: false;
345
+ referencedRelation: "rooms";
346
+ referencedColumns: ["id"];
347
+ }];
348
+ };
201
349
  bugs: {
202
350
  Row: {
203
351
  attachment_url: string | null;
@@ -234,6 +382,84 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
234
382
  };
235
383
  Relationships: [];
236
384
  };
385
+ carrier_shipping_rates: {
386
+ Row: {
387
+ carrier_id: string;
388
+ country_code: string;
389
+ created_at: string;
390
+ id: string;
391
+ price_per_trolley: number;
392
+ };
393
+ Insert: {
394
+ carrier_id: string;
395
+ country_code: string;
396
+ created_at?: string;
397
+ id?: string;
398
+ price_per_trolley: number;
399
+ };
400
+ Update: {
401
+ carrier_id?: string;
402
+ country_code?: string;
403
+ created_at?: string;
404
+ id?: string;
405
+ price_per_trolley?: number;
406
+ };
407
+ Relationships: [{
408
+ foreignKeyName: "carrier_shipping_rates_carrier_id_fkey";
409
+ columns: ["carrier_id"];
410
+ isOneToOne: false;
411
+ referencedRelation: "carriers";
412
+ referencedColumns: ["id"];
413
+ }];
414
+ };
415
+ carriers: {
416
+ Row: {
417
+ address: string | null;
418
+ contact_person: string | null;
419
+ created_at: string;
420
+ delivery_days: number | null;
421
+ email: string | null;
422
+ id: string;
423
+ name: string;
424
+ notes: string | null;
425
+ phone: string | null;
426
+ signup_time_1: string | null;
427
+ signup_time_2: string | null;
428
+ updated_at: string;
429
+ user_id: string;
430
+ };
431
+ Insert: {
432
+ address?: string | null;
433
+ contact_person?: string | null;
434
+ created_at?: string;
435
+ delivery_days?: number | null;
436
+ email?: string | null;
437
+ id?: string;
438
+ name: string;
439
+ notes?: string | null;
440
+ phone?: string | null;
441
+ signup_time_1?: string | null;
442
+ signup_time_2?: string | null;
443
+ updated_at?: string;
444
+ user_id: string;
445
+ };
446
+ Update: {
447
+ address?: string | null;
448
+ contact_person?: string | null;
449
+ created_at?: string;
450
+ delivery_days?: number | null;
451
+ email?: string | null;
452
+ id?: string;
453
+ name?: string;
454
+ notes?: string | null;
455
+ phone?: string | null;
456
+ signup_time_1?: string | null;
457
+ signup_time_2?: string | null;
458
+ updated_at?: string;
459
+ user_id?: string;
460
+ };
461
+ Relationships: [];
462
+ };
237
463
  collections: {
238
464
  Row: {
239
465
  created_at: string;
@@ -942,114 +1168,423 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
942
1168
  };
943
1169
  Relationships: [];
944
1170
  };
945
- exact_account_analytics_cache: {
1171
+ email_auth_connections: {
946
1172
  Row: {
947
- account_id: string;
948
- account_name: string | null;
949
- avg_payment_days: number | null;
950
- computed_at: string;
951
- connection_id: string;
952
- expires_at: string | null;
1173
+ access_token_encrypted: string | null;
1174
+ account_email: string | null;
1175
+ client_id_encrypted: string | null;
1176
+ client_secret_encrypted: string | null;
1177
+ created_at: string;
1178
+ created_by: string | null;
1179
+ display_name: string | null;
1180
+ gmail_history_id: string | null;
1181
+ gmail_watch_expires_at: string | null;
1182
+ graph_subscription_expires_at: string | null;
1183
+ graph_subscription_id: string | null;
953
1184
  id: string;
954
- invoice_count: number | null;
955
- last_invoice_date: string | null;
956
- last_payment_date: string | null;
957
- open_balance: number | null;
958
- overdue_balance: number | null;
959
- total_revenue: number | null;
1185
+ imap_host: string | null;
1186
+ imap_last_uid: number | null;
1187
+ imap_password_encrypted: string | null;
1188
+ imap_port: number | null;
1189
+ imap_secure: boolean | null;
1190
+ imap_uid_validity: number | null;
1191
+ imap_username: string | null;
1192
+ is_active: boolean;
1193
+ last_error: string | null;
1194
+ last_event_at: string | null;
1195
+ last_verified_at: string | null;
1196
+ oauth_mode: string | null;
1197
+ provider: string;
1198
+ purpose_assignments: import("../integrations/supabase/types").Json;
1199
+ realtime_mode: string;
1200
+ refresh_token_encrypted: string | null;
1201
+ scopes: string[] | null;
1202
+ smtp_host: string | null;
1203
+ smtp_password_encrypted: string | null;
1204
+ smtp_port: number | null;
1205
+ smtp_secure: boolean | null;
1206
+ smtp_username: string | null;
1207
+ status: string;
1208
+ token_expires_at: string | null;
1209
+ updated_at: string;
960
1210
  };
961
1211
  Insert: {
962
- account_id: string;
963
- account_name?: string | null;
964
- avg_payment_days?: number | null;
965
- computed_at?: string;
966
- connection_id: string;
967
- expires_at?: string | null;
968
- id?: string;
969
- invoice_count?: number | null;
970
- last_invoice_date?: string | null;
971
- last_payment_date?: string | null;
972
- open_balance?: number | null;
973
- overdue_balance?: number | null;
974
- total_revenue?: number | null;
1212
+ access_token_encrypted?: string | null;
1213
+ account_email?: string | null;
1214
+ client_id_encrypted?: string | null;
1215
+ client_secret_encrypted?: string | null;
1216
+ created_at?: string;
1217
+ created_by?: string | null;
1218
+ display_name?: string | null;
1219
+ gmail_history_id?: string | null;
1220
+ gmail_watch_expires_at?: string | null;
1221
+ graph_subscription_expires_at?: string | null;
1222
+ graph_subscription_id?: string | null;
1223
+ id?: string;
1224
+ imap_host?: string | null;
1225
+ imap_last_uid?: number | null;
1226
+ imap_password_encrypted?: string | null;
1227
+ imap_port?: number | null;
1228
+ imap_secure?: boolean | null;
1229
+ imap_uid_validity?: number | null;
1230
+ imap_username?: string | null;
1231
+ is_active?: boolean;
1232
+ last_error?: string | null;
1233
+ last_event_at?: string | null;
1234
+ last_verified_at?: string | null;
1235
+ oauth_mode?: string | null;
1236
+ provider: string;
1237
+ purpose_assignments?: import("../integrations/supabase/types").Json;
1238
+ realtime_mode?: string;
1239
+ refresh_token_encrypted?: string | null;
1240
+ scopes?: string[] | null;
1241
+ smtp_host?: string | null;
1242
+ smtp_password_encrypted?: string | null;
1243
+ smtp_port?: number | null;
1244
+ smtp_secure?: boolean | null;
1245
+ smtp_username?: string | null;
1246
+ status?: string;
1247
+ token_expires_at?: string | null;
1248
+ updated_at?: string;
975
1249
  };
976
1250
  Update: {
977
- account_id?: string;
978
- account_name?: string | null;
979
- avg_payment_days?: number | null;
980
- computed_at?: string;
981
- connection_id?: string;
982
- expires_at?: string | null;
983
- id?: string;
984
- invoice_count?: number | null;
985
- last_invoice_date?: string | null;
986
- last_payment_date?: string | null;
987
- open_balance?: number | null;
988
- overdue_balance?: number | null;
989
- total_revenue?: number | null;
1251
+ access_token_encrypted?: string | null;
1252
+ account_email?: string | null;
1253
+ client_id_encrypted?: string | null;
1254
+ client_secret_encrypted?: string | null;
1255
+ created_at?: string;
1256
+ created_by?: string | null;
1257
+ display_name?: string | null;
1258
+ gmail_history_id?: string | null;
1259
+ gmail_watch_expires_at?: string | null;
1260
+ graph_subscription_expires_at?: string | null;
1261
+ graph_subscription_id?: string | null;
1262
+ id?: string;
1263
+ imap_host?: string | null;
1264
+ imap_last_uid?: number | null;
1265
+ imap_password_encrypted?: string | null;
1266
+ imap_port?: number | null;
1267
+ imap_secure?: boolean | null;
1268
+ imap_uid_validity?: number | null;
1269
+ imap_username?: string | null;
1270
+ is_active?: boolean;
1271
+ last_error?: string | null;
1272
+ last_event_at?: string | null;
1273
+ last_verified_at?: string | null;
1274
+ oauth_mode?: string | null;
1275
+ provider?: string;
1276
+ purpose_assignments?: import("../integrations/supabase/types").Json;
1277
+ realtime_mode?: string;
1278
+ refresh_token_encrypted?: string | null;
1279
+ scopes?: string[] | null;
1280
+ smtp_host?: string | null;
1281
+ smtp_password_encrypted?: string | null;
1282
+ smtp_port?: number | null;
1283
+ smtp_secure?: boolean | null;
1284
+ smtp_username?: string | null;
1285
+ status?: string;
1286
+ token_expires_at?: string | null;
1287
+ updated_at?: string;
990
1288
  };
991
- Relationships: [{
992
- foreignKeyName: "exact_account_analytics_cache_connection_id_fkey";
993
- columns: ["connection_id"];
994
- isOneToOne: false;
995
- referencedRelation: "exact_connections";
996
- referencedColumns: ["id"];
997
- }];
1289
+ Relationships: [];
998
1290
  };
999
- exact_analytics_cache: {
1291
+ email_auth_events: {
1000
1292
  Row: {
1001
- analytics_type: string;
1002
- avg_payment_days: number | null;
1003
- computed_at: string;
1004
1293
  connection_id: string;
1005
- data_raw: import("../integrations/supabase/types").Json | null;
1006
- expires_at: string | null;
1294
+ consumed_at: string | null;
1295
+ created_at: string;
1296
+ event_type: string;
1297
+ external_id: string | null;
1007
1298
  id: string;
1008
- open_count: number | null;
1009
- overdue_amount: number | null;
1010
- paid_this_month: number | null;
1011
- period_key: string;
1012
- total_invoiced: number | null;
1013
- total_open: number | null;
1299
+ payload: import("../integrations/supabase/types").Json;
1300
+ provider: string;
1301
+ received_at: string;
1014
1302
  };
1015
1303
  Insert: {
1016
- analytics_type: string;
1017
- avg_payment_days?: number | null;
1018
- computed_at?: string;
1019
1304
  connection_id: string;
1020
- data_raw?: import("../integrations/supabase/types").Json | null;
1021
- expires_at?: string | null;
1305
+ consumed_at?: string | null;
1306
+ created_at?: string;
1307
+ event_type: string;
1308
+ external_id?: string | null;
1022
1309
  id?: string;
1023
- open_count?: number | null;
1024
- overdue_amount?: number | null;
1025
- paid_this_month?: number | null;
1026
- period_key: string;
1027
- total_invoiced?: number | null;
1028
- total_open?: number | null;
1310
+ payload?: import("../integrations/supabase/types").Json;
1311
+ provider: string;
1312
+ received_at?: string;
1029
1313
  };
1030
1314
  Update: {
1031
- analytics_type?: string;
1032
- avg_payment_days?: number | null;
1033
- computed_at?: string;
1034
1315
  connection_id?: string;
1035
- data_raw?: import("../integrations/supabase/types").Json | null;
1036
- expires_at?: string | null;
1316
+ consumed_at?: string | null;
1317
+ created_at?: string;
1318
+ event_type?: string;
1319
+ external_id?: string | null;
1037
1320
  id?: string;
1038
- open_count?: number | null;
1039
- overdue_amount?: number | null;
1040
- paid_this_month?: number | null;
1041
- period_key?: string;
1042
- total_invoiced?: number | null;
1043
- total_open?: number | null;
1321
+ payload?: import("../integrations/supabase/types").Json;
1322
+ provider?: string;
1323
+ received_at?: string;
1044
1324
  };
1045
1325
  Relationships: [{
1046
- foreignKeyName: "exact_analytics_cache_connection_id_fkey";
1326
+ foreignKeyName: "email_auth_events_connection_id_fkey";
1047
1327
  columns: ["connection_id"];
1048
1328
  isOneToOne: false;
1049
- referencedRelation: "exact_connections";
1329
+ referencedRelation: "email_auth_connections";
1050
1330
  referencedColumns: ["id"];
1051
- }];
1052
- };
1331
+ }, {
1332
+ foreignKeyName: "email_auth_events_connection_id_fkey";
1333
+ columns: ["connection_id"];
1334
+ isOneToOne: false;
1335
+ referencedRelation: "email_auth_connections_safe";
1336
+ referencedColumns: ["id"];
1337
+ }];
1338
+ };
1339
+ email_auth_outbox: {
1340
+ Row: {
1341
+ attempts: number;
1342
+ bcc_addresses: string[];
1343
+ cc_addresses: string[];
1344
+ connection_id: string | null;
1345
+ created_at: string;
1346
+ created_by: string | null;
1347
+ external_message_id: string | null;
1348
+ headers: import("../integrations/supabase/types").Json;
1349
+ html_body: string | null;
1350
+ id: string;
1351
+ last_error: string | null;
1352
+ purpose: string;
1353
+ reply_to: string | null;
1354
+ scheduled_at: string;
1355
+ sent_at: string | null;
1356
+ status: string;
1357
+ subject: string;
1358
+ text_body: string | null;
1359
+ to_addresses: string[];
1360
+ updated_at: string;
1361
+ };
1362
+ Insert: {
1363
+ attempts?: number;
1364
+ bcc_addresses?: string[];
1365
+ cc_addresses?: string[];
1366
+ connection_id?: string | null;
1367
+ created_at?: string;
1368
+ created_by?: string | null;
1369
+ external_message_id?: string | null;
1370
+ headers?: import("../integrations/supabase/types").Json;
1371
+ html_body?: string | null;
1372
+ id?: string;
1373
+ last_error?: string | null;
1374
+ purpose: string;
1375
+ reply_to?: string | null;
1376
+ scheduled_at?: string;
1377
+ sent_at?: string | null;
1378
+ status?: string;
1379
+ subject: string;
1380
+ text_body?: string | null;
1381
+ to_addresses: string[];
1382
+ updated_at?: string;
1383
+ };
1384
+ Update: {
1385
+ attempts?: number;
1386
+ bcc_addresses?: string[];
1387
+ cc_addresses?: string[];
1388
+ connection_id?: string | null;
1389
+ created_at?: string;
1390
+ created_by?: string | null;
1391
+ external_message_id?: string | null;
1392
+ headers?: import("../integrations/supabase/types").Json;
1393
+ html_body?: string | null;
1394
+ id?: string;
1395
+ last_error?: string | null;
1396
+ purpose?: string;
1397
+ reply_to?: string | null;
1398
+ scheduled_at?: string;
1399
+ sent_at?: string | null;
1400
+ status?: string;
1401
+ subject?: string;
1402
+ text_body?: string | null;
1403
+ to_addresses?: string[];
1404
+ updated_at?: string;
1405
+ };
1406
+ Relationships: [{
1407
+ foreignKeyName: "email_auth_outbox_connection_id_fkey";
1408
+ columns: ["connection_id"];
1409
+ isOneToOne: false;
1410
+ referencedRelation: "email_auth_connections";
1411
+ referencedColumns: ["id"];
1412
+ }, {
1413
+ foreignKeyName: "email_auth_outbox_connection_id_fkey";
1414
+ columns: ["connection_id"];
1415
+ isOneToOne: false;
1416
+ referencedRelation: "email_auth_connections_safe";
1417
+ referencedColumns: ["id"];
1418
+ }];
1419
+ };
1420
+ email_auth_purpose_settings: {
1421
+ Row: {
1422
+ purpose: string;
1423
+ reply_to: string | null;
1424
+ updated_at: string;
1425
+ updated_by: string | null;
1426
+ };
1427
+ Insert: {
1428
+ purpose: string;
1429
+ reply_to?: string | null;
1430
+ updated_at?: string;
1431
+ updated_by?: string | null;
1432
+ };
1433
+ Update: {
1434
+ purpose?: string;
1435
+ reply_to?: string | null;
1436
+ updated_at?: string;
1437
+ updated_by?: string | null;
1438
+ };
1439
+ Relationships: [];
1440
+ };
1441
+ email_auth_token_refresh_log: {
1442
+ Row: {
1443
+ connection_id: string;
1444
+ error_message: string | null;
1445
+ id: string;
1446
+ refreshed_at: string;
1447
+ success: boolean;
1448
+ trigger_source: string;
1449
+ };
1450
+ Insert: {
1451
+ connection_id: string;
1452
+ error_message?: string | null;
1453
+ id?: string;
1454
+ refreshed_at?: string;
1455
+ success: boolean;
1456
+ trigger_source: string;
1457
+ };
1458
+ Update: {
1459
+ connection_id?: string;
1460
+ error_message?: string | null;
1461
+ id?: string;
1462
+ refreshed_at?: string;
1463
+ success?: boolean;
1464
+ trigger_source?: string;
1465
+ };
1466
+ Relationships: [{
1467
+ foreignKeyName: "email_auth_token_refresh_log_connection_id_fkey";
1468
+ columns: ["connection_id"];
1469
+ isOneToOne: false;
1470
+ referencedRelation: "email_auth_connections";
1471
+ referencedColumns: ["id"];
1472
+ }, {
1473
+ foreignKeyName: "email_auth_token_refresh_log_connection_id_fkey";
1474
+ columns: ["connection_id"];
1475
+ isOneToOne: false;
1476
+ referencedRelation: "email_auth_connections_safe";
1477
+ referencedColumns: ["id"];
1478
+ }];
1479
+ };
1480
+ exact_account_analytics_cache: {
1481
+ Row: {
1482
+ account_id: string;
1483
+ account_name: string | null;
1484
+ avg_payment_days: number | null;
1485
+ computed_at: string;
1486
+ connection_id: string;
1487
+ expires_at: string | null;
1488
+ id: string;
1489
+ invoice_count: number | null;
1490
+ last_invoice_date: string | null;
1491
+ last_payment_date: string | null;
1492
+ open_balance: number | null;
1493
+ overdue_balance: number | null;
1494
+ total_revenue: number | null;
1495
+ };
1496
+ Insert: {
1497
+ account_id: string;
1498
+ account_name?: string | null;
1499
+ avg_payment_days?: number | null;
1500
+ computed_at?: string;
1501
+ connection_id: string;
1502
+ expires_at?: string | null;
1503
+ id?: string;
1504
+ invoice_count?: number | null;
1505
+ last_invoice_date?: string | null;
1506
+ last_payment_date?: string | null;
1507
+ open_balance?: number | null;
1508
+ overdue_balance?: number | null;
1509
+ total_revenue?: number | null;
1510
+ };
1511
+ Update: {
1512
+ account_id?: string;
1513
+ account_name?: string | null;
1514
+ avg_payment_days?: number | null;
1515
+ computed_at?: string;
1516
+ connection_id?: string;
1517
+ expires_at?: string | null;
1518
+ id?: string;
1519
+ invoice_count?: number | null;
1520
+ last_invoice_date?: string | null;
1521
+ last_payment_date?: string | null;
1522
+ open_balance?: number | null;
1523
+ overdue_balance?: number | null;
1524
+ total_revenue?: number | null;
1525
+ };
1526
+ Relationships: [{
1527
+ foreignKeyName: "exact_account_analytics_cache_connection_id_fkey";
1528
+ columns: ["connection_id"];
1529
+ isOneToOne: false;
1530
+ referencedRelation: "exact_connections";
1531
+ referencedColumns: ["id"];
1532
+ }];
1533
+ };
1534
+ exact_analytics_cache: {
1535
+ Row: {
1536
+ analytics_type: string;
1537
+ avg_payment_days: number | null;
1538
+ computed_at: string;
1539
+ connection_id: string;
1540
+ data_raw: import("../integrations/supabase/types").Json | null;
1541
+ expires_at: string | null;
1542
+ id: string;
1543
+ open_count: number | null;
1544
+ overdue_amount: number | null;
1545
+ paid_this_month: number | null;
1546
+ period_key: string;
1547
+ total_invoiced: number | null;
1548
+ total_open: number | null;
1549
+ };
1550
+ Insert: {
1551
+ analytics_type: string;
1552
+ avg_payment_days?: number | null;
1553
+ computed_at?: string;
1554
+ connection_id: string;
1555
+ data_raw?: import("../integrations/supabase/types").Json | null;
1556
+ expires_at?: string | null;
1557
+ id?: string;
1558
+ open_count?: number | null;
1559
+ overdue_amount?: number | null;
1560
+ paid_this_month?: number | null;
1561
+ period_key: string;
1562
+ total_invoiced?: number | null;
1563
+ total_open?: number | null;
1564
+ };
1565
+ Update: {
1566
+ analytics_type?: string;
1567
+ avg_payment_days?: number | null;
1568
+ computed_at?: string;
1569
+ connection_id?: string;
1570
+ data_raw?: import("../integrations/supabase/types").Json | null;
1571
+ expires_at?: string | null;
1572
+ id?: string;
1573
+ open_count?: number | null;
1574
+ overdue_amount?: number | null;
1575
+ paid_this_month?: number | null;
1576
+ period_key?: string;
1577
+ total_invoiced?: number | null;
1578
+ total_open?: number | null;
1579
+ };
1580
+ Relationships: [{
1581
+ foreignKeyName: "exact_analytics_cache_connection_id_fkey";
1582
+ columns: ["connection_id"];
1583
+ isOneToOne: false;
1584
+ referencedRelation: "exact_connections";
1585
+ referencedColumns: ["id"];
1586
+ }];
1587
+ };
1053
1588
  exact_bulk_operation_items: {
1054
1589
  Row: {
1055
1590
  attempts: number;
@@ -1300,11 +1835,15 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1300
1835
  address_line1: string | null;
1301
1836
  address_line2: string | null;
1302
1837
  balance: number | null;
1838
+ chamber_of_commerce: string | null;
1303
1839
  city: string | null;
1840
+ classification_description: string | null;
1304
1841
  connection_id: string;
1305
1842
  contact_name: string | null;
1306
1843
  country: string | null;
1844
+ created_at_exact: string | null;
1307
1845
  credit_line: number | null;
1846
+ currency: string | null;
1308
1847
  data_raw: import("../integrations/supabase/types").Json | null;
1309
1848
  email: string | null;
1310
1849
  exact_id: string;
@@ -1313,12 +1852,18 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1313
1852
  id: string;
1314
1853
  is_sales: boolean | null;
1315
1854
  is_supplier: boolean | null;
1855
+ language: string | null;
1856
+ modified_at_exact: string | null;
1857
+ payment_condition_description: string | null;
1858
+ payment_condition_sales: string | null;
1316
1859
  phone: string | null;
1317
1860
  postal_code: string | null;
1861
+ remarks: string | null;
1318
1862
  search_text: string | null;
1319
1863
  status: string | null;
1320
1864
  updated_at: string;
1321
1865
  vat_number: string | null;
1866
+ website: string | null;
1322
1867
  };
1323
1868
  Insert: {
1324
1869
  account_name?: string | null;
@@ -1326,11 +1871,15 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1326
1871
  address_line1?: string | null;
1327
1872
  address_line2?: string | null;
1328
1873
  balance?: number | null;
1874
+ chamber_of_commerce?: string | null;
1329
1875
  city?: string | null;
1876
+ classification_description?: string | null;
1330
1877
  connection_id: string;
1331
1878
  contact_name?: string | null;
1332
1879
  country?: string | null;
1880
+ created_at_exact?: string | null;
1333
1881
  credit_line?: number | null;
1882
+ currency?: string | null;
1334
1883
  data_raw?: import("../integrations/supabase/types").Json | null;
1335
1884
  email?: string | null;
1336
1885
  exact_id: string;
@@ -1339,12 +1888,18 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1339
1888
  id?: string;
1340
1889
  is_sales?: boolean | null;
1341
1890
  is_supplier?: boolean | null;
1891
+ language?: string | null;
1892
+ modified_at_exact?: string | null;
1893
+ payment_condition_description?: string | null;
1894
+ payment_condition_sales?: string | null;
1342
1895
  phone?: string | null;
1343
1896
  postal_code?: string | null;
1897
+ remarks?: string | null;
1344
1898
  search_text?: string | null;
1345
1899
  status?: string | null;
1346
1900
  updated_at?: string;
1347
1901
  vat_number?: string | null;
1902
+ website?: string | null;
1348
1903
  };
1349
1904
  Update: {
1350
1905
  account_name?: string | null;
@@ -1352,11 +1907,15 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1352
1907
  address_line1?: string | null;
1353
1908
  address_line2?: string | null;
1354
1909
  balance?: number | null;
1910
+ chamber_of_commerce?: string | null;
1355
1911
  city?: string | null;
1912
+ classification_description?: string | null;
1356
1913
  connection_id?: string;
1357
1914
  contact_name?: string | null;
1358
1915
  country?: string | null;
1916
+ created_at_exact?: string | null;
1359
1917
  credit_line?: number | null;
1918
+ currency?: string | null;
1360
1919
  data_raw?: import("../integrations/supabase/types").Json | null;
1361
1920
  email?: string | null;
1362
1921
  exact_id?: string;
@@ -1365,12 +1924,18 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1365
1924
  id?: string;
1366
1925
  is_sales?: boolean | null;
1367
1926
  is_supplier?: boolean | null;
1927
+ language?: string | null;
1928
+ modified_at_exact?: string | null;
1929
+ payment_condition_description?: string | null;
1930
+ payment_condition_sales?: string | null;
1368
1931
  phone?: string | null;
1369
1932
  postal_code?: string | null;
1933
+ remarks?: string | null;
1370
1934
  search_text?: string | null;
1371
1935
  status?: string | null;
1372
1936
  updated_at?: string;
1373
1937
  vat_number?: string | null;
1938
+ website?: string | null;
1374
1939
  };
1375
1940
  Relationships: [{
1376
1941
  foreignKeyName: "exact_customers_cache_connection_id_fkey";
@@ -1506,6 +2071,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1506
2071
  connection_id: string;
1507
2072
  data_raw: import("../integrations/supabase/types").Json | null;
1508
2073
  due_date: string | null;
2074
+ entry_id: string | null;
1509
2075
  exact_id: string;
1510
2076
  expires_at: string | null;
1511
2077
  fetched_at: string;
@@ -1531,6 +2097,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1531
2097
  connection_id: string;
1532
2098
  data_raw?: import("../integrations/supabase/types").Json | null;
1533
2099
  due_date?: string | null;
2100
+ entry_id?: string | null;
1534
2101
  exact_id: string;
1535
2102
  expires_at?: string | null;
1536
2103
  fetched_at?: string;
@@ -1556,6 +2123,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1556
2123
  connection_id?: string;
1557
2124
  data_raw?: import("../integrations/supabase/types").Json | null;
1558
2125
  due_date?: string | null;
2126
+ entry_id?: string | null;
1559
2127
  exact_id?: string;
1560
2128
  expires_at?: string | null;
1561
2129
  fetched_at?: string;
@@ -1632,6 +2200,63 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1632
2200
  referencedColumns: ["id"];
1633
2201
  }];
1634
2202
  };
2203
+ exact_refresh_locks: {
2204
+ Row: {
2205
+ environment: import("../integrations/supabase/types").Database["public"]["Enums"]["exact_env"];
2206
+ locked_by: string;
2207
+ locked_until: string;
2208
+ updated_at: string;
2209
+ };
2210
+ Insert: {
2211
+ environment: import("../integrations/supabase/types").Database["public"]["Enums"]["exact_env"];
2212
+ locked_by: string;
2213
+ locked_until: string;
2214
+ updated_at?: string;
2215
+ };
2216
+ Update: {
2217
+ environment?: import("../integrations/supabase/types").Database["public"]["Enums"]["exact_env"];
2218
+ locked_by?: string;
2219
+ locked_until?: string;
2220
+ updated_at?: string;
2221
+ };
2222
+ Relationships: [];
2223
+ };
2224
+ exact_settings: {
2225
+ Row: {
2226
+ client_id: string | null;
2227
+ client_secret: string | null;
2228
+ connection_status: string;
2229
+ created_at: string;
2230
+ division_id: string | null;
2231
+ id: string;
2232
+ last_sync_at: string | null;
2233
+ redirect_uri: string | null;
2234
+ updated_at: string;
2235
+ };
2236
+ Insert: {
2237
+ client_id?: string | null;
2238
+ client_secret?: string | null;
2239
+ connection_status?: string;
2240
+ created_at?: string;
2241
+ division_id?: string | null;
2242
+ id?: string;
2243
+ last_sync_at?: string | null;
2244
+ redirect_uri?: string | null;
2245
+ updated_at?: string;
2246
+ };
2247
+ Update: {
2248
+ client_id?: string | null;
2249
+ client_secret?: string | null;
2250
+ connection_status?: string;
2251
+ created_at?: string;
2252
+ division_id?: string | null;
2253
+ id?: string;
2254
+ last_sync_at?: string | null;
2255
+ redirect_uri?: string | null;
2256
+ updated_at?: string;
2257
+ };
2258
+ Relationships: [];
2259
+ };
1635
2260
  exact_sync_state: {
1636
2261
  Row: {
1637
2262
  connection_id: string;
@@ -1659,27 +2284,120 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1659
2284
  };
1660
2285
  Relationships: [];
1661
2286
  };
1662
- floricode_connection_settings: {
2287
+ external_customer_providers: {
1663
2288
  Row: {
1664
- catalog_key: string | null;
1665
- catalog_url: string;
2289
+ color: string | null;
1666
2290
  created_at: string;
1667
- id: number;
1668
- last_meta: import("../integrations/supabase/types").Json | null;
1669
- last_test_at: string | null;
1670
- last_test_error: string | null;
1671
- last_test_ok: boolean | null;
2291
+ icon: string | null;
2292
+ is_enabled: boolean;
2293
+ label: string;
2294
+ last_synced_at: string | null;
2295
+ provider: string;
2296
+ sort_order: number;
1672
2297
  updated_at: string;
1673
2298
  };
1674
2299
  Insert: {
1675
- catalog_key?: string | null;
1676
- catalog_url?: string;
2300
+ color?: string | null;
1677
2301
  created_at?: string;
1678
- id?: number;
1679
- last_meta?: import("../integrations/supabase/types").Json | null;
1680
- last_test_at?: string | null;
1681
- last_test_error?: string | null;
1682
- last_test_ok?: boolean | null;
2302
+ icon?: string | null;
2303
+ is_enabled?: boolean;
2304
+ label: string;
2305
+ last_synced_at?: string | null;
2306
+ provider: string;
2307
+ sort_order?: number;
2308
+ updated_at?: string;
2309
+ };
2310
+ Update: {
2311
+ color?: string | null;
2312
+ created_at?: string;
2313
+ icon?: string | null;
2314
+ is_enabled?: boolean;
2315
+ label?: string;
2316
+ last_synced_at?: string | null;
2317
+ provider?: string;
2318
+ sort_order?: number;
2319
+ updated_at?: string;
2320
+ };
2321
+ Relationships: [];
2322
+ };
2323
+ extra_categories: {
2324
+ Row: {
2325
+ created_at: string;
2326
+ id: string;
2327
+ name: string;
2328
+ sort_order: number;
2329
+ updated_at: string;
2330
+ };
2331
+ Insert: {
2332
+ created_at?: string;
2333
+ id?: string;
2334
+ name: string;
2335
+ sort_order?: number;
2336
+ updated_at?: string;
2337
+ };
2338
+ Update: {
2339
+ created_at?: string;
2340
+ id?: string;
2341
+ name?: string;
2342
+ sort_order?: number;
2343
+ updated_at?: string;
2344
+ };
2345
+ Relationships: [];
2346
+ };
2347
+ extras: {
2348
+ Row: {
2349
+ category: string;
2350
+ created_at: string;
2351
+ exact_article_id: string | null;
2352
+ id: string;
2353
+ is_active: boolean;
2354
+ name: string;
2355
+ price: number;
2356
+ pricing_type: string;
2357
+ };
2358
+ Insert: {
2359
+ category: string;
2360
+ created_at?: string;
2361
+ exact_article_id?: string | null;
2362
+ id?: string;
2363
+ is_active?: boolean;
2364
+ name: string;
2365
+ price?: number;
2366
+ pricing_type?: string;
2367
+ };
2368
+ Update: {
2369
+ category?: string;
2370
+ created_at?: string;
2371
+ exact_article_id?: string | null;
2372
+ id?: string;
2373
+ is_active?: boolean;
2374
+ name?: string;
2375
+ price?: number;
2376
+ pricing_type?: string;
2377
+ };
2378
+ Relationships: [];
2379
+ };
2380
+ floricode_connection_settings: {
2381
+ Row: {
2382
+ catalog_key: string | null;
2383
+ catalog_url: string;
2384
+ created_at: string;
2385
+ id: number;
2386
+ last_meta: import("../integrations/supabase/types").Json | null;
2387
+ last_test_at: string | null;
2388
+ last_test_error: string | null;
2389
+ last_test_ok: boolean | null;
2390
+ updated_at: string;
2391
+ };
2392
+ Insert: {
2393
+ catalog_key?: string | null;
2394
+ catalog_url?: string;
2395
+ created_at?: string;
2396
+ id?: number;
2397
+ last_meta?: import("../integrations/supabase/types").Json | null;
2398
+ last_test_at?: string | null;
2399
+ last_test_error?: string | null;
2400
+ last_test_ok?: boolean | null;
1683
2401
  updated_at?: string;
1684
2402
  };
1685
2403
  Update: {
@@ -1749,6 +2467,48 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1749
2467
  };
1750
2468
  Relationships: [];
1751
2469
  };
2470
+ floriday_carriers_cache: {
2471
+ Row: {
2472
+ connection_id: string | null;
2473
+ created_at: string;
2474
+ data: import("../integrations/supabase/types").Json;
2475
+ fetched_at: string;
2476
+ gln_code: string | null;
2477
+ id: string;
2478
+ name: string | null;
2479
+ organization_id: string;
2480
+ updated_at: string;
2481
+ };
2482
+ Insert: {
2483
+ connection_id?: string | null;
2484
+ created_at?: string;
2485
+ data: import("../integrations/supabase/types").Json;
2486
+ fetched_at?: string;
2487
+ gln_code?: string | null;
2488
+ id?: string;
2489
+ name?: string | null;
2490
+ organization_id: string;
2491
+ updated_at?: string;
2492
+ };
2493
+ Update: {
2494
+ connection_id?: string | null;
2495
+ created_at?: string;
2496
+ data?: import("../integrations/supabase/types").Json;
2497
+ fetched_at?: string;
2498
+ gln_code?: string | null;
2499
+ id?: string;
2500
+ name?: string | null;
2501
+ organization_id?: string;
2502
+ updated_at?: string;
2503
+ };
2504
+ Relationships: [{
2505
+ foreignKeyName: "floriday_carriers_cache_connection_id_fkey";
2506
+ columns: ["connection_id"];
2507
+ isOneToOne: false;
2508
+ referencedRelation: "floriday_connections";
2509
+ referencedColumns: ["id"];
2510
+ }];
2511
+ };
1752
2512
  floriday_connections: {
1753
2513
  Row: {
1754
2514
  access_token: string | null;
@@ -1806,6 +2566,48 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1806
2566
  };
1807
2567
  Relationships: [];
1808
2568
  };
2569
+ floriday_connections_cache: {
2570
+ Row: {
2571
+ buyer_organization_id: string | null;
2572
+ buyer_organization_name: string | null;
2573
+ connection_id: string;
2574
+ data: import("../integrations/supabase/types").Json;
2575
+ floriday_connection_id: string;
2576
+ is_deleted: boolean;
2577
+ sequence_number: number;
2578
+ status: string | null;
2579
+ synced_at: string;
2580
+ };
2581
+ Insert: {
2582
+ buyer_organization_id?: string | null;
2583
+ buyer_organization_name?: string | null;
2584
+ connection_id: string;
2585
+ data: import("../integrations/supabase/types").Json;
2586
+ floriday_connection_id: string;
2587
+ is_deleted?: boolean;
2588
+ sequence_number: number;
2589
+ status?: string | null;
2590
+ synced_at?: string;
2591
+ };
2592
+ Update: {
2593
+ buyer_organization_id?: string | null;
2594
+ buyer_organization_name?: string | null;
2595
+ connection_id?: string;
2596
+ data?: import("../integrations/supabase/types").Json;
2597
+ floriday_connection_id?: string;
2598
+ is_deleted?: boolean;
2599
+ sequence_number?: number;
2600
+ status?: string | null;
2601
+ synced_at?: string;
2602
+ };
2603
+ Relationships: [{
2604
+ foreignKeyName: "floriday_connections_cache_connection_id_fkey";
2605
+ columns: ["connection_id"];
2606
+ isOneToOne: false;
2607
+ referencedRelation: "floriday_connections";
2608
+ referencedColumns: ["id"];
2609
+ }];
2610
+ };
1809
2611
  floriday_customers_cache: {
1810
2612
  Row: {
1811
2613
  connection_id: string | null;
@@ -1890,6 +2692,48 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1890
2692
  };
1891
2693
  Relationships: [];
1892
2694
  };
2695
+ floriday_salesorders_cache: {
2696
+ Row: {
2697
+ buyer_organization_id: string | null;
2698
+ connection_id: string;
2699
+ created_at: string;
2700
+ data: import("../integrations/supabase/types").Json;
2701
+ floriday_id: string;
2702
+ is_deleted: boolean;
2703
+ sequence_number: number;
2704
+ status: string | null;
2705
+ updated_at: string;
2706
+ };
2707
+ Insert: {
2708
+ buyer_organization_id?: string | null;
2709
+ connection_id: string;
2710
+ created_at?: string;
2711
+ data: import("../integrations/supabase/types").Json;
2712
+ floriday_id: string;
2713
+ is_deleted?: boolean;
2714
+ sequence_number: number;
2715
+ status?: string | null;
2716
+ updated_at?: string;
2717
+ };
2718
+ Update: {
2719
+ buyer_organization_id?: string | null;
2720
+ connection_id?: string;
2721
+ created_at?: string;
2722
+ data?: import("../integrations/supabase/types").Json;
2723
+ floriday_id?: string;
2724
+ is_deleted?: boolean;
2725
+ sequence_number?: number;
2726
+ status?: string | null;
2727
+ updated_at?: string;
2728
+ };
2729
+ Relationships: [{
2730
+ foreignKeyName: "floriday_salesorders_cache_connection_id_fkey";
2731
+ columns: ["connection_id"];
2732
+ isOneToOne: false;
2733
+ referencedRelation: "floriday_connections";
2734
+ referencedColumns: ["id"];
2735
+ }];
2736
+ };
1893
2737
  floriday_settings: {
1894
2738
  Row: {
1895
2739
  active_environment: string;
@@ -1908,6 +2752,108 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
1908
2752
  };
1909
2753
  Relationships: [];
1910
2754
  };
2755
+ floriday_sync_state: {
2756
+ Row: {
2757
+ connection_id: string;
2758
+ entity_type: string;
2759
+ last_error: string | null;
2760
+ last_sequence_number: number;
2761
+ last_synced_at: string | null;
2762
+ updated_at: string;
2763
+ };
2764
+ Insert: {
2765
+ connection_id: string;
2766
+ entity_type: string;
2767
+ last_error?: string | null;
2768
+ last_sequence_number?: number;
2769
+ last_synced_at?: string | null;
2770
+ updated_at?: string;
2771
+ };
2772
+ Update: {
2773
+ connection_id?: string;
2774
+ entity_type?: string;
2775
+ last_error?: string | null;
2776
+ last_sequence_number?: number;
2777
+ last_synced_at?: string | null;
2778
+ updated_at?: string;
2779
+ };
2780
+ Relationships: [{
2781
+ foreignKeyName: "floriday_sync_state_connection_id_fkey";
2782
+ columns: ["connection_id"];
2783
+ isOneToOne: false;
2784
+ referencedRelation: "floriday_connections";
2785
+ referencedColumns: ["id"];
2786
+ }];
2787
+ };
2788
+ floriday_token_refresh_log: {
2789
+ Row: {
2790
+ attempted_at: string;
2791
+ connection_id: string | null;
2792
+ environment: string;
2793
+ error: string | null;
2794
+ expires_at: string | null;
2795
+ id: string;
2796
+ ok: boolean;
2797
+ };
2798
+ Insert: {
2799
+ attempted_at?: string;
2800
+ connection_id?: string | null;
2801
+ environment: string;
2802
+ error?: string | null;
2803
+ expires_at?: string | null;
2804
+ id?: string;
2805
+ ok: boolean;
2806
+ };
2807
+ Update: {
2808
+ attempted_at?: string;
2809
+ connection_id?: string | null;
2810
+ environment?: string;
2811
+ error?: string | null;
2812
+ expires_at?: string | null;
2813
+ id?: string;
2814
+ ok?: boolean;
2815
+ };
2816
+ Relationships: [{
2817
+ foreignKeyName: "floriday_token_refresh_log_connection_id_fkey";
2818
+ columns: ["connection_id"];
2819
+ isOneToOne: false;
2820
+ referencedRelation: "floriday_connections";
2821
+ referencedColumns: ["id"];
2822
+ }];
2823
+ };
2824
+ floriday_trade_items_cache: {
2825
+ Row: {
2826
+ connection_id: string;
2827
+ data: import("../integrations/supabase/types").Json;
2828
+ fetched_at: string;
2829
+ floriday_id: string;
2830
+ is_deleted: boolean;
2831
+ sequence_number: number;
2832
+ };
2833
+ Insert: {
2834
+ connection_id: string;
2835
+ data?: import("../integrations/supabase/types").Json;
2836
+ fetched_at?: string;
2837
+ floriday_id: string;
2838
+ is_deleted?: boolean;
2839
+ sequence_number?: number;
2840
+ };
2841
+ Update: {
2842
+ connection_id?: string;
2843
+ data?: import("../integrations/supabase/types").Json;
2844
+ fetched_at?: string;
2845
+ floriday_id?: string;
2846
+ is_deleted?: boolean;
2847
+ sequence_number?: number;
2848
+ };
2849
+ Relationships: [{
2850
+ foreignKeyName: "floriday_trade_items_cache_connection_id_fkey";
2851
+ columns: ["connection_id"];
2852
+ isOneToOne: false;
2853
+ referencedRelation: "floriday_connections";
2854
+ referencedColumns: ["id"];
2855
+ }];
2856
+ };
1911
2857
  imap_accounts: {
1912
2858
  Row: {
1913
2859
  created_at: string;
@@ -2082,7 +3028,103 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2082
3028
  };
2083
3029
  Relationships: [];
2084
3030
  };
2085
- locations: {
3031
+ invoice_run_items: {
3032
+ Row: {
3033
+ booking_id: string | null;
3034
+ company_name: string | null;
3035
+ created_at: string;
3036
+ customer_email: string | null;
3037
+ description: string | null;
3038
+ exact_article_id: string | null;
3039
+ id: string;
3040
+ invoice_run_id: string | null;
3041
+ quantity: number | null;
3042
+ total_excl_vat: number | null;
3043
+ total_incl_vat: number | null;
3044
+ unit_price: number | null;
3045
+ vat_amount: number | null;
3046
+ };
3047
+ Insert: {
3048
+ booking_id?: string | null;
3049
+ company_name?: string | null;
3050
+ created_at?: string;
3051
+ customer_email?: string | null;
3052
+ description?: string | null;
3053
+ exact_article_id?: string | null;
3054
+ id?: string;
3055
+ invoice_run_id?: string | null;
3056
+ quantity?: number | null;
3057
+ total_excl_vat?: number | null;
3058
+ total_incl_vat?: number | null;
3059
+ unit_price?: number | null;
3060
+ vat_amount?: number | null;
3061
+ };
3062
+ Update: {
3063
+ booking_id?: string | null;
3064
+ company_name?: string | null;
3065
+ created_at?: string;
3066
+ customer_email?: string | null;
3067
+ description?: string | null;
3068
+ exact_article_id?: string | null;
3069
+ id?: string;
3070
+ invoice_run_id?: string | null;
3071
+ quantity?: number | null;
3072
+ total_excl_vat?: number | null;
3073
+ total_incl_vat?: number | null;
3074
+ unit_price?: number | null;
3075
+ vat_amount?: number | null;
3076
+ };
3077
+ Relationships: [{
3078
+ foreignKeyName: "invoice_run_items_booking_id_fkey";
3079
+ columns: ["booking_id"];
3080
+ isOneToOne: false;
3081
+ referencedRelation: "bookings";
3082
+ referencedColumns: ["id"];
3083
+ }, {
3084
+ foreignKeyName: "invoice_run_items_invoice_run_id_fkey";
3085
+ columns: ["invoice_run_id"];
3086
+ isOneToOne: false;
3087
+ referencedRelation: "invoice_runs";
3088
+ referencedColumns: ["id"];
3089
+ }];
3090
+ };
3091
+ invoice_runs: {
3092
+ Row: {
3093
+ created_at: string;
3094
+ created_by: string | null;
3095
+ id: string;
3096
+ period_end: string;
3097
+ period_start: string;
3098
+ status: string;
3099
+ total_excl_vat: number | null;
3100
+ total_incl_vat: number | null;
3101
+ vat_amount: number | null;
3102
+ };
3103
+ Insert: {
3104
+ created_at?: string;
3105
+ created_by?: string | null;
3106
+ id?: string;
3107
+ period_end: string;
3108
+ period_start: string;
3109
+ status?: string;
3110
+ total_excl_vat?: number | null;
3111
+ total_incl_vat?: number | null;
3112
+ vat_amount?: number | null;
3113
+ };
3114
+ Update: {
3115
+ created_at?: string;
3116
+ created_by?: string | null;
3117
+ id?: string;
3118
+ period_end?: string;
3119
+ period_start?: string;
3120
+ status?: string;
3121
+ total_excl_vat?: number | null;
3122
+ total_incl_vat?: number | null;
3123
+ vat_amount?: number | null;
3124
+ };
3125
+ Relationships: [];
3126
+ };
3127
+ locations: {
2086
3128
  Row: {
2087
3129
  created_at: string;
2088
3130
  id: string;
@@ -2112,6 +3154,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2112
3154
  body_text: string | null;
2113
3155
  created_at: string;
2114
3156
  error_message: string | null;
3157
+ external_id: string | null;
2115
3158
  from_email: string | null;
2116
3159
  from_name: string | null;
2117
3160
  id: string;
@@ -2121,7 +3164,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2121
3164
  received_at: string | null;
2122
3165
  status: string;
2123
3166
  subject: string | null;
2124
- uid: number;
3167
+ uid: number | null;
2125
3168
  updated_at: string;
2126
3169
  };
2127
3170
  Insert: {
@@ -2129,6 +3172,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2129
3172
  body_text?: string | null;
2130
3173
  created_at?: string;
2131
3174
  error_message?: string | null;
3175
+ external_id?: string | null;
2132
3176
  from_email?: string | null;
2133
3177
  from_name?: string | null;
2134
3178
  id?: string;
@@ -2138,7 +3182,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2138
3182
  received_at?: string | null;
2139
3183
  status?: string;
2140
3184
  subject?: string | null;
2141
- uid: number;
3185
+ uid?: number | null;
2142
3186
  updated_at?: string;
2143
3187
  };
2144
3188
  Update: {
@@ -2146,6 +3190,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2146
3190
  body_text?: string | null;
2147
3191
  created_at?: string;
2148
3192
  error_message?: string | null;
3193
+ external_id?: string | null;
2149
3194
  from_email?: string | null;
2150
3195
  from_name?: string | null;
2151
3196
  id?: string;
@@ -2155,7 +3200,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2155
3200
  received_at?: string | null;
2156
3201
  status?: string;
2157
3202
  subject?: string | null;
2158
- uid?: number;
3203
+ uid?: number | null;
2159
3204
  updated_at?: string;
2160
3205
  };
2161
3206
  Relationships: [{
@@ -2427,6 +3472,60 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
2427
3472
  };
2428
3473
  Relationships: [];
2429
3474
  };
3475
+ monteurs: {
3476
+ Row: {
3477
+ avatar_url: string | null;
3478
+ color: string | null;
3479
+ created_at: string;
3480
+ email: string | null;
3481
+ id: string;
3482
+ is_active: boolean;
3483
+ leave_balance_hours: number;
3484
+ name: string;
3485
+ persnr: number | null;
3486
+ phone: string | null;
3487
+ role: string;
3488
+ tenant_id: string;
3489
+ updated_at: string;
3490
+ };
3491
+ Insert: {
3492
+ avatar_url?: string | null;
3493
+ color?: string | null;
3494
+ created_at?: string;
3495
+ email?: string | null;
3496
+ id?: string;
3497
+ is_active?: boolean;
3498
+ leave_balance_hours?: number;
3499
+ name: string;
3500
+ persnr?: number | null;
3501
+ phone?: string | null;
3502
+ role?: string;
3503
+ tenant_id: string;
3504
+ updated_at?: string;
3505
+ };
3506
+ Update: {
3507
+ avatar_url?: string | null;
3508
+ color?: string | null;
3509
+ created_at?: string;
3510
+ email?: string | null;
3511
+ id?: string;
3512
+ is_active?: boolean;
3513
+ leave_balance_hours?: number;
3514
+ name?: string;
3515
+ persnr?: number | null;
3516
+ phone?: string | null;
3517
+ role?: string;
3518
+ tenant_id?: string;
3519
+ updated_at?: string;
3520
+ };
3521
+ Relationships: [{
3522
+ foreignKeyName: "monteurs_tenant_id_fkey";
3523
+ columns: ["tenant_id"];
3524
+ isOneToOne: false;
3525
+ referencedRelation: "tenants";
3526
+ referencedColumns: ["id"];
3527
+ }];
3528
+ };
2430
3529
  notifications: {
2431
3530
  Row: {
2432
3531
  created_at: string;
@@ -3259,6 +4358,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3259
4358
  email: string | null;
3260
4359
  id: string;
3261
4360
  notification_preferences: import("../integrations/supabase/types").Json;
4361
+ tenant_id: string | null;
3262
4362
  updated_at: string;
3263
4363
  };
3264
4364
  Insert: {
@@ -3267,6 +4367,7 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3267
4367
  email?: string | null;
3268
4368
  id: string;
3269
4369
  notification_preferences?: import("../integrations/supabase/types").Json;
4370
+ tenant_id?: string | null;
3270
4371
  updated_at?: string;
3271
4372
  };
3272
4373
  Update: {
@@ -3275,9 +4376,16 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3275
4376
  email?: string | null;
3276
4377
  id?: string;
3277
4378
  notification_preferences?: import("../integrations/supabase/types").Json;
4379
+ tenant_id?: string | null;
3278
4380
  updated_at?: string;
3279
4381
  };
3280
- Relationships: [];
4382
+ Relationships: [{
4383
+ foreignKeyName: "profiles_tenant_id_fkey";
4384
+ columns: ["tenant_id"];
4385
+ isOneToOne: false;
4386
+ referencedRelation: "tenants";
4387
+ referencedColumns: ["id"];
4388
+ }];
3281
4389
  };
3282
4390
  projects: {
3283
4391
  Row: {
@@ -3537,233 +4645,1695 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3537
4645
  referencedColumns: ["id"];
3538
4646
  }];
3539
4647
  };
3540
- quote_items: {
4648
+ quote_activities: {
3541
4649
  Row: {
3542
4650
  created_at: string;
3543
- description: string;
4651
+ event_type: string;
3544
4652
  id: string;
3545
- quantity: number;
4653
+ metadata: import("../integrations/supabase/types").Json;
3546
4654
  quote_id: string;
3547
- sort_order: number;
3548
- unit_price: number;
4655
+ user_id: string | null;
3549
4656
  };
3550
4657
  Insert: {
3551
4658
  created_at?: string;
3552
- description?: string;
4659
+ event_type: string;
3553
4660
  id?: string;
3554
- quantity?: number;
4661
+ metadata?: import("../integrations/supabase/types").Json;
3555
4662
  quote_id: string;
3556
- sort_order?: number;
3557
- unit_price?: number;
4663
+ user_id?: string | null;
3558
4664
  };
3559
4665
  Update: {
3560
4666
  created_at?: string;
3561
- description?: string;
4667
+ event_type?: string;
3562
4668
  id?: string;
3563
- quantity?: number;
4669
+ metadata?: import("../integrations/supabase/types").Json;
3564
4670
  quote_id?: string;
3565
- sort_order?: number;
3566
- unit_price?: number;
4671
+ user_id?: string | null;
3567
4672
  };
3568
4673
  Relationships: [{
3569
- foreignKeyName: "quote_items_quote_id_fkey";
4674
+ foreignKeyName: "quote_activities_quote_id_fkey";
3570
4675
  columns: ["quote_id"];
3571
4676
  isOneToOne: false;
3572
4677
  referencedRelation: "quotes";
3573
4678
  referencedColumns: ["id"];
3574
4679
  }];
3575
4680
  };
3576
- quotes: {
4681
+ quote_attachments: {
3577
4682
  Row: {
3578
4683
  created_at: string;
4684
+ file_name: string;
4685
+ file_size: number | null;
4686
+ file_url: string;
3579
4687
  id: string;
3580
- notes: string | null;
3581
- prospect_id: string | null;
3582
- quote_number: string | null;
3583
- status: string;
3584
- title: string;
3585
- updated_at: string;
3586
- valid_until: string | null;
4688
+ mime_type: string | null;
4689
+ quote_id: string;
3587
4690
  };
3588
4691
  Insert: {
3589
4692
  created_at?: string;
4693
+ file_name: string;
4694
+ file_size?: number | null;
4695
+ file_url: string;
3590
4696
  id?: string;
3591
- notes?: string | null;
3592
- prospect_id?: string | null;
3593
- quote_number?: string | null;
3594
- status?: string;
3595
- title?: string;
3596
- updated_at?: string;
3597
- valid_until?: string | null;
4697
+ mime_type?: string | null;
4698
+ quote_id: string;
3598
4699
  };
3599
4700
  Update: {
3600
4701
  created_at?: string;
4702
+ file_name?: string;
4703
+ file_size?: number | null;
4704
+ file_url?: string;
3601
4705
  id?: string;
3602
- notes?: string | null;
3603
- prospect_id?: string | null;
3604
- quote_number?: string | null;
3605
- status?: string;
3606
- title?: string;
3607
- updated_at?: string;
3608
- valid_until?: string | null;
4706
+ mime_type?: string | null;
4707
+ quote_id?: string;
3609
4708
  };
3610
4709
  Relationships: [{
3611
- foreignKeyName: "quotes_prospect_id_fkey";
3612
- columns: ["prospect_id"];
4710
+ foreignKeyName: "quote_attachments_quote_id_fkey";
4711
+ columns: ["quote_id"];
3613
4712
  isOneToOne: false;
3614
- referencedRelation: "prospects";
4713
+ referencedRelation: "quotes";
3615
4714
  referencedColumns: ["id"];
3616
4715
  }];
3617
4716
  };
3618
- supplier_products: {
4717
+ quote_field_options: {
3619
4718
  Row: {
3620
- article_number: string | null;
3621
4719
  created_at: string;
4720
+ field_id: string;
3622
4721
  id: string;
3623
- name: string;
3624
- notes: string | null;
3625
- pot_size: string | null;
3626
- price: number | null;
3627
- quantity: number | null;
3628
- supplier_id: string;
3629
- unit: string;
3630
- updated_at: string;
4722
+ label: string;
4723
+ sort_order: number;
4724
+ value: string;
3631
4725
  };
3632
4726
  Insert: {
3633
- article_number?: string | null;
3634
4727
  created_at?: string;
4728
+ field_id: string;
3635
4729
  id?: string;
3636
- name: string;
3637
- notes?: string | null;
3638
- pot_size?: string | null;
3639
- price?: number | null;
3640
- quantity?: number | null;
3641
- supplier_id: string;
3642
- unit?: string;
3643
- updated_at?: string;
4730
+ label: string;
4731
+ sort_order?: number;
4732
+ value: string;
3644
4733
  };
3645
4734
  Update: {
3646
- article_number?: string | null;
3647
4735
  created_at?: string;
4736
+ field_id?: string;
3648
4737
  id?: string;
3649
- name?: string;
3650
- notes?: string | null;
3651
- pot_size?: string | null;
3652
- price?: number | null;
3653
- quantity?: number | null;
3654
- supplier_id?: string;
3655
- unit?: string;
3656
- updated_at?: string;
4738
+ label?: string;
4739
+ sort_order?: number;
4740
+ value?: string;
3657
4741
  };
3658
4742
  Relationships: [{
3659
- foreignKeyName: "supplier_products_supplier_id_fkey";
3660
- columns: ["supplier_id"];
4743
+ foreignKeyName: "quote_field_options_field_id_fkey";
4744
+ columns: ["field_id"];
3661
4745
  isOneToOne: false;
3662
- referencedRelation: "suppliers";
4746
+ referencedRelation: "quote_field_settings";
3663
4747
  referencedColumns: ["id"];
3664
4748
  }];
3665
4749
  };
3666
- suppliers: {
4750
+ quote_field_settings: {
3667
4751
  Row: {
3668
- address: string | null;
3669
- column_mappings: import("../integrations/supabase/types").Json | null;
3670
- contact_person: string | null;
3671
4752
  created_at: string;
3672
- default_product_type: string;
3673
- email: string | null;
4753
+ default_value: string | null;
4754
+ field_key: string;
4755
+ field_type: string;
3674
4756
  id: string;
3675
- imported_file_name: string | null;
3676
- name: string;
3677
- notes: string | null;
3678
- phone: string | null;
4757
+ is_system: boolean;
4758
+ label: string;
4759
+ required: boolean;
4760
+ sort_order: number;
3679
4761
  updated_at: string;
4762
+ visible: boolean;
3680
4763
  };
3681
4764
  Insert: {
3682
- address?: string | null;
3683
- column_mappings?: import("../integrations/supabase/types").Json | null;
3684
- contact_person?: string | null;
3685
4765
  created_at?: string;
3686
- default_product_type?: string;
3687
- email?: string | null;
4766
+ default_value?: string | null;
4767
+ field_key: string;
4768
+ field_type: string;
3688
4769
  id?: string;
3689
- imported_file_name?: string | null;
3690
- name: string;
3691
- notes?: string | null;
3692
- phone?: string | null;
4770
+ is_system?: boolean;
4771
+ label: string;
4772
+ required?: boolean;
4773
+ sort_order?: number;
3693
4774
  updated_at?: string;
4775
+ visible?: boolean;
3694
4776
  };
3695
4777
  Update: {
3696
- address?: string | null;
3697
- column_mappings?: import("../integrations/supabase/types").Json | null;
3698
- contact_person?: string | null;
3699
4778
  created_at?: string;
3700
- default_product_type?: string;
3701
- email?: string | null;
4779
+ default_value?: string | null;
4780
+ field_key?: string;
4781
+ field_type?: string;
3702
4782
  id?: string;
3703
- imported_file_name?: string | null;
3704
- name?: string;
3705
- notes?: string | null;
3706
- phone?: string | null;
4783
+ is_system?: boolean;
4784
+ label?: string;
4785
+ required?: boolean;
4786
+ sort_order?: number;
3707
4787
  updated_at?: string;
4788
+ visible?: boolean;
3708
4789
  };
3709
4790
  Relationships: [];
3710
4791
  };
3711
- trade_item_drafts: {
4792
+ quote_items: {
3712
4793
  Row: {
3713
- connection_id: string | null;
4794
+ category: string | null;
3714
4795
  created_at: string;
3715
- data: import("../integrations/supabase/types").Json;
4796
+ description: string;
3716
4797
  id: string;
3717
- updated_at: string;
3718
- user_id: string;
4798
+ line_total: number;
4799
+ module_id: string | null;
4800
+ name: string | null;
4801
+ quantity: number;
4802
+ quote_id: string;
4803
+ sort_order: number;
4804
+ unit_price: number;
3719
4805
  };
3720
4806
  Insert: {
3721
- connection_id?: string | null;
4807
+ category?: string | null;
3722
4808
  created_at?: string;
3723
- data?: import("../integrations/supabase/types").Json;
4809
+ description?: string;
3724
4810
  id?: string;
3725
- updated_at?: string;
3726
- user_id: string;
4811
+ line_total?: number;
4812
+ module_id?: string | null;
4813
+ name?: string | null;
4814
+ quantity?: number;
4815
+ quote_id: string;
4816
+ sort_order?: number;
4817
+ unit_price?: number;
3727
4818
  };
3728
4819
  Update: {
3729
- connection_id?: string | null;
4820
+ category?: string | null;
3730
4821
  created_at?: string;
3731
- data?: import("../integrations/supabase/types").Json;
4822
+ description?: string;
3732
4823
  id?: string;
3733
- updated_at?: string;
4824
+ line_total?: number;
4825
+ module_id?: string | null;
4826
+ name?: string | null;
4827
+ quantity?: number;
4828
+ quote_id?: string;
4829
+ sort_order?: number;
4830
+ unit_price?: number;
4831
+ };
4832
+ Relationships: [{
4833
+ foreignKeyName: "quote_items_module_id_fkey";
4834
+ columns: ["module_id"];
4835
+ isOneToOne: false;
4836
+ referencedRelation: "quote_modules";
4837
+ referencedColumns: ["id"];
4838
+ }, {
4839
+ foreignKeyName: "quote_items_quote_id_fkey";
4840
+ columns: ["quote_id"];
4841
+ isOneToOne: false;
4842
+ referencedRelation: "quotes";
4843
+ referencedColumns: ["id"];
4844
+ }];
4845
+ };
4846
+ quote_modules: {
4847
+ Row: {
4848
+ category: string | null;
4849
+ created_at: string;
4850
+ description: string | null;
4851
+ id: string;
4852
+ is_active: boolean;
4853
+ name: string;
4854
+ price: number;
4855
+ sort_order: number;
4856
+ updated_at: string;
4857
+ };
4858
+ Insert: {
4859
+ category?: string | null;
4860
+ created_at?: string;
4861
+ description?: string | null;
4862
+ id?: string;
4863
+ is_active?: boolean;
4864
+ name: string;
4865
+ price?: number;
4866
+ sort_order?: number;
4867
+ updated_at?: string;
4868
+ };
4869
+ Update: {
4870
+ category?: string | null;
4871
+ created_at?: string;
4872
+ description?: string | null;
4873
+ id?: string;
4874
+ is_active?: boolean;
4875
+ name?: string;
4876
+ price?: number;
4877
+ sort_order?: number;
4878
+ updated_at?: string;
4879
+ };
4880
+ Relationships: [];
4881
+ };
4882
+ quote_templates: {
4883
+ Row: {
4884
+ created_at: string;
4885
+ description: string | null;
4886
+ field_values: import("../integrations/supabase/types").Json;
4887
+ id: string;
4888
+ is_default: boolean;
4889
+ items: import("../integrations/supabase/types").Json;
4890
+ name: string;
4891
+ updated_at: string;
4892
+ vat_rate: number;
4893
+ };
4894
+ Insert: {
4895
+ created_at?: string;
4896
+ description?: string | null;
4897
+ field_values?: import("../integrations/supabase/types").Json;
4898
+ id?: string;
4899
+ is_default?: boolean;
4900
+ items?: import("../integrations/supabase/types").Json;
4901
+ name: string;
4902
+ updated_at?: string;
4903
+ vat_rate?: number;
4904
+ };
4905
+ Update: {
4906
+ created_at?: string;
4907
+ description?: string | null;
4908
+ field_values?: import("../integrations/supabase/types").Json;
4909
+ id?: string;
4910
+ is_default?: boolean;
4911
+ items?: import("../integrations/supabase/types").Json;
4912
+ name?: string;
4913
+ updated_at?: string;
4914
+ vat_rate?: number;
4915
+ };
4916
+ Relationships: [];
4917
+ };
4918
+ quote_terms: {
4919
+ Row: {
4920
+ content: string | null;
4921
+ created_at: string;
4922
+ file_url: string | null;
4923
+ id: string;
4924
+ is_active: boolean;
4925
+ name: string;
4926
+ published_at: string | null;
4927
+ updated_at: string;
4928
+ version: string;
4929
+ };
4930
+ Insert: {
4931
+ content?: string | null;
4932
+ created_at?: string;
4933
+ file_url?: string | null;
4934
+ id?: string;
4935
+ is_active?: boolean;
4936
+ name: string;
4937
+ published_at?: string | null;
4938
+ updated_at?: string;
4939
+ version?: string;
4940
+ };
4941
+ Update: {
4942
+ content?: string | null;
4943
+ created_at?: string;
4944
+ file_url?: string | null;
4945
+ id?: string;
4946
+ is_active?: boolean;
4947
+ name?: string;
4948
+ published_at?: string | null;
4949
+ updated_at?: string;
4950
+ version?: string;
4951
+ };
4952
+ Relationships: [];
4953
+ };
4954
+ quotes: {
4955
+ Row: {
4956
+ accepted_at: string | null;
4957
+ archived_at: string | null;
4958
+ contact_id: string | null;
4959
+ created_at: string;
4960
+ customer_id: string | null;
4961
+ discount: number;
4962
+ expires_at: string | null;
4963
+ field_values: import("../integrations/supabase/types").Json;
4964
+ id: string;
4965
+ notes: string | null;
4966
+ owner_id: string | null;
4967
+ personal_message: string | null;
4968
+ project_id: string | null;
4969
+ prospect_id: string | null;
4970
+ public_token: string;
4971
+ quote_number: string | null;
4972
+ recipient_email: string | null;
4973
+ recipient_name: string | null;
4974
+ rejected_at: string | null;
4975
+ sent_at: string | null;
4976
+ status: string;
4977
+ subtotal: number;
4978
+ template_id: string | null;
4979
+ terms_id: string | null;
4980
+ title: string;
4981
+ total: number;
4982
+ updated_at: string;
4983
+ valid_until: string | null;
4984
+ vat_amount: number;
4985
+ vat_rate: number;
4986
+ viewed_at: string | null;
4987
+ };
4988
+ Insert: {
4989
+ accepted_at?: string | null;
4990
+ archived_at?: string | null;
4991
+ contact_id?: string | null;
4992
+ created_at?: string;
4993
+ customer_id?: string | null;
4994
+ discount?: number;
4995
+ expires_at?: string | null;
4996
+ field_values?: import("../integrations/supabase/types").Json;
4997
+ id?: string;
4998
+ notes?: string | null;
4999
+ owner_id?: string | null;
5000
+ personal_message?: string | null;
5001
+ project_id?: string | null;
5002
+ prospect_id?: string | null;
5003
+ public_token?: string;
5004
+ quote_number?: string | null;
5005
+ recipient_email?: string | null;
5006
+ recipient_name?: string | null;
5007
+ rejected_at?: string | null;
5008
+ sent_at?: string | null;
5009
+ status?: string;
5010
+ subtotal?: number;
5011
+ template_id?: string | null;
5012
+ terms_id?: string | null;
5013
+ title?: string;
5014
+ total?: number;
5015
+ updated_at?: string;
5016
+ valid_until?: string | null;
5017
+ vat_amount?: number;
5018
+ vat_rate?: number;
5019
+ viewed_at?: string | null;
5020
+ };
5021
+ Update: {
5022
+ accepted_at?: string | null;
5023
+ archived_at?: string | null;
5024
+ contact_id?: string | null;
5025
+ created_at?: string;
5026
+ customer_id?: string | null;
5027
+ discount?: number;
5028
+ expires_at?: string | null;
5029
+ field_values?: import("../integrations/supabase/types").Json;
5030
+ id?: string;
5031
+ notes?: string | null;
5032
+ owner_id?: string | null;
5033
+ personal_message?: string | null;
5034
+ project_id?: string | null;
5035
+ prospect_id?: string | null;
5036
+ public_token?: string;
5037
+ quote_number?: string | null;
5038
+ recipient_email?: string | null;
5039
+ recipient_name?: string | null;
5040
+ rejected_at?: string | null;
5041
+ sent_at?: string | null;
5042
+ status?: string;
5043
+ subtotal?: number;
5044
+ template_id?: string | null;
5045
+ terms_id?: string | null;
5046
+ title?: string;
5047
+ total?: number;
5048
+ updated_at?: string;
5049
+ valid_until?: string | null;
5050
+ vat_amount?: number;
5051
+ vat_rate?: number;
5052
+ viewed_at?: string | null;
5053
+ };
5054
+ Relationships: [{
5055
+ foreignKeyName: "quotes_contact_id_fkey";
5056
+ columns: ["contact_id"];
5057
+ isOneToOne: false;
5058
+ referencedRelation: "customer_contacts";
5059
+ referencedColumns: ["id"];
5060
+ }, {
5061
+ foreignKeyName: "quotes_customer_id_fkey";
5062
+ columns: ["customer_id"];
5063
+ isOneToOne: false;
5064
+ referencedRelation: "customers";
5065
+ referencedColumns: ["id"];
5066
+ }, {
5067
+ foreignKeyName: "quotes_project_id_fkey";
5068
+ columns: ["project_id"];
5069
+ isOneToOne: false;
5070
+ referencedRelation: "projects";
5071
+ referencedColumns: ["id"];
5072
+ }, {
5073
+ foreignKeyName: "quotes_prospect_id_fkey";
5074
+ columns: ["prospect_id"];
5075
+ isOneToOne: false;
5076
+ referencedRelation: "prospects";
5077
+ referencedColumns: ["id"];
5078
+ }, {
5079
+ foreignKeyName: "quotes_template_id_fkey";
5080
+ columns: ["template_id"];
5081
+ isOneToOne: false;
5082
+ referencedRelation: "quote_templates";
5083
+ referencedColumns: ["id"];
5084
+ }, {
5085
+ foreignKeyName: "quotes_terms_id_fkey";
5086
+ columns: ["terms_id"];
5087
+ isOneToOne: false;
5088
+ referencedRelation: "quote_terms";
5089
+ referencedColumns: ["id"];
5090
+ }];
5091
+ };
5092
+ reception_notifications: {
5093
+ Row: {
5094
+ booking_id: string | null;
5095
+ created_at: string;
5096
+ id: string;
5097
+ is_read: boolean;
5098
+ message: string;
5099
+ recipient_email: string | null;
5100
+ title: string;
5101
+ type: string;
5102
+ };
5103
+ Insert: {
5104
+ booking_id?: string | null;
5105
+ created_at?: string;
5106
+ id?: string;
5107
+ is_read?: boolean;
5108
+ message: string;
5109
+ recipient_email?: string | null;
5110
+ title: string;
5111
+ type: string;
5112
+ };
5113
+ Update: {
5114
+ booking_id?: string | null;
5115
+ created_at?: string;
5116
+ id?: string;
5117
+ is_read?: boolean;
5118
+ message?: string;
5119
+ recipient_email?: string | null;
5120
+ title?: string;
5121
+ type?: string;
5122
+ };
5123
+ Relationships: [{
5124
+ foreignKeyName: "reception_notifications_booking_id_fkey";
5125
+ columns: ["booking_id"];
5126
+ isOneToOne: false;
5127
+ referencedRelation: "bookings";
5128
+ referencedColumns: ["id"];
5129
+ }];
5130
+ };
5131
+ rooms: {
5132
+ Row: {
5133
+ capacity: number;
5134
+ color_code: string | null;
5135
+ created_at: string;
5136
+ description: string | null;
5137
+ hourly_rate: number;
5138
+ id: string;
5139
+ image_url: string | null;
5140
+ is_active: boolean;
5141
+ name: string;
5142
+ };
5143
+ Insert: {
5144
+ capacity?: number;
5145
+ color_code?: string | null;
5146
+ created_at?: string;
5147
+ description?: string | null;
5148
+ hourly_rate?: number;
5149
+ id?: string;
5150
+ image_url?: string | null;
5151
+ is_active?: boolean;
5152
+ name: string;
5153
+ };
5154
+ Update: {
5155
+ capacity?: number;
5156
+ color_code?: string | null;
5157
+ created_at?: string;
5158
+ description?: string | null;
5159
+ hourly_rate?: number;
5160
+ id?: string;
5161
+ image_url?: string | null;
5162
+ is_active?: boolean;
5163
+ name?: string;
5164
+ };
5165
+ Relationships: [];
5166
+ };
5167
+ supplier_products: {
5168
+ Row: {
5169
+ article_number: string | null;
5170
+ created_at: string;
5171
+ id: string;
5172
+ name: string;
5173
+ notes: string | null;
5174
+ pot_size: string | null;
5175
+ price: number | null;
5176
+ quantity: number | null;
5177
+ supplier_id: string;
5178
+ unit: string;
5179
+ updated_at: string;
5180
+ };
5181
+ Insert: {
5182
+ article_number?: string | null;
5183
+ created_at?: string;
5184
+ id?: string;
5185
+ name: string;
5186
+ notes?: string | null;
5187
+ pot_size?: string | null;
5188
+ price?: number | null;
5189
+ quantity?: number | null;
5190
+ supplier_id: string;
5191
+ unit?: string;
5192
+ updated_at?: string;
5193
+ };
5194
+ Update: {
5195
+ article_number?: string | null;
5196
+ created_at?: string;
5197
+ id?: string;
5198
+ name?: string;
5199
+ notes?: string | null;
5200
+ pot_size?: string | null;
5201
+ price?: number | null;
5202
+ quantity?: number | null;
5203
+ supplier_id?: string;
5204
+ unit?: string;
5205
+ updated_at?: string;
5206
+ };
5207
+ Relationships: [{
5208
+ foreignKeyName: "supplier_products_supplier_id_fkey";
5209
+ columns: ["supplier_id"];
5210
+ isOneToOne: false;
5211
+ referencedRelation: "suppliers";
5212
+ referencedColumns: ["id"];
5213
+ }];
5214
+ };
5215
+ suppliers: {
5216
+ Row: {
5217
+ address: string | null;
5218
+ column_mappings: import("../integrations/supabase/types").Json | null;
5219
+ contact_person: string | null;
5220
+ created_at: string;
5221
+ default_product_type: string;
5222
+ email: string | null;
5223
+ id: string;
5224
+ imported_file_name: string | null;
5225
+ name: string;
5226
+ notes: string | null;
5227
+ phone: string | null;
5228
+ updated_at: string;
5229
+ };
5230
+ Insert: {
5231
+ address?: string | null;
5232
+ column_mappings?: import("../integrations/supabase/types").Json | null;
5233
+ contact_person?: string | null;
5234
+ created_at?: string;
5235
+ default_product_type?: string;
5236
+ email?: string | null;
5237
+ id?: string;
5238
+ imported_file_name?: string | null;
5239
+ name: string;
5240
+ notes?: string | null;
5241
+ phone?: string | null;
5242
+ updated_at?: string;
5243
+ };
5244
+ Update: {
5245
+ address?: string | null;
5246
+ column_mappings?: import("../integrations/supabase/types").Json | null;
5247
+ contact_person?: string | null;
5248
+ created_at?: string;
5249
+ default_product_type?: string;
5250
+ email?: string | null;
5251
+ id?: string;
5252
+ imported_file_name?: string | null;
5253
+ name?: string;
5254
+ notes?: string | null;
5255
+ phone?: string | null;
5256
+ updated_at?: string;
5257
+ };
5258
+ Relationships: [];
5259
+ };
5260
+ tenants: {
5261
+ Row: {
5262
+ created_at: string;
5263
+ id: string;
5264
+ name: string;
5265
+ slug: string | null;
5266
+ updated_at: string;
5267
+ };
5268
+ Insert: {
5269
+ created_at?: string;
5270
+ id?: string;
5271
+ name?: string;
5272
+ slug?: string | null;
5273
+ updated_at?: string;
5274
+ };
5275
+ Update: {
5276
+ created_at?: string;
5277
+ id?: string;
5278
+ name?: string;
5279
+ slug?: string | null;
5280
+ updated_at?: string;
5281
+ };
5282
+ Relationships: [];
5283
+ };
5284
+ trade_item_drafts: {
5285
+ Row: {
5286
+ connection_id: string | null;
5287
+ created_at: string;
5288
+ data: import("../integrations/supabase/types").Json;
5289
+ id: string;
5290
+ updated_at: string;
5291
+ user_id: string;
5292
+ };
5293
+ Insert: {
5294
+ connection_id?: string | null;
5295
+ created_at?: string;
5296
+ data?: import("../integrations/supabase/types").Json;
5297
+ id?: string;
5298
+ updated_at?: string;
5299
+ user_id: string;
5300
+ };
5301
+ Update: {
5302
+ connection_id?: string | null;
5303
+ created_at?: string;
5304
+ data?: import("../integrations/supabase/types").Json;
5305
+ id?: string;
5306
+ updated_at?: string;
5307
+ user_id?: string;
5308
+ };
5309
+ Relationships: [];
5310
+ };
5311
+ twinfield_connections: {
5312
+ Row: {
5313
+ access_token: string | null;
5314
+ client_id: string;
5315
+ client_secret: string | null;
5316
+ cluster_uri: string | null;
5317
+ company_code: string | null;
5318
+ company_name: string | null;
5319
+ connected_at: string | null;
5320
+ created_at: string;
5321
+ environment: string;
5322
+ id: string;
5323
+ is_active: boolean;
5324
+ label: string | null;
5325
+ office_code: string | null;
5326
+ redirect_uri: string;
5327
+ refresh_token: string | null;
5328
+ token_expires_at: string | null;
5329
+ updated_at: string;
5330
+ user_id: string;
5331
+ };
5332
+ Insert: {
5333
+ access_token?: string | null;
5334
+ client_id: string;
5335
+ client_secret?: string | null;
5336
+ cluster_uri?: string | null;
5337
+ company_code?: string | null;
5338
+ company_name?: string | null;
5339
+ connected_at?: string | null;
5340
+ created_at?: string;
5341
+ environment: string;
5342
+ id?: string;
5343
+ is_active?: boolean;
5344
+ label?: string | null;
5345
+ office_code?: string | null;
5346
+ redirect_uri: string;
5347
+ refresh_token?: string | null;
5348
+ token_expires_at?: string | null;
5349
+ updated_at?: string;
5350
+ user_id: string;
5351
+ };
5352
+ Update: {
5353
+ access_token?: string | null;
5354
+ client_id?: string;
5355
+ client_secret?: string | null;
5356
+ cluster_uri?: string | null;
5357
+ company_code?: string | null;
5358
+ company_name?: string | null;
5359
+ connected_at?: string | null;
5360
+ created_at?: string;
5361
+ environment?: string;
5362
+ id?: string;
5363
+ is_active?: boolean;
5364
+ label?: string | null;
5365
+ office_code?: string | null;
5366
+ redirect_uri?: string;
5367
+ refresh_token?: string | null;
5368
+ token_expires_at?: string | null;
5369
+ updated_at?: string;
5370
+ user_id?: string;
5371
+ };
5372
+ Relationships: [];
5373
+ };
5374
+ twinfield_credentials: {
5375
+ Row: {
5376
+ administration_code: string | null;
5377
+ client_id: string | null;
5378
+ client_secret: string | null;
5379
+ cluster: string | null;
5380
+ connected_at: string | null;
5381
+ created_at: string;
5382
+ environment: string | null;
5383
+ id: string;
5384
+ redirect_uri: string | null;
5385
+ refresh_token: string | null;
5386
+ updated_at: string;
5387
+ user_id: string;
5388
+ };
5389
+ Insert: {
5390
+ administration_code?: string | null;
5391
+ client_id?: string | null;
5392
+ client_secret?: string | null;
5393
+ cluster?: string | null;
5394
+ connected_at?: string | null;
5395
+ created_at?: string;
5396
+ environment?: string | null;
5397
+ id?: string;
5398
+ redirect_uri?: string | null;
5399
+ refresh_token?: string | null;
5400
+ updated_at?: string;
5401
+ user_id: string;
5402
+ };
5403
+ Update: {
5404
+ administration_code?: string | null;
5405
+ client_id?: string | null;
5406
+ client_secret?: string | null;
5407
+ cluster?: string | null;
5408
+ connected_at?: string | null;
5409
+ created_at?: string;
5410
+ environment?: string | null;
5411
+ id?: string;
5412
+ redirect_uri?: string | null;
5413
+ refresh_token?: string | null;
5414
+ updated_at?: string;
5415
+ user_id?: string;
5416
+ };
5417
+ Relationships: [];
5418
+ };
5419
+ twinfield_customers: {
5420
+ Row: {
5421
+ address: string | null;
5422
+ city: string | null;
5423
+ country: string | null;
5424
+ created_at: string;
5425
+ email: string | null;
5426
+ id: string;
5427
+ last_synced_at: string | null;
5428
+ name: string;
5429
+ phone: string | null;
5430
+ postal_code: string | null;
5431
+ status: string;
5432
+ sync_error: string | null;
5433
+ sync_status: string;
5434
+ twinfield_code: string | null;
5435
+ updated_at: string;
5436
+ user_id: string;
5437
+ };
5438
+ Insert: {
5439
+ address?: string | null;
5440
+ city?: string | null;
5441
+ country?: string | null;
5442
+ created_at?: string;
5443
+ email?: string | null;
5444
+ id?: string;
5445
+ last_synced_at?: string | null;
5446
+ name: string;
5447
+ phone?: string | null;
5448
+ postal_code?: string | null;
5449
+ status?: string;
5450
+ sync_error?: string | null;
5451
+ sync_status?: string;
5452
+ twinfield_code?: string | null;
5453
+ updated_at?: string;
5454
+ user_id: string;
5455
+ };
5456
+ Update: {
5457
+ address?: string | null;
5458
+ city?: string | null;
5459
+ country?: string | null;
5460
+ created_at?: string;
5461
+ email?: string | null;
5462
+ id?: string;
5463
+ last_synced_at?: string | null;
5464
+ name?: string;
5465
+ phone?: string | null;
5466
+ postal_code?: string | null;
5467
+ status?: string;
5468
+ sync_error?: string | null;
5469
+ sync_status?: string;
5470
+ twinfield_code?: string | null;
5471
+ updated_at?: string;
5472
+ user_id?: string;
5473
+ };
5474
+ Relationships: [];
5475
+ };
5476
+ twinfield_customers_cache: {
5477
+ Row: {
5478
+ connection_id: string;
5479
+ country: string | null;
5480
+ data: import("../integrations/supabase/types").Json;
5481
+ email: string | null;
5482
+ fetched_at: string;
5483
+ modified_at: string | null;
5484
+ name: string | null;
5485
+ twinfield_code: string;
5486
+ vat_number: string | null;
5487
+ };
5488
+ Insert: {
5489
+ connection_id: string;
5490
+ country?: string | null;
5491
+ data?: import("../integrations/supabase/types").Json;
5492
+ email?: string | null;
5493
+ fetched_at?: string;
5494
+ modified_at?: string | null;
5495
+ name?: string | null;
5496
+ twinfield_code: string;
5497
+ vat_number?: string | null;
5498
+ };
5499
+ Update: {
5500
+ connection_id?: string;
5501
+ country?: string | null;
5502
+ data?: import("../integrations/supabase/types").Json;
5503
+ email?: string | null;
5504
+ fetched_at?: string;
5505
+ modified_at?: string | null;
5506
+ name?: string | null;
5507
+ twinfield_code?: string;
5508
+ vat_number?: string | null;
5509
+ };
5510
+ Relationships: [{
5511
+ foreignKeyName: "twinfield_customers_cache_connection_id_fkey";
5512
+ columns: ["connection_id"];
5513
+ isOneToOne: false;
5514
+ referencedRelation: "twinfield_connections";
5515
+ referencedColumns: ["id"];
5516
+ }];
5517
+ };
5518
+ twinfield_invoice_lines: {
5519
+ Row: {
5520
+ article_code: string | null;
5521
+ created_at: string;
5522
+ description: string | null;
5523
+ gl_account: string | null;
5524
+ id: string;
5525
+ invoice_id: string;
5526
+ line_number: number | null;
5527
+ line_total: number;
5528
+ quantity: number;
5529
+ unit_price: number;
5530
+ user_id: string;
5531
+ vat_code: string | null;
5532
+ vat_rate: number;
5533
+ };
5534
+ Insert: {
5535
+ article_code?: string | null;
5536
+ created_at?: string;
5537
+ description?: string | null;
5538
+ gl_account?: string | null;
5539
+ id?: string;
5540
+ invoice_id: string;
5541
+ line_number?: number | null;
5542
+ line_total?: number;
5543
+ quantity?: number;
5544
+ unit_price?: number;
5545
+ user_id: string;
5546
+ vat_code?: string | null;
5547
+ vat_rate?: number;
5548
+ };
5549
+ Update: {
5550
+ article_code?: string | null;
5551
+ created_at?: string;
5552
+ description?: string | null;
5553
+ gl_account?: string | null;
5554
+ id?: string;
5555
+ invoice_id?: string;
5556
+ line_number?: number | null;
5557
+ line_total?: number;
5558
+ quantity?: number;
5559
+ unit_price?: number;
5560
+ user_id?: string;
5561
+ vat_code?: string | null;
5562
+ vat_rate?: number;
5563
+ };
5564
+ Relationships: [{
5565
+ foreignKeyName: "twinfield_invoice_lines_invoice_id_fkey";
5566
+ columns: ["invoice_id"];
5567
+ isOneToOne: false;
5568
+ referencedRelation: "twinfield_invoices";
5569
+ referencedColumns: ["id"];
5570
+ }];
5571
+ };
5572
+ twinfield_invoice_lines_cache_v2: {
5573
+ Row: {
5574
+ article_code: string | null;
5575
+ connection_id: string;
5576
+ data: import("../integrations/supabase/types").Json;
5577
+ description: string | null;
5578
+ fetched_at: string;
5579
+ invoice_number: string;
5580
+ line_number: number;
5581
+ quantity: number | null;
5582
+ unit_price: number | null;
5583
+ vat_code: string | null;
5584
+ };
5585
+ Insert: {
5586
+ article_code?: string | null;
5587
+ connection_id: string;
5588
+ data?: import("../integrations/supabase/types").Json;
5589
+ description?: string | null;
5590
+ fetched_at?: string;
5591
+ invoice_number: string;
5592
+ line_number: number;
5593
+ quantity?: number | null;
5594
+ unit_price?: number | null;
5595
+ vat_code?: string | null;
5596
+ };
5597
+ Update: {
5598
+ article_code?: string | null;
5599
+ connection_id?: string;
5600
+ data?: import("../integrations/supabase/types").Json;
5601
+ description?: string | null;
5602
+ fetched_at?: string;
5603
+ invoice_number?: string;
5604
+ line_number?: number;
5605
+ quantity?: number | null;
5606
+ unit_price?: number | null;
5607
+ vat_code?: string | null;
5608
+ };
5609
+ Relationships: [{
5610
+ foreignKeyName: "twinfield_invoice_lines_cache_v2_connection_id_fkey";
5611
+ columns: ["connection_id"];
5612
+ isOneToOne: false;
5613
+ referencedRelation: "twinfield_connections";
5614
+ referencedColumns: ["id"];
5615
+ }];
5616
+ };
5617
+ twinfield_invoice_settings: {
5618
+ Row: {
5619
+ created_at: string;
5620
+ default_gl_account: string;
5621
+ default_invoice_type: string;
5622
+ default_payment_term_days: number;
5623
+ default_vat_code: string;
5624
+ updated_at: string;
5625
+ user_id: string;
5626
+ };
5627
+ Insert: {
5628
+ created_at?: string;
5629
+ default_gl_account?: string;
5630
+ default_invoice_type?: string;
5631
+ default_payment_term_days?: number;
5632
+ default_vat_code?: string;
5633
+ updated_at?: string;
5634
+ user_id: string;
5635
+ };
5636
+ Update: {
5637
+ created_at?: string;
5638
+ default_gl_account?: string;
5639
+ default_invoice_type?: string;
5640
+ default_payment_term_days?: number;
5641
+ default_vat_code?: string;
5642
+ updated_at?: string;
5643
+ user_id?: string;
5644
+ };
5645
+ Relationships: [];
5646
+ };
5647
+ twinfield_invoice_sync_logs: {
5648
+ Row: {
5649
+ created_at: string;
5650
+ details: import("../integrations/supabase/types").Json | null;
5651
+ duration_ms: number | null;
5652
+ id: string;
5653
+ invoice_lines_fetched: number | null;
5654
+ invoices_fetched: number | null;
5655
+ message: string | null;
5656
+ status: string;
5657
+ step: string | null;
5658
+ user_id: string;
5659
+ };
5660
+ Insert: {
5661
+ created_at?: string;
5662
+ details?: import("../integrations/supabase/types").Json | null;
5663
+ duration_ms?: number | null;
5664
+ id?: string;
5665
+ invoice_lines_fetched?: number | null;
5666
+ invoices_fetched?: number | null;
5667
+ message?: string | null;
5668
+ status: string;
5669
+ step?: string | null;
5670
+ user_id: string;
5671
+ };
5672
+ Update: {
5673
+ created_at?: string;
5674
+ details?: import("../integrations/supabase/types").Json | null;
5675
+ duration_ms?: number | null;
5676
+ id?: string;
5677
+ invoice_lines_fetched?: number | null;
5678
+ invoices_fetched?: number | null;
5679
+ message?: string | null;
5680
+ status?: string;
5681
+ step?: string | null;
5682
+ user_id?: string;
5683
+ };
5684
+ Relationships: [];
5685
+ };
5686
+ twinfield_invoices: {
5687
+ Row: {
5688
+ administration_code: string | null;
5689
+ created_at: string;
5690
+ currency: string | null;
5691
+ customer_code: string | null;
5692
+ customer_email: string | null;
5693
+ customer_name: string | null;
5694
+ customer_phone: string | null;
5695
+ due_date: string | null;
5696
+ id: string;
5697
+ invoice_date: string | null;
5698
+ last_synced_at: string;
5699
+ local_invoice_number: string | null;
5700
+ outstanding_amount: number;
5701
+ paid_amount: number;
5702
+ payment_date: string | null;
5703
+ raw_payload: import("../integrations/supabase/types").Json | null;
5704
+ status: string;
5705
+ subtotal: number;
5706
+ sync_error: string | null;
5707
+ sync_status: string;
5708
+ total: number;
5709
+ twinfield_invoice_number: string;
5710
+ twinfield_transaction_number: string | null;
5711
+ updated_at: string;
5712
+ user_id: string;
5713
+ vat_amount: number;
5714
+ };
5715
+ Insert: {
5716
+ administration_code?: string | null;
5717
+ created_at?: string;
5718
+ currency?: string | null;
5719
+ customer_code?: string | null;
5720
+ customer_email?: string | null;
5721
+ customer_name?: string | null;
5722
+ customer_phone?: string | null;
5723
+ due_date?: string | null;
5724
+ id?: string;
5725
+ invoice_date?: string | null;
5726
+ last_synced_at?: string;
5727
+ local_invoice_number?: string | null;
5728
+ outstanding_amount?: number;
5729
+ paid_amount?: number;
5730
+ payment_date?: string | null;
5731
+ raw_payload?: import("../integrations/supabase/types").Json | null;
5732
+ status?: string;
5733
+ subtotal?: number;
5734
+ sync_error?: string | null;
5735
+ sync_status?: string;
5736
+ total?: number;
5737
+ twinfield_invoice_number: string;
5738
+ twinfield_transaction_number?: string | null;
5739
+ updated_at?: string;
5740
+ user_id: string;
5741
+ vat_amount?: number;
5742
+ };
5743
+ Update: {
5744
+ administration_code?: string | null;
5745
+ created_at?: string;
5746
+ currency?: string | null;
5747
+ customer_code?: string | null;
5748
+ customer_email?: string | null;
5749
+ customer_name?: string | null;
5750
+ customer_phone?: string | null;
5751
+ due_date?: string | null;
5752
+ id?: string;
5753
+ invoice_date?: string | null;
5754
+ last_synced_at?: string;
5755
+ local_invoice_number?: string | null;
5756
+ outstanding_amount?: number;
5757
+ paid_amount?: number;
5758
+ payment_date?: string | null;
5759
+ raw_payload?: import("../integrations/supabase/types").Json | null;
5760
+ status?: string;
5761
+ subtotal?: number;
5762
+ sync_error?: string | null;
5763
+ sync_status?: string;
5764
+ total?: number;
5765
+ twinfield_invoice_number?: string;
5766
+ twinfield_transaction_number?: string | null;
5767
+ updated_at?: string;
5768
+ user_id?: string;
5769
+ vat_amount?: number;
5770
+ };
5771
+ Relationships: [];
5772
+ };
5773
+ twinfield_invoices_cache_v2: {
5774
+ Row: {
5775
+ connection_id: string;
5776
+ currency: string | null;
5777
+ customer_code: string | null;
5778
+ data: import("../integrations/supabase/types").Json;
5779
+ due_date: string | null;
5780
+ fetched_at: string;
5781
+ invoice_date: string | null;
5782
+ invoice_number: string;
5783
+ modified_at: string | null;
5784
+ status: string | null;
5785
+ total_excl: number | null;
5786
+ total_incl: number | null;
5787
+ };
5788
+ Insert: {
5789
+ connection_id: string;
5790
+ currency?: string | null;
5791
+ customer_code?: string | null;
5792
+ data?: import("../integrations/supabase/types").Json;
5793
+ due_date?: string | null;
5794
+ fetched_at?: string;
5795
+ invoice_date?: string | null;
5796
+ invoice_number: string;
5797
+ modified_at?: string | null;
5798
+ status?: string | null;
5799
+ total_excl?: number | null;
5800
+ total_incl?: number | null;
5801
+ };
5802
+ Update: {
5803
+ connection_id?: string;
5804
+ currency?: string | null;
5805
+ customer_code?: string | null;
5806
+ data?: import("../integrations/supabase/types").Json;
5807
+ due_date?: string | null;
5808
+ fetched_at?: string;
5809
+ invoice_date?: string | null;
5810
+ invoice_number?: string;
5811
+ modified_at?: string | null;
5812
+ status?: string | null;
5813
+ total_excl?: number | null;
5814
+ total_incl?: number | null;
5815
+ };
5816
+ Relationships: [{
5817
+ foreignKeyName: "twinfield_invoices_cache_v2_connection_id_fkey";
5818
+ columns: ["connection_id"];
5819
+ isOneToOne: false;
5820
+ referencedRelation: "twinfield_connections";
5821
+ referencedColumns: ["id"];
5822
+ }];
5823
+ };
5824
+ twinfield_oauth_state: {
5825
+ Row: {
5826
+ created_at: string;
5827
+ environment: string;
5828
+ nonce: string | null;
5829
+ state: string;
5830
+ user_id: string;
5831
+ };
5832
+ Insert: {
5833
+ created_at?: string;
5834
+ environment: string;
5835
+ nonce?: string | null;
5836
+ state: string;
5837
+ user_id: string;
5838
+ };
5839
+ Update: {
5840
+ created_at?: string;
5841
+ environment?: string;
5842
+ nonce?: string | null;
5843
+ state?: string;
5844
+ user_id?: string;
5845
+ };
5846
+ Relationships: [];
5847
+ };
5848
+ twinfield_settings: {
5849
+ Row: {
5850
+ active_environment: string;
5851
+ id: number;
5852
+ updated_at: string;
5853
+ };
5854
+ Insert: {
5855
+ active_environment?: string;
5856
+ id?: number;
5857
+ updated_at?: string;
5858
+ };
5859
+ Update: {
5860
+ active_environment?: string;
5861
+ id?: number;
5862
+ updated_at?: string;
5863
+ };
5864
+ Relationships: [];
5865
+ };
5866
+ twinfield_sync_state: {
5867
+ Row: {
5868
+ connection_id: string;
5869
+ entity_type: string;
5870
+ last_error: string | null;
5871
+ last_modified_since: string;
5872
+ last_synced_at: string | null;
5873
+ updated_at: string;
5874
+ };
5875
+ Insert: {
5876
+ connection_id: string;
5877
+ entity_type: string;
5878
+ last_error?: string | null;
5879
+ last_modified_since?: string;
5880
+ last_synced_at?: string | null;
5881
+ updated_at?: string;
5882
+ };
5883
+ Update: {
5884
+ connection_id?: string;
5885
+ entity_type?: string;
5886
+ last_error?: string | null;
5887
+ last_modified_since?: string;
5888
+ last_synced_at?: string | null;
5889
+ updated_at?: string;
5890
+ };
5891
+ Relationships: [{
5892
+ foreignKeyName: "twinfield_sync_state_connection_id_fkey";
5893
+ columns: ["connection_id"];
5894
+ isOneToOne: false;
5895
+ referencedRelation: "twinfield_connections";
5896
+ referencedColumns: ["id"];
5897
+ }];
5898
+ };
5899
+ twinfield_token_refresh_log: {
5900
+ Row: {
5901
+ attempted_at: string;
5902
+ connection_id: string;
5903
+ error: string | null;
5904
+ expires_at: string | null;
5905
+ id: string;
5906
+ ok: boolean;
5907
+ };
5908
+ Insert: {
5909
+ attempted_at?: string;
5910
+ connection_id: string;
5911
+ error?: string | null;
5912
+ expires_at?: string | null;
5913
+ id?: string;
5914
+ ok: boolean;
5915
+ };
5916
+ Update: {
5917
+ attempted_at?: string;
5918
+ connection_id?: string;
5919
+ error?: string | null;
5920
+ expires_at?: string | null;
5921
+ id?: string;
5922
+ ok?: boolean;
5923
+ };
5924
+ Relationships: [{
5925
+ foreignKeyName: "twinfield_token_refresh_log_connection_id_fkey";
5926
+ columns: ["connection_id"];
5927
+ isOneToOne: false;
5928
+ referencedRelation: "twinfield_connections";
5929
+ referencedColumns: ["id"];
5930
+ }];
5931
+ };
5932
+ user_roles: {
5933
+ Row: {
5934
+ created_at: string;
5935
+ id: string;
5936
+ role: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
5937
+ user_id: string;
5938
+ };
5939
+ Insert: {
5940
+ created_at?: string;
5941
+ id?: string;
5942
+ role: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
5943
+ user_id: string;
5944
+ };
5945
+ Update: {
5946
+ created_at?: string;
5947
+ id?: string;
5948
+ role?: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
3734
5949
  user_id?: string;
3735
5950
  };
5951
+ Relationships: [{
5952
+ foreignKeyName: "user_roles_user_id_fkey";
5953
+ columns: ["user_id"];
5954
+ isOneToOne: false;
5955
+ referencedRelation: "profiles";
5956
+ referencedColumns: ["id"];
5957
+ }];
5958
+ };
5959
+ work_order_monteurs: {
5960
+ Row: {
5961
+ created_at: string;
5962
+ id: string;
5963
+ monteur_id: string;
5964
+ work_order_id: string;
5965
+ };
5966
+ Insert: {
5967
+ created_at?: string;
5968
+ id?: string;
5969
+ monteur_id: string;
5970
+ work_order_id: string;
5971
+ };
5972
+ Update: {
5973
+ created_at?: string;
5974
+ id?: string;
5975
+ monteur_id?: string;
5976
+ work_order_id?: string;
5977
+ };
5978
+ Relationships: [{
5979
+ foreignKeyName: "work_order_monteurs_monteur_id_fkey";
5980
+ columns: ["monteur_id"];
5981
+ isOneToOne: false;
5982
+ referencedRelation: "monteurs";
5983
+ referencedColumns: ["id"];
5984
+ }, {
5985
+ foreignKeyName: "work_order_monteurs_work_order_id_fkey";
5986
+ columns: ["work_order_id"];
5987
+ isOneToOne: false;
5988
+ referencedRelation: "work_orders";
5989
+ referencedColumns: ["id"];
5990
+ }];
5991
+ };
5992
+ work_orders: {
5993
+ Row: {
5994
+ assigned_to: string | null;
5995
+ city: string | null;
5996
+ contact_person: string | null;
5997
+ created_at: string;
5998
+ custom_fields: import("../integrations/supabase/types").Json;
5999
+ customer_name: string;
6000
+ description: string;
6001
+ email: string | null;
6002
+ email_source: string | null;
6003
+ estimated_duration_hours: number | null;
6004
+ external_reference: string | null;
6005
+ follow_up_needed: boolean;
6006
+ id: string;
6007
+ mandate: string;
6008
+ mandate_budget: number;
6009
+ mandate_used: number;
6010
+ order_number: string;
6011
+ parent_work_order_id: string | null;
6012
+ pdf_url: string | null;
6013
+ phone: string | null;
6014
+ postal_code: string;
6015
+ priority: string;
6016
+ project_number: string | null;
6017
+ report_validated: boolean;
6018
+ room_number: string;
6019
+ scheduled_date: string | null;
6020
+ scheduled_end_time: string | null;
6021
+ scheduled_start_time: string | null;
6022
+ status: string;
6023
+ tenant_id: string;
6024
+ total_hours_worked: number | null;
6025
+ total_price: number | null;
6026
+ travel_time_minutes: number | null;
6027
+ updated_at: string;
6028
+ work_address: string;
6029
+ work_report: string | null;
6030
+ };
6031
+ Insert: {
6032
+ assigned_to?: string | null;
6033
+ city?: string | null;
6034
+ contact_person?: string | null;
6035
+ created_at?: string;
6036
+ custom_fields?: import("../integrations/supabase/types").Json;
6037
+ customer_name?: string;
6038
+ description?: string;
6039
+ email?: string | null;
6040
+ email_source?: string | null;
6041
+ estimated_duration_hours?: number | null;
6042
+ external_reference?: string | null;
6043
+ follow_up_needed?: boolean;
6044
+ id?: string;
6045
+ mandate?: string;
6046
+ mandate_budget?: number;
6047
+ mandate_used?: number;
6048
+ order_number?: string;
6049
+ parent_work_order_id?: string | null;
6050
+ pdf_url?: string | null;
6051
+ phone?: string | null;
6052
+ postal_code?: string;
6053
+ priority?: string;
6054
+ project_number?: string | null;
6055
+ report_validated?: boolean;
6056
+ room_number?: string;
6057
+ scheduled_date?: string | null;
6058
+ scheduled_end_time?: string | null;
6059
+ scheduled_start_time?: string | null;
6060
+ status?: string;
6061
+ tenant_id: string;
6062
+ total_hours_worked?: number | null;
6063
+ total_price?: number | null;
6064
+ travel_time_minutes?: number | null;
6065
+ updated_at?: string;
6066
+ work_address?: string;
6067
+ work_report?: string | null;
6068
+ };
6069
+ Update: {
6070
+ assigned_to?: string | null;
6071
+ city?: string | null;
6072
+ contact_person?: string | null;
6073
+ created_at?: string;
6074
+ custom_fields?: import("../integrations/supabase/types").Json;
6075
+ customer_name?: string;
6076
+ description?: string;
6077
+ email?: string | null;
6078
+ email_source?: string | null;
6079
+ estimated_duration_hours?: number | null;
6080
+ external_reference?: string | null;
6081
+ follow_up_needed?: boolean;
6082
+ id?: string;
6083
+ mandate?: string;
6084
+ mandate_budget?: number;
6085
+ mandate_used?: number;
6086
+ order_number?: string;
6087
+ parent_work_order_id?: string | null;
6088
+ pdf_url?: string | null;
6089
+ phone?: string | null;
6090
+ postal_code?: string;
6091
+ priority?: string;
6092
+ project_number?: string | null;
6093
+ report_validated?: boolean;
6094
+ room_number?: string;
6095
+ scheduled_date?: string | null;
6096
+ scheduled_end_time?: string | null;
6097
+ scheduled_start_time?: string | null;
6098
+ status?: string;
6099
+ tenant_id?: string;
6100
+ total_hours_worked?: number | null;
6101
+ total_price?: number | null;
6102
+ travel_time_minutes?: number | null;
6103
+ updated_at?: string;
6104
+ work_address?: string;
6105
+ work_report?: string | null;
6106
+ };
6107
+ Relationships: [{
6108
+ foreignKeyName: "work_orders_parent_work_order_id_fkey";
6109
+ columns: ["parent_work_order_id"];
6110
+ isOneToOne: false;
6111
+ referencedRelation: "work_orders";
6112
+ referencedColumns: ["id"];
6113
+ }, {
6114
+ foreignKeyName: "work_orders_tenant_id_fkey";
6115
+ columns: ["tenant_id"];
6116
+ isOneToOne: false;
6117
+ referencedRelation: "tenants";
6118
+ referencedColumns: ["id"];
6119
+ }];
6120
+ };
6121
+ };
6122
+ Views: {
6123
+ email_auth_connections_safe: {
6124
+ Row: {
6125
+ account_email: string | null;
6126
+ created_at: string | null;
6127
+ created_by: string | null;
6128
+ display_name: string | null;
6129
+ has_access_token: boolean | null;
6130
+ has_client_id: boolean | null;
6131
+ has_client_secret: boolean | null;
6132
+ has_imap_password: boolean | null;
6133
+ has_refresh_token: boolean | null;
6134
+ has_smtp_password: boolean | null;
6135
+ id: string | null;
6136
+ imap_host: string | null;
6137
+ imap_port: number | null;
6138
+ imap_secure: boolean | null;
6139
+ imap_username: string | null;
6140
+ is_active: boolean | null;
6141
+ last_error: string | null;
6142
+ last_verified_at: string | null;
6143
+ oauth_mode: string | null;
6144
+ provider: string | null;
6145
+ purpose_assignments: import("../integrations/supabase/types").Json | null;
6146
+ scopes: string[] | null;
6147
+ smtp_host: string | null;
6148
+ smtp_port: number | null;
6149
+ smtp_secure: boolean | null;
6150
+ smtp_username: string | null;
6151
+ status: string | null;
6152
+ token_expires_at: string | null;
6153
+ updated_at: string | null;
6154
+ };
6155
+ Insert: {
6156
+ account_email?: string | null;
6157
+ created_at?: string | null;
6158
+ created_by?: string | null;
6159
+ display_name?: string | null;
6160
+ has_access_token?: never;
6161
+ has_client_id?: never;
6162
+ has_client_secret?: never;
6163
+ has_imap_password?: never;
6164
+ has_refresh_token?: never;
6165
+ has_smtp_password?: never;
6166
+ id?: string | null;
6167
+ imap_host?: string | null;
6168
+ imap_port?: number | null;
6169
+ imap_secure?: boolean | null;
6170
+ imap_username?: string | null;
6171
+ is_active?: boolean | null;
6172
+ last_error?: string | null;
6173
+ last_verified_at?: string | null;
6174
+ oauth_mode?: string | null;
6175
+ provider?: string | null;
6176
+ purpose_assignments?: import("../integrations/supabase/types").Json | null;
6177
+ scopes?: string[] | null;
6178
+ smtp_host?: string | null;
6179
+ smtp_port?: number | null;
6180
+ smtp_secure?: boolean | null;
6181
+ smtp_username?: string | null;
6182
+ status?: string | null;
6183
+ token_expires_at?: string | null;
6184
+ updated_at?: string | null;
6185
+ };
6186
+ Update: {
6187
+ account_email?: string | null;
6188
+ created_at?: string | null;
6189
+ created_by?: string | null;
6190
+ display_name?: string | null;
6191
+ has_access_token?: never;
6192
+ has_client_id?: never;
6193
+ has_client_secret?: never;
6194
+ has_imap_password?: never;
6195
+ has_refresh_token?: never;
6196
+ has_smtp_password?: never;
6197
+ id?: string | null;
6198
+ imap_host?: string | null;
6199
+ imap_port?: number | null;
6200
+ imap_secure?: boolean | null;
6201
+ imap_username?: string | null;
6202
+ is_active?: boolean | null;
6203
+ last_error?: string | null;
6204
+ last_verified_at?: string | null;
6205
+ oauth_mode?: string | null;
6206
+ provider?: string | null;
6207
+ purpose_assignments?: import("../integrations/supabase/types").Json | null;
6208
+ scopes?: string[] | null;
6209
+ smtp_host?: string | null;
6210
+ smtp_port?: number | null;
6211
+ smtp_secure?: boolean | null;
6212
+ smtp_username?: string | null;
6213
+ status?: string | null;
6214
+ token_expires_at?: string | null;
6215
+ updated_at?: string | null;
6216
+ };
6217
+ Relationships: [];
6218
+ };
6219
+ external_customers_grouped: {
6220
+ Row: {
6221
+ city: string | null;
6222
+ commercial_name: string | null;
6223
+ contact_person: string | null;
6224
+ country: string | null;
6225
+ display_name: string | null;
6226
+ email: string | null;
6227
+ fetched_at: string | null;
6228
+ gln: string | null;
6229
+ group_key: string | null;
6230
+ is_active: boolean | null;
6231
+ is_merged: boolean | null;
6232
+ logo_url: string | null;
6233
+ match_key: string | null;
6234
+ phone: string | null;
6235
+ providers: string[] | null;
6236
+ source_count: number | null;
6237
+ sources: import("../integrations/supabase/types").Json | null;
6238
+ vat_number: string | null;
6239
+ website: string | null;
6240
+ };
3736
6241
  Relationships: [];
3737
6242
  };
3738
- user_roles: {
6243
+ external_customers_unified: {
3739
6244
  Row: {
3740
- created_at: string;
3741
- id: string;
3742
- role: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
3743
- user_id: string;
6245
+ city: string | null;
6246
+ commercial_name: string | null;
6247
+ company_name: string | null;
6248
+ connection_id: string | null;
6249
+ contact_person: string | null;
6250
+ country: string | null;
6251
+ email: string | null;
6252
+ external_id: string | null;
6253
+ fetched_at: string | null;
6254
+ gln: string | null;
6255
+ house_number: string | null;
6256
+ is_active: boolean | null;
6257
+ is_deleted: boolean | null;
6258
+ logo_url: string | null;
6259
+ phone: string | null;
6260
+ postal_code: string | null;
6261
+ provider: string | null;
6262
+ raw: import("../integrations/supabase/types").Json | null;
6263
+ status: string | null;
6264
+ street: string | null;
6265
+ vat_number: string | null;
6266
+ website: string | null;
3744
6267
  };
3745
- Insert: {
3746
- created_at?: string;
3747
- id?: string;
3748
- role: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
3749
- user_id: string;
6268
+ Relationships: [];
6269
+ };
6270
+ v_external_customers_floriday: {
6271
+ Row: {
6272
+ city: string | null;
6273
+ commercial_name: string | null;
6274
+ company_name: string | null;
6275
+ connection_id: string | null;
6276
+ contact_person: string | null;
6277
+ country: string | null;
6278
+ email: string | null;
6279
+ external_id: string | null;
6280
+ fetched_at: string | null;
6281
+ gln: string | null;
6282
+ house_number: string | null;
6283
+ is_active: boolean | null;
6284
+ is_deleted: boolean | null;
6285
+ logo_url: string | null;
6286
+ phone: string | null;
6287
+ postal_code: string | null;
6288
+ provider: string | null;
6289
+ raw: import("../integrations/supabase/types").Json | null;
6290
+ status: string | null;
6291
+ street: string | null;
6292
+ vat_number: string | null;
6293
+ website: string | null;
3750
6294
  };
3751
- Update: {
3752
- created_at?: string;
3753
- id?: string;
3754
- role?: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
3755
- user_id?: string;
6295
+ Relationships: [{
6296
+ foreignKeyName: "floriday_customers_cache_connection_id_fkey";
6297
+ columns: ["connection_id"];
6298
+ isOneToOne: false;
6299
+ referencedRelation: "floriday_connections";
6300
+ referencedColumns: ["id"];
6301
+ }];
6302
+ };
6303
+ v_external_customers_twinfield: {
6304
+ Row: {
6305
+ city: string | null;
6306
+ commercial_name: string | null;
6307
+ company_name: string | null;
6308
+ connection_id: string | null;
6309
+ contact_person: string | null;
6310
+ country: string | null;
6311
+ email: string | null;
6312
+ external_id: string | null;
6313
+ fetched_at: string | null;
6314
+ gln: string | null;
6315
+ house_number: string | null;
6316
+ is_active: boolean | null;
6317
+ is_deleted: boolean | null;
6318
+ logo_url: string | null;
6319
+ phone: string | null;
6320
+ postal_code: string | null;
6321
+ provider: string | null;
6322
+ raw: import("../integrations/supabase/types").Json | null;
6323
+ status: string | null;
6324
+ street: string | null;
6325
+ vat_number: string | null;
6326
+ website: string | null;
3756
6327
  };
3757
6328
  Relationships: [{
3758
- foreignKeyName: "user_roles_user_id_fkey";
3759
- columns: ["user_id"];
6329
+ foreignKeyName: "twinfield_customers_cache_connection_id_fkey";
6330
+ columns: ["connection_id"];
3760
6331
  isOneToOne: false;
3761
- referencedRelation: "profiles";
6332
+ referencedRelation: "twinfield_connections";
3762
6333
  referencedColumns: ["id"];
3763
6334
  }];
3764
6335
  };
3765
6336
  };
3766
- Views: { [_ in never]: never; };
3767
6337
  Functions: {
3768
6338
  dashboard_list_public_schema: {
3769
6339
  Args: never;
@@ -3773,6 +6343,45 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3773
6343
  table_name: string;
3774
6344
  }[];
3775
6345
  };
6346
+ email_auth_decrypt: {
6347
+ Args: {
6348
+ cipher: string;
6349
+ };
6350
+ Returns: string;
6351
+ };
6352
+ email_auth_encrypt: {
6353
+ Args: {
6354
+ plain: string;
6355
+ };
6356
+ Returns: string;
6357
+ };
6358
+ email_auth_fetch_message: {
6359
+ Args: {
6360
+ _connection_id: string;
6361
+ _external_id: string;
6362
+ };
6363
+ Returns: import("../integrations/supabase/types").Json;
6364
+ };
6365
+ email_auth_for_purpose: {
6366
+ Args: {
6367
+ _direction: string;
6368
+ _purpose: string;
6369
+ };
6370
+ Returns: {
6371
+ account_email: string;
6372
+ display_name: string;
6373
+ id: string;
6374
+ last_error: string;
6375
+ last_verified_at: string;
6376
+ needs_reauth: boolean;
6377
+ provider: string;
6378
+ status: string;
6379
+ }[];
6380
+ };
6381
+ ensure_user_tenant: {
6382
+ Args: never;
6383
+ Returns: string;
6384
+ };
3776
6385
  exact_decrypt: {
3777
6386
  Args: {
3778
6387
  cipher: string;
@@ -3785,12 +6394,97 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3785
6394
  };
3786
6395
  Returns: string;
3787
6396
  };
6397
+ exact_lock_environment: {
6398
+ Args: {
6399
+ _environment: string;
6400
+ };
6401
+ Returns: undefined;
6402
+ };
6403
+ exact_release_refresh_lock: {
6404
+ Args: {
6405
+ _environment: import("../integrations/supabase/types").Database["public"]["Enums"]["exact_env"];
6406
+ _locked_by: string;
6407
+ };
6408
+ Returns: undefined;
6409
+ };
6410
+ exact_try_acquire_refresh_lock: {
6411
+ Args: {
6412
+ _environment: import("../integrations/supabase/types").Database["public"]["Enums"]["exact_env"];
6413
+ _lease_seconds?: number;
6414
+ _locked_by?: string;
6415
+ };
6416
+ Returns: boolean;
6417
+ };
6418
+ get_active_floriday_connection_public: {
6419
+ Args: never;
6420
+ Returns: {
6421
+ active_environment: string;
6422
+ environment: string;
6423
+ gln_code: string;
6424
+ id: string;
6425
+ label: string;
6426
+ organization_name: string;
6427
+ preferred_warehouse_id: string;
6428
+ preferred_warehouse_name: string;
6429
+ }[];
6430
+ };
6431
+ get_active_twinfield_public: {
6432
+ Args: never;
6433
+ Returns: {
6434
+ active_environment: string;
6435
+ company_code: string;
6436
+ company_name: string;
6437
+ connection_id: string;
6438
+ environment: string;
6439
+ office_code: string;
6440
+ }[];
6441
+ };
6442
+ get_floriday_cron_jobs: {
6443
+ Args: never;
6444
+ Returns: {
6445
+ active: boolean;
6446
+ jobname: string;
6447
+ schedule: string;
6448
+ url: string;
6449
+ }[];
6450
+ };
3788
6451
  get_offer_by_link_code: {
3789
6452
  Args: {
3790
6453
  p_code: string;
3791
6454
  };
3792
6455
  Returns: import("../integrations/supabase/types").Json;
3793
6456
  };
6457
+ get_room_busy_windows: {
6458
+ Args: {
6459
+ p_from: string;
6460
+ p_to: string;
6461
+ };
6462
+ Returns: {
6463
+ end_time: string;
6464
+ room_id: string;
6465
+ start_time: string;
6466
+ status: string;
6467
+ }[];
6468
+ };
6469
+ get_twinfield_cron_jobs: {
6470
+ Args: never;
6471
+ Returns: {
6472
+ active: boolean;
6473
+ jobname: string;
6474
+ schedule: string;
6475
+ url: string;
6476
+ }[];
6477
+ };
6478
+ get_user_tenant_id: {
6479
+ Args: never;
6480
+ Returns: string;
6481
+ };
6482
+ get_work_order_tenant_id: {
6483
+ Args: {
6484
+ wo_id: string;
6485
+ };
6486
+ Returns: string;
6487
+ };
3794
6488
  has_role: {
3795
6489
  Args: {
3796
6490
  _role: import("../integrations/supabase/types").Database["public"]["Enums"]["app_role"];
@@ -3798,6 +6492,48 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3798
6492
  };
3799
6493
  Returns: boolean;
3800
6494
  };
6495
+ is_authenticated: {
6496
+ Args: never;
6497
+ Returns: boolean;
6498
+ };
6499
+ is_developer: {
6500
+ Args: never;
6501
+ Returns: boolean;
6502
+ };
6503
+ next_work_order_number: {
6504
+ Args: {
6505
+ p_parent_work_order_id?: string;
6506
+ p_tenant_id: string;
6507
+ };
6508
+ Returns: string;
6509
+ };
6510
+ normalize_vat: {
6511
+ Args: {
6512
+ v: string;
6513
+ };
6514
+ Returns: string;
6515
+ };
6516
+ schedule_floriday_carriers_sync: {
6517
+ Args: {
6518
+ p_apikey: string;
6519
+ p_url: string;
6520
+ };
6521
+ Returns: number;
6522
+ };
6523
+ schedule_floriday_connections_sync: {
6524
+ Args: {
6525
+ p_apikey: string;
6526
+ p_url: string;
6527
+ };
6528
+ Returns: number;
6529
+ };
6530
+ schedule_floriday_customer_organizations_sync: {
6531
+ Args: {
6532
+ p_apikey: string;
6533
+ p_url: string;
6534
+ };
6535
+ Returns: number;
6536
+ };
3801
6537
  schedule_floriday_network_sync: {
3802
6538
  Args: {
3803
6539
  p_apikey: string;
@@ -3805,6 +6541,13 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3805
6541
  };
3806
6542
  Returns: number;
3807
6543
  };
6544
+ schedule_floriday_salesorders_sync: {
6545
+ Args: {
6546
+ p_apikey: string;
6547
+ p_url: string;
6548
+ };
6549
+ Returns: number;
6550
+ };
3808
6551
  schedule_floriday_token_refresh: {
3809
6552
  Args: {
3810
6553
  p_apikey: string;
@@ -3812,6 +6555,55 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3812
6555
  };
3813
6556
  Returns: number;
3814
6557
  };
6558
+ schedule_floriday_trade_items_sync: {
6559
+ Args: {
6560
+ p_apikey: string;
6561
+ p_url: string;
6562
+ };
6563
+ Returns: number;
6564
+ };
6565
+ schedule_twinfield_customers_sync: {
6566
+ Args: {
6567
+ p_apikey: string;
6568
+ p_url: string;
6569
+ };
6570
+ Returns: number;
6571
+ } | {
6572
+ Args: {
6573
+ p_apikey: string;
6574
+ p_cron_secret?: string;
6575
+ p_url: string;
6576
+ };
6577
+ Returns: number;
6578
+ };
6579
+ schedule_twinfield_invoices_sync: {
6580
+ Args: {
6581
+ p_apikey: string;
6582
+ p_url: string;
6583
+ };
6584
+ Returns: number;
6585
+ } | {
6586
+ Args: {
6587
+ p_apikey: string;
6588
+ p_cron_secret?: string;
6589
+ p_url: string;
6590
+ };
6591
+ Returns: number;
6592
+ };
6593
+ schedule_twinfield_token_refresh: {
6594
+ Args: {
6595
+ p_apikey: string;
6596
+ p_url: string;
6597
+ };
6598
+ Returns: number;
6599
+ } | {
6600
+ Args: {
6601
+ p_apikey: string;
6602
+ p_cron_secret?: string;
6603
+ p_url: string;
6604
+ };
6605
+ Returns: number;
6606
+ };
3815
6607
  show_limit: {
3816
6608
  Args: never;
3817
6609
  Returns: number;
@@ -3822,10 +6614,23 @@ export declare const getFloridayOrders: import("@tanstack/start-client-core").Op
3822
6614
  };
3823
6615
  Returns: string[];
3824
6616
  };
6617
+ twinfield_decrypt: {
6618
+ Args: {
6619
+ cipher: string;
6620
+ };
6621
+ Returns: string;
6622
+ };
6623
+ twinfield_encrypt: {
6624
+ Args: {
6625
+ plain: string;
6626
+ };
6627
+ Returns: string;
6628
+ };
3825
6629
  };
3826
6630
  Enums: {
3827
- app_role: "admin" | "manager" | "warehouse" | "sales" | "developer";
6631
+ app_role: "admin" | "manager" | "warehouse" | "sales" | "developer" | "receptie";
3828
6632
  exact_env: "staging" | "live";
6633
+ quote_status: "concept" | "verzonden" | "bekeken" | "in_behandeling" | "geaccepteerd" | "afgewezen" | "verlopen" | "gearchiveerd";
3829
6634
  };
3830
6635
  CompositeTypes: { [_ in never]: never; };
3831
6636
  }, {