@flowselections/floriday-klanten-module 1.0.3 → 1.0.5

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.
@@ -475,6 +475,276 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
475
475
  };
476
476
  Relationships: [];
477
477
  };
478
+ dashboard_ai_conversations: {
479
+ Row: {
480
+ created_at: string;
481
+ id: string;
482
+ messages: import("./types").Json;
483
+ page_id: string | null;
484
+ title: string | null;
485
+ updated_at: string;
486
+ user_id: string;
487
+ };
488
+ Insert: {
489
+ created_at?: string;
490
+ id?: string;
491
+ messages?: import("./types").Json;
492
+ page_id?: string | null;
493
+ title?: string | null;
494
+ updated_at?: string;
495
+ user_id: string;
496
+ };
497
+ Update: {
498
+ created_at?: string;
499
+ id?: string;
500
+ messages?: import("./types").Json;
501
+ page_id?: string | null;
502
+ title?: string | null;
503
+ updated_at?: string;
504
+ user_id?: string;
505
+ };
506
+ Relationships: [{
507
+ foreignKeyName: "dashboard_ai_conversations_page_id_fkey";
508
+ columns: ["page_id"];
509
+ isOneToOne: false;
510
+ referencedRelation: "dashboard_pages";
511
+ referencedColumns: ["id"];
512
+ }];
513
+ };
514
+ dashboard_alert_events: {
515
+ Row: {
516
+ acknowledged: boolean;
517
+ block_id: string;
518
+ created_at: string;
519
+ id: string;
520
+ message: string | null;
521
+ page_id: string;
522
+ severity: string;
523
+ threshold: number | null;
524
+ user_id: string;
525
+ value: number | null;
526
+ };
527
+ Insert: {
528
+ acknowledged?: boolean;
529
+ block_id: string;
530
+ created_at?: string;
531
+ id?: string;
532
+ message?: string | null;
533
+ page_id: string;
534
+ severity?: string;
535
+ threshold?: number | null;
536
+ user_id: string;
537
+ value?: number | null;
538
+ };
539
+ Update: {
540
+ acknowledged?: boolean;
541
+ block_id?: string;
542
+ created_at?: string;
543
+ id?: string;
544
+ message?: string | null;
545
+ page_id?: string;
546
+ severity?: string;
547
+ threshold?: number | null;
548
+ user_id?: string;
549
+ value?: number | null;
550
+ };
551
+ Relationships: [{
552
+ foreignKeyName: "dashboard_alert_events_block_id_fkey";
553
+ columns: ["block_id"];
554
+ isOneToOne: false;
555
+ referencedRelation: "dashboard_blocks";
556
+ referencedColumns: ["id"];
557
+ }, {
558
+ foreignKeyName: "dashboard_alert_events_page_id_fkey";
559
+ columns: ["page_id"];
560
+ isOneToOne: false;
561
+ referencedRelation: "dashboard_pages";
562
+ referencedColumns: ["id"];
563
+ }];
564
+ };
565
+ dashboard_block_templates: {
566
+ Row: {
567
+ config: import("./types").Json;
568
+ created_at: string;
569
+ description: string | null;
570
+ id: string;
571
+ is_public: boolean;
572
+ name: string;
573
+ type: string;
574
+ updated_at: string;
575
+ user_id: string;
576
+ };
577
+ Insert: {
578
+ config?: import("./types").Json;
579
+ created_at?: string;
580
+ description?: string | null;
581
+ id?: string;
582
+ is_public?: boolean;
583
+ name: string;
584
+ type: string;
585
+ updated_at?: string;
586
+ user_id: string;
587
+ };
588
+ Update: {
589
+ config?: import("./types").Json;
590
+ created_at?: string;
591
+ description?: string | null;
592
+ id?: string;
593
+ is_public?: boolean;
594
+ name?: string;
595
+ type?: string;
596
+ updated_at?: string;
597
+ user_id?: string;
598
+ };
599
+ Relationships: [];
600
+ };
601
+ dashboard_blocks: {
602
+ Row: {
603
+ config: import("./types").Json;
604
+ created_at: string;
605
+ filters: import("./types").Json;
606
+ id: string;
607
+ layout: import("./types").Json;
608
+ page_id: string;
609
+ permissions: import("./types").Json;
610
+ sort_order: number;
611
+ title: string;
612
+ type: string;
613
+ updated_at: string;
614
+ };
615
+ Insert: {
616
+ config?: import("./types").Json;
617
+ created_at?: string;
618
+ filters?: import("./types").Json;
619
+ id?: string;
620
+ layout?: import("./types").Json;
621
+ page_id: string;
622
+ permissions?: import("./types").Json;
623
+ sort_order?: number;
624
+ title: string;
625
+ type: string;
626
+ updated_at?: string;
627
+ };
628
+ Update: {
629
+ config?: import("./types").Json;
630
+ created_at?: string;
631
+ filters?: import("./types").Json;
632
+ id?: string;
633
+ layout?: import("./types").Json;
634
+ page_id?: string;
635
+ permissions?: import("./types").Json;
636
+ sort_order?: number;
637
+ title?: string;
638
+ type?: string;
639
+ updated_at?: string;
640
+ };
641
+ Relationships: [{
642
+ foreignKeyName: "dashboard_blocks_page_id_fkey";
643
+ columns: ["page_id"];
644
+ isOneToOne: false;
645
+ referencedRelation: "dashboard_pages";
646
+ referencedColumns: ["id"];
647
+ }];
648
+ };
649
+ dashboard_daily_reports: {
650
+ Row: {
651
+ created_at: string;
652
+ highlights: import("./types").Json | null;
653
+ id: string;
654
+ page_id: string;
655
+ summary: string;
656
+ user_id: string;
657
+ };
658
+ Insert: {
659
+ created_at?: string;
660
+ highlights?: import("./types").Json | null;
661
+ id?: string;
662
+ page_id: string;
663
+ summary: string;
664
+ user_id: string;
665
+ };
666
+ Update: {
667
+ created_at?: string;
668
+ highlights?: import("./types").Json | null;
669
+ id?: string;
670
+ page_id?: string;
671
+ summary?: string;
672
+ user_id?: string;
673
+ };
674
+ Relationships: [{
675
+ foreignKeyName: "dashboard_daily_reports_page_id_fkey";
676
+ columns: ["page_id"];
677
+ isOneToOne: false;
678
+ referencedRelation: "dashboard_pages";
679
+ referencedColumns: ["id"];
680
+ }];
681
+ };
682
+ dashboard_pages: {
683
+ Row: {
684
+ created_at: string;
685
+ icon: string | null;
686
+ id: string;
687
+ is_default: boolean;
688
+ name: string;
689
+ shared_with: string[];
690
+ sort_order: number;
691
+ updated_at: string;
692
+ user_id: string;
693
+ };
694
+ Insert: {
695
+ created_at?: string;
696
+ icon?: string | null;
697
+ id?: string;
698
+ is_default?: boolean;
699
+ name: string;
700
+ shared_with?: string[];
701
+ sort_order?: number;
702
+ updated_at?: string;
703
+ user_id: string;
704
+ };
705
+ Update: {
706
+ created_at?: string;
707
+ icon?: string | null;
708
+ id?: string;
709
+ is_default?: boolean;
710
+ name?: string;
711
+ shared_with?: string[];
712
+ sort_order?: number;
713
+ updated_at?: string;
714
+ user_id?: string;
715
+ };
716
+ Relationships: [];
717
+ };
718
+ dashboard_saved_queries: {
719
+ Row: {
720
+ created_at: string;
721
+ description: string | null;
722
+ id: string;
723
+ name: string;
724
+ query_spec: import("./types").Json;
725
+ updated_at: string;
726
+ user_id: string;
727
+ };
728
+ Insert: {
729
+ created_at?: string;
730
+ description?: string | null;
731
+ id?: string;
732
+ name: string;
733
+ query_spec: import("./types").Json;
734
+ updated_at?: string;
735
+ user_id: string;
736
+ };
737
+ Update: {
738
+ created_at?: string;
739
+ description?: string | null;
740
+ id?: string;
741
+ name?: string;
742
+ query_spec?: import("./types").Json;
743
+ updated_at?: string;
744
+ user_id?: string;
745
+ };
746
+ Relationships: [];
747
+ };
478
748
  exact_connections: {
479
749
  Row: {
480
750
  access_token_encrypted: string;
@@ -485,6 +755,9 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
485
755
  environment: Database["public"]["Enums"]["exact_env"];
486
756
  expires_at: string;
487
757
  id: string;
758
+ last_error: string | null;
759
+ last_refreshed_at: string | null;
760
+ last_tested_at: string | null;
488
761
  refresh_token_encrypted: string;
489
762
  status: string;
490
763
  updated_at: string;
@@ -498,6 +771,9 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
498
771
  environment: Database["public"]["Enums"]["exact_env"];
499
772
  expires_at: string;
500
773
  id?: string;
774
+ last_error?: string | null;
775
+ last_refreshed_at?: string | null;
776
+ last_tested_at?: string | null;
501
777
  refresh_token_encrypted: string;
502
778
  status?: string;
503
779
  updated_at?: string;
@@ -511,6 +787,9 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
511
787
  environment?: Database["public"]["Enums"]["exact_env"];
512
788
  expires_at?: string;
513
789
  id?: string;
790
+ last_error?: string | null;
791
+ last_refreshed_at?: string | null;
792
+ last_tested_at?: string | null;
514
793
  refresh_token_encrypted?: string;
515
794
  status?: string;
516
795
  updated_at?: string;
@@ -533,7 +812,7 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
533
812
  created_at?: string;
534
813
  environment: Database["public"]["Enums"]["exact_env"];
535
814
  id?: string;
536
- redirect_uri: string;
815
+ redirect_uri?: string;
537
816
  updated_at?: string;
538
817
  };
539
818
  Update: {
@@ -892,6 +1171,222 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
892
1171
  };
893
1172
  Relationships: [];
894
1173
  };
1174
+ mailbox_messages: {
1175
+ Row: {
1176
+ body_html: string | null;
1177
+ body_text: string | null;
1178
+ created_at: string;
1179
+ error_message: string | null;
1180
+ from_email: string | null;
1181
+ from_name: string | null;
1182
+ id: string;
1183
+ message_id: string | null;
1184
+ raw_size: number | null;
1185
+ received_at: string | null;
1186
+ status: string;
1187
+ subject: string | null;
1188
+ uid: number;
1189
+ updated_at: string;
1190
+ };
1191
+ Insert: {
1192
+ body_html?: string | null;
1193
+ body_text?: string | null;
1194
+ created_at?: string;
1195
+ error_message?: string | null;
1196
+ from_email?: string | null;
1197
+ from_name?: string | null;
1198
+ id?: string;
1199
+ message_id?: string | null;
1200
+ raw_size?: number | null;
1201
+ received_at?: string | null;
1202
+ status?: string;
1203
+ subject?: string | null;
1204
+ uid: number;
1205
+ updated_at?: string;
1206
+ };
1207
+ Update: {
1208
+ body_html?: string | null;
1209
+ body_text?: string | null;
1210
+ created_at?: string;
1211
+ error_message?: string | null;
1212
+ from_email?: string | null;
1213
+ from_name?: string | null;
1214
+ id?: string;
1215
+ message_id?: string | null;
1216
+ raw_size?: number | null;
1217
+ received_at?: string | null;
1218
+ status?: string;
1219
+ subject?: string | null;
1220
+ uid?: number;
1221
+ updated_at?: string;
1222
+ };
1223
+ Relationships: [];
1224
+ };
1225
+ mailbox_order_proposals: {
1226
+ Row: {
1227
+ confidence: number | null;
1228
+ created_at: string;
1229
+ created_order_id: string | null;
1230
+ delivery_date: string | null;
1231
+ id: string;
1232
+ matched_customer_id: string | null;
1233
+ message_id: string;
1234
+ notes: string | null;
1235
+ parsed_payload: import("./types").Json | null;
1236
+ reviewed_at: string | null;
1237
+ reviewed_by: string | null;
1238
+ status: string;
1239
+ updated_at: string;
1240
+ };
1241
+ Insert: {
1242
+ confidence?: number | null;
1243
+ created_at?: string;
1244
+ created_order_id?: string | null;
1245
+ delivery_date?: string | null;
1246
+ id?: string;
1247
+ matched_customer_id?: string | null;
1248
+ message_id: string;
1249
+ notes?: string | null;
1250
+ parsed_payload?: import("./types").Json | null;
1251
+ reviewed_at?: string | null;
1252
+ reviewed_by?: string | null;
1253
+ status?: string;
1254
+ updated_at?: string;
1255
+ };
1256
+ Update: {
1257
+ confidence?: number | null;
1258
+ created_at?: string;
1259
+ created_order_id?: string | null;
1260
+ delivery_date?: string | null;
1261
+ id?: string;
1262
+ matched_customer_id?: string | null;
1263
+ message_id?: string;
1264
+ notes?: string | null;
1265
+ parsed_payload?: import("./types").Json | null;
1266
+ reviewed_at?: string | null;
1267
+ reviewed_by?: string | null;
1268
+ status?: string;
1269
+ updated_at?: string;
1270
+ };
1271
+ Relationships: [{
1272
+ foreignKeyName: "mailbox_order_proposals_created_order_id_fkey";
1273
+ columns: ["created_order_id"];
1274
+ isOneToOne: false;
1275
+ referencedRelation: "orders";
1276
+ referencedColumns: ["id"];
1277
+ }, {
1278
+ foreignKeyName: "mailbox_order_proposals_matched_customer_id_fkey";
1279
+ columns: ["matched_customer_id"];
1280
+ isOneToOne: false;
1281
+ referencedRelation: "customers";
1282
+ referencedColumns: ["id"];
1283
+ }, {
1284
+ foreignKeyName: "mailbox_order_proposals_message_id_fkey";
1285
+ columns: ["message_id"];
1286
+ isOneToOne: false;
1287
+ referencedRelation: "mailbox_messages";
1288
+ referencedColumns: ["id"];
1289
+ }];
1290
+ };
1291
+ mailbox_proposal_lines: {
1292
+ Row: {
1293
+ created_at: string;
1294
+ id: string;
1295
+ match_confidence: number | null;
1296
+ product_id: string | null;
1297
+ proposal_id: string;
1298
+ quantity: number | null;
1299
+ raw_product_text: string | null;
1300
+ sort_order: number;
1301
+ unit: string | null;
1302
+ updated_at: string;
1303
+ };
1304
+ Insert: {
1305
+ created_at?: string;
1306
+ id?: string;
1307
+ match_confidence?: number | null;
1308
+ product_id?: string | null;
1309
+ proposal_id: string;
1310
+ quantity?: number | null;
1311
+ raw_product_text?: string | null;
1312
+ sort_order?: number;
1313
+ unit?: string | null;
1314
+ updated_at?: string;
1315
+ };
1316
+ Update: {
1317
+ created_at?: string;
1318
+ id?: string;
1319
+ match_confidence?: number | null;
1320
+ product_id?: string | null;
1321
+ proposal_id?: string;
1322
+ quantity?: number | null;
1323
+ raw_product_text?: string | null;
1324
+ sort_order?: number;
1325
+ unit?: string | null;
1326
+ updated_at?: string;
1327
+ };
1328
+ Relationships: [{
1329
+ foreignKeyName: "mailbox_proposal_lines_product_id_fkey";
1330
+ columns: ["product_id"];
1331
+ isOneToOne: false;
1332
+ referencedRelation: "products";
1333
+ referencedColumns: ["id"];
1334
+ }, {
1335
+ foreignKeyName: "mailbox_proposal_lines_proposal_id_fkey";
1336
+ columns: ["proposal_id"];
1337
+ isOneToOne: false;
1338
+ referencedRelation: "mailbox_order_proposals";
1339
+ referencedColumns: ["id"];
1340
+ }];
1341
+ };
1342
+ mailbox_settings: {
1343
+ Row: {
1344
+ created_at: string;
1345
+ folder: string;
1346
+ id: string;
1347
+ imap_host: string;
1348
+ imap_port: number;
1349
+ imap_use_tls: boolean;
1350
+ imap_username: string;
1351
+ last_error: string | null;
1352
+ last_polled_at: string | null;
1353
+ last_uid_seen: number;
1354
+ polling_enabled: boolean;
1355
+ singleton: boolean;
1356
+ updated_at: string;
1357
+ };
1358
+ Insert: {
1359
+ created_at?: string;
1360
+ folder?: string;
1361
+ id?: string;
1362
+ imap_host?: string;
1363
+ imap_port?: number;
1364
+ imap_use_tls?: boolean;
1365
+ imap_username?: string;
1366
+ last_error?: string | null;
1367
+ last_polled_at?: string | null;
1368
+ last_uid_seen?: number;
1369
+ polling_enabled?: boolean;
1370
+ singleton?: boolean;
1371
+ updated_at?: string;
1372
+ };
1373
+ Update: {
1374
+ created_at?: string;
1375
+ folder?: string;
1376
+ id?: string;
1377
+ imap_host?: string;
1378
+ imap_port?: number;
1379
+ imap_use_tls?: boolean;
1380
+ imap_username?: string;
1381
+ last_error?: string | null;
1382
+ last_polled_at?: string | null;
1383
+ last_uid_seen?: number;
1384
+ polling_enabled?: boolean;
1385
+ singleton?: boolean;
1386
+ updated_at?: string;
1387
+ };
1388
+ Relationships: [];
1389
+ };
895
1390
  notifications: {
896
1391
  Row: {
897
1392
  created_at: string;
@@ -922,6 +1417,378 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
922
1417
  };
923
1418
  Relationships: [];
924
1419
  };
1420
+ offer_campaign_product_tiers: {
1421
+ Row: {
1422
+ campaign_product_id: string;
1423
+ created_at: string;
1424
+ id: string;
1425
+ min_crates: number;
1426
+ price_per_crate: number;
1427
+ sort_order: number;
1428
+ };
1429
+ Insert: {
1430
+ campaign_product_id: string;
1431
+ created_at?: string;
1432
+ id?: string;
1433
+ min_crates?: number;
1434
+ price_per_crate?: number;
1435
+ sort_order?: number;
1436
+ };
1437
+ Update: {
1438
+ campaign_product_id?: string;
1439
+ created_at?: string;
1440
+ id?: string;
1441
+ min_crates?: number;
1442
+ price_per_crate?: number;
1443
+ sort_order?: number;
1444
+ };
1445
+ Relationships: [{
1446
+ foreignKeyName: "offer_campaign_product_tiers_campaign_product_id_fkey";
1447
+ columns: ["campaign_product_id"];
1448
+ isOneToOne: false;
1449
+ referencedRelation: "offer_campaign_products";
1450
+ referencedColumns: ["id"];
1451
+ }];
1452
+ };
1453
+ offer_campaign_products: {
1454
+ Row: {
1455
+ available_stock: number;
1456
+ barcode: string | null;
1457
+ belading: string | null;
1458
+ campaign_id: string;
1459
+ crate_price: number | null;
1460
+ created_at: string;
1461
+ description: string | null;
1462
+ discount_price: number;
1463
+ id: string;
1464
+ image_url: string | null;
1465
+ normal_price: number;
1466
+ plants_per_crate: number | null;
1467
+ product_id: string | null;
1468
+ product_name: string;
1469
+ sort_order: number;
1470
+ sticker_available: boolean;
1471
+ sticker_cost: number | null;
1472
+ };
1473
+ Insert: {
1474
+ available_stock?: number;
1475
+ barcode?: string | null;
1476
+ belading?: string | null;
1477
+ campaign_id: string;
1478
+ crate_price?: number | null;
1479
+ created_at?: string;
1480
+ description?: string | null;
1481
+ discount_price?: number;
1482
+ id?: string;
1483
+ image_url?: string | null;
1484
+ normal_price?: number;
1485
+ plants_per_crate?: number | null;
1486
+ product_id?: string | null;
1487
+ product_name: string;
1488
+ sort_order?: number;
1489
+ sticker_available?: boolean;
1490
+ sticker_cost?: number | null;
1491
+ };
1492
+ Update: {
1493
+ available_stock?: number;
1494
+ barcode?: string | null;
1495
+ belading?: string | null;
1496
+ campaign_id?: string;
1497
+ crate_price?: number | null;
1498
+ created_at?: string;
1499
+ description?: string | null;
1500
+ discount_price?: number;
1501
+ id?: string;
1502
+ image_url?: string | null;
1503
+ normal_price?: number;
1504
+ plants_per_crate?: number | null;
1505
+ product_id?: string | null;
1506
+ product_name?: string;
1507
+ sort_order?: number;
1508
+ sticker_available?: boolean;
1509
+ sticker_cost?: number | null;
1510
+ };
1511
+ Relationships: [{
1512
+ foreignKeyName: "offer_campaign_products_campaign_id_fkey";
1513
+ columns: ["campaign_id"];
1514
+ isOneToOne: false;
1515
+ referencedRelation: "offer_campaigns";
1516
+ referencedColumns: ["id"];
1517
+ }, {
1518
+ foreignKeyName: "offer_campaign_products_product_id_fkey";
1519
+ columns: ["product_id"];
1520
+ isOneToOne: false;
1521
+ referencedRelation: "products";
1522
+ referencedColumns: ["id"];
1523
+ }];
1524
+ };
1525
+ offer_campaigns: {
1526
+ Row: {
1527
+ created_at: string;
1528
+ created_by: string | null;
1529
+ from_email: string;
1530
+ from_name: string;
1531
+ id: string;
1532
+ intro_message: string | null;
1533
+ name: string;
1534
+ scheduled_at: string | null;
1535
+ sent_at: string | null;
1536
+ status: string;
1537
+ subject: string;
1538
+ updated_at: string;
1539
+ };
1540
+ Insert: {
1541
+ created_at?: string;
1542
+ created_by?: string | null;
1543
+ from_email: string;
1544
+ from_name: string;
1545
+ id?: string;
1546
+ intro_message?: string | null;
1547
+ name: string;
1548
+ scheduled_at?: string | null;
1549
+ sent_at?: string | null;
1550
+ status?: string;
1551
+ subject: string;
1552
+ updated_at?: string;
1553
+ };
1554
+ Update: {
1555
+ created_at?: string;
1556
+ created_by?: string | null;
1557
+ from_email?: string;
1558
+ from_name?: string;
1559
+ id?: string;
1560
+ intro_message?: string | null;
1561
+ name?: string;
1562
+ scheduled_at?: string | null;
1563
+ sent_at?: string | null;
1564
+ status?: string;
1565
+ subject?: string;
1566
+ updated_at?: string;
1567
+ };
1568
+ Relationships: [];
1569
+ };
1570
+ offer_events: {
1571
+ Row: {
1572
+ campaign_id: string;
1573
+ created_at: string;
1574
+ event_type: string;
1575
+ id: string;
1576
+ metadata: import("./types").Json;
1577
+ recipient_id: string;
1578
+ };
1579
+ Insert: {
1580
+ campaign_id: string;
1581
+ created_at?: string;
1582
+ event_type: string;
1583
+ id?: string;
1584
+ metadata?: import("./types").Json;
1585
+ recipient_id: string;
1586
+ };
1587
+ Update: {
1588
+ campaign_id?: string;
1589
+ created_at?: string;
1590
+ event_type?: string;
1591
+ id?: string;
1592
+ metadata?: import("./types").Json;
1593
+ recipient_id?: string;
1594
+ };
1595
+ Relationships: [{
1596
+ foreignKeyName: "offer_events_campaign_id_fkey";
1597
+ columns: ["campaign_id"];
1598
+ isOneToOne: false;
1599
+ referencedRelation: "offer_campaigns";
1600
+ referencedColumns: ["id"];
1601
+ }, {
1602
+ foreignKeyName: "offer_events_recipient_id_fkey";
1603
+ columns: ["recipient_id"];
1604
+ isOneToOne: false;
1605
+ referencedRelation: "offer_recipients";
1606
+ referencedColumns: ["id"];
1607
+ }];
1608
+ };
1609
+ offer_orders: {
1610
+ Row: {
1611
+ campaign_id: string;
1612
+ created_at: string;
1613
+ customer_email: string;
1614
+ customer_id: string | null;
1615
+ customer_name: string;
1616
+ customer_phone: string | null;
1617
+ id: string;
1618
+ items: import("./types").Json;
1619
+ notes: string | null;
1620
+ recipient_id: string;
1621
+ total_amount: number;
1622
+ };
1623
+ Insert: {
1624
+ campaign_id: string;
1625
+ created_at?: string;
1626
+ customer_email: string;
1627
+ customer_id?: string | null;
1628
+ customer_name: string;
1629
+ customer_phone?: string | null;
1630
+ id?: string;
1631
+ items?: import("./types").Json;
1632
+ notes?: string | null;
1633
+ recipient_id: string;
1634
+ total_amount?: number;
1635
+ };
1636
+ Update: {
1637
+ campaign_id?: string;
1638
+ created_at?: string;
1639
+ customer_email?: string;
1640
+ customer_id?: string | null;
1641
+ customer_name?: string;
1642
+ customer_phone?: string | null;
1643
+ id?: string;
1644
+ items?: import("./types").Json;
1645
+ notes?: string | null;
1646
+ recipient_id?: string;
1647
+ total_amount?: number;
1648
+ };
1649
+ Relationships: [{
1650
+ foreignKeyName: "offer_orders_campaign_id_fkey";
1651
+ columns: ["campaign_id"];
1652
+ isOneToOne: false;
1653
+ referencedRelation: "offer_campaigns";
1654
+ referencedColumns: ["id"];
1655
+ }, {
1656
+ foreignKeyName: "offer_orders_customer_id_fkey";
1657
+ columns: ["customer_id"];
1658
+ isOneToOne: false;
1659
+ referencedRelation: "customers";
1660
+ referencedColumns: ["id"];
1661
+ }, {
1662
+ foreignKeyName: "offer_orders_recipient_id_fkey";
1663
+ columns: ["recipient_id"];
1664
+ isOneToOne: false;
1665
+ referencedRelation: "offer_recipients";
1666
+ referencedColumns: ["id"];
1667
+ }];
1668
+ };
1669
+ offer_recipients: {
1670
+ Row: {
1671
+ campaign_id: string;
1672
+ clicked_at: string | null;
1673
+ contact_id: string | null;
1674
+ created_at: string;
1675
+ customer_id: string | null;
1676
+ id: string;
1677
+ link_code: string;
1678
+ opened_at: string | null;
1679
+ ordered_at: string | null;
1680
+ recipient_email: string;
1681
+ recipient_name: string;
1682
+ sent_at: string | null;
1683
+ };
1684
+ Insert: {
1685
+ campaign_id: string;
1686
+ clicked_at?: string | null;
1687
+ contact_id?: string | null;
1688
+ created_at?: string;
1689
+ customer_id?: string | null;
1690
+ id?: string;
1691
+ link_code?: string;
1692
+ opened_at?: string | null;
1693
+ ordered_at?: string | null;
1694
+ recipient_email: string;
1695
+ recipient_name: string;
1696
+ sent_at?: string | null;
1697
+ };
1698
+ Update: {
1699
+ campaign_id?: string;
1700
+ clicked_at?: string | null;
1701
+ contact_id?: string | null;
1702
+ created_at?: string;
1703
+ customer_id?: string | null;
1704
+ id?: string;
1705
+ link_code?: string;
1706
+ opened_at?: string | null;
1707
+ ordered_at?: string | null;
1708
+ recipient_email?: string;
1709
+ recipient_name?: string;
1710
+ sent_at?: string | null;
1711
+ };
1712
+ Relationships: [{
1713
+ foreignKeyName: "offer_recipients_campaign_id_fkey";
1714
+ columns: ["campaign_id"];
1715
+ isOneToOne: false;
1716
+ referencedRelation: "offer_campaigns";
1717
+ referencedColumns: ["id"];
1718
+ }, {
1719
+ foreignKeyName: "offer_recipients_contact_id_fkey";
1720
+ columns: ["contact_id"];
1721
+ isOneToOne: false;
1722
+ referencedRelation: "customer_contacts";
1723
+ referencedColumns: ["id"];
1724
+ }, {
1725
+ foreignKeyName: "offer_recipients_customer_id_fkey";
1726
+ columns: ["customer_id"];
1727
+ isOneToOne: false;
1728
+ referencedRelation: "customers";
1729
+ referencedColumns: ["id"];
1730
+ }];
1731
+ };
1732
+ offer_settings: {
1733
+ Row: {
1734
+ button_color: string;
1735
+ created_at: string;
1736
+ default_countries: string[];
1737
+ default_customer_classes: string[];
1738
+ default_intro: string;
1739
+ default_subject: string;
1740
+ discount_display: string;
1741
+ excluded_contact_ids: string[];
1742
+ excluded_customer_ids: string[];
1743
+ from_email: string;
1744
+ from_name: string;
1745
+ id: string;
1746
+ logo_url: string | null;
1747
+ primary_color: string;
1748
+ singleton: boolean;
1749
+ tracking_enabled: boolean;
1750
+ updated_at: string;
1751
+ };
1752
+ Insert: {
1753
+ button_color?: string;
1754
+ created_at?: string;
1755
+ default_countries?: string[];
1756
+ default_customer_classes?: string[];
1757
+ default_intro?: string;
1758
+ default_subject?: string;
1759
+ discount_display?: string;
1760
+ excluded_contact_ids?: string[];
1761
+ excluded_customer_ids?: string[];
1762
+ from_email?: string;
1763
+ from_name?: string;
1764
+ id?: string;
1765
+ logo_url?: string | null;
1766
+ primary_color?: string;
1767
+ singleton?: boolean;
1768
+ tracking_enabled?: boolean;
1769
+ updated_at?: string;
1770
+ };
1771
+ Update: {
1772
+ button_color?: string;
1773
+ created_at?: string;
1774
+ default_countries?: string[];
1775
+ default_customer_classes?: string[];
1776
+ default_intro?: string;
1777
+ default_subject?: string;
1778
+ discount_display?: string;
1779
+ excluded_contact_ids?: string[];
1780
+ excluded_customer_ids?: string[];
1781
+ from_email?: string;
1782
+ from_name?: string;
1783
+ id?: string;
1784
+ logo_url?: string | null;
1785
+ primary_color?: string;
1786
+ singleton?: boolean;
1787
+ tracking_enabled?: boolean;
1788
+ updated_at?: string;
1789
+ };
1790
+ Relationships: [];
1791
+ };
925
1792
  order_field_options: {
926
1793
  Row: {
927
1794
  created_at: string;
@@ -1513,6 +2380,24 @@ export declare const supabaseAdmin: import("@supabase/supabase-js").SupabaseClie
1513
2380
  };
1514
2381
  Views: { [_ in never]: never; };
1515
2382
  Functions: {
2383
+ exact_decrypt: {
2384
+ Args: {
2385
+ cipher: string;
2386
+ };
2387
+ Returns: string;
2388
+ };
2389
+ exact_encrypt: {
2390
+ Args: {
2391
+ plain: string;
2392
+ };
2393
+ Returns: string;
2394
+ };
2395
+ get_offer_by_link_code: {
2396
+ Args: {
2397
+ p_code: string;
2398
+ };
2399
+ Returns: import("./types").Json;
2400
+ };
1516
2401
  has_role: {
1517
2402
  Args: {
1518
2403
  _role: Database["public"]["Enums"]["app_role"];