@happyvertical/smrt-content 0.40.70 → 0.41.0

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.
@@ -2,7 +2,7 @@
2
2
  "version": "1.0.0",
3
3
  "timestamp": 0,
4
4
  "packageName": "@happyvertical/smrt-content",
5
- "packageVersion": "0.40.70",
5
+ "packageVersion": "0.41.0",
6
6
  "objects": {
7
7
  "@happyvertical/smrt-content:ContentAsset": {
8
8
  "name": "contentasset",
@@ -156,12 +156,6 @@
156
156
  }
157
157
  },
158
158
  "indexes": [
159
- {
160
- "name": "content_assets_id_idx",
161
- "columns": [
162
- "id"
163
- ]
164
- },
165
159
  {
166
160
  "name": "content_assets_content_id_asset_id_idx",
167
161
  "columns": [
@@ -172,9 +166,23 @@
172
166
  "unique": true
173
167
  },
174
168
  {
175
- "name": "content_assets_tenant_id_idx",
169
+ "name": "content_assets_slug_context_idx",
170
+ "columns": [
171
+ "slug",
172
+ "context"
173
+ ]
174
+ },
175
+ {
176
+ "name": "content_assets_tenant_id_created_at_idx",
177
+ "columns": [
178
+ "tenant_id",
179
+ "created_at"
180
+ ]
181
+ },
182
+ {
183
+ "name": "content_assets_asset_id_idx",
176
184
  "columns": [
177
- "tenant_id"
185
+ "asset_id"
178
186
  ]
179
187
  }
180
188
  ],
@@ -342,12 +350,6 @@
342
350
  }
343
351
  },
344
352
  "indexes": [
345
- {
346
- "name": "content_assets_id_idx",
347
- "columns": [
348
- "id"
349
- ]
350
- },
351
353
  {
352
354
  "name": "content_assets_slug_context_idx",
353
355
  "columns": [
@@ -355,6 +357,12 @@
355
357
  "context"
356
358
  ],
357
359
  "unique": true
360
+ },
361
+ {
362
+ "name": "content_assets_created_at_idx",
363
+ "columns": [
364
+ "created_at"
365
+ ]
358
366
  }
359
367
  ],
360
368
  "version": "35bf42e8"
@@ -589,22 +597,35 @@
589
597
  },
590
598
  "indexes": [
591
599
  {
592
- "name": "content_contribution_attachments_id_idx",
600
+ "name": "content_contribution_attachments_slug_context_idx",
593
601
  "columns": [
594
- "id"
602
+ "slug",
603
+ "context"
595
604
  ]
596
605
  },
597
606
  {
598
- "name": "content_contribution_attachments_id_idx",
607
+ "name": "content_contribution_attachments_tenant_id_created_at_idx",
599
608
  "columns": [
600
- "id"
601
- ],
602
- "unique": true
609
+ "tenant_id",
610
+ "created_at"
611
+ ]
603
612
  },
604
613
  {
605
- "name": "content_contribution_attachments_tenant_id_idx",
614
+ "name": "content_contribution_attachments_contribution_id_idx",
606
615
  "columns": [
607
- "tenant_id"
616
+ "contribution_id"
617
+ ]
618
+ },
619
+ {
620
+ "name": "content_contribution_attachments_revision_id_idx",
621
+ "columns": [
622
+ "revision_id"
623
+ ]
624
+ },
625
+ {
626
+ "name": "content_contribution_attachments_promoted_asset_id_idx",
627
+ "columns": [
628
+ "promoted_asset_id"
608
629
  ]
609
630
  }
610
631
  ],
@@ -687,12 +708,6 @@
687
708
  }
688
709
  },
689
710
  "indexes": [
690
- {
691
- "name": "content_contribution_attachments_id_idx",
692
- "columns": [
693
- "id"
694
- ]
695
- },
696
711
  {
697
712
  "name": "content_contribution_attachments_slug_context_idx",
698
713
  "columns": [
@@ -700,6 +715,12 @@
700
715
  "context"
701
716
  ],
702
717
  "unique": true
718
+ },
719
+ {
720
+ "name": "content_contribution_attachments_created_at_idx",
721
+ "columns": [
722
+ "created_at"
723
+ ]
703
724
  }
704
725
  ],
705
726
  "version": "d0c8b33f"
@@ -924,13 +945,7 @@
924
945
  },
925
946
  "indexes": [
926
947
  {
927
- "name": "content_contribution_revisions_id_idx",
928
- "columns": [
929
- "id"
930
- ]
931
- },
932
- {
933
- "name": "content_contribution_revisions_contribution_id_revision_number_idx",
948
+ "name": "content_contribution_revisions_contribution_id_r_af43e6d599_idx",
934
949
  "columns": [
935
950
  "contribution_id",
936
951
  "revision_number"
@@ -938,9 +953,23 @@
938
953
  "unique": true
939
954
  },
940
955
  {
941
- "name": "content_contribution_revisions_tenant_id_idx",
956
+ "name": "content_contribution_revisions_slug_context_idx",
942
957
  "columns": [
943
- "tenant_id"
958
+ "slug",
959
+ "context"
960
+ ]
961
+ },
962
+ {
963
+ "name": "content_contribution_revisions_tenant_id_created_at_idx",
964
+ "columns": [
965
+ "tenant_id",
966
+ "created_at"
967
+ ]
968
+ },
969
+ {
970
+ "name": "content_contribution_revisions_source_message_id_idx",
971
+ "columns": [
972
+ "source_message_id"
944
973
  ]
945
974
  }
946
975
  ],
@@ -1023,12 +1052,6 @@
1023
1052
  }
1024
1053
  },
1025
1054
  "indexes": [
1026
- {
1027
- "name": "content_contribution_revisions_id_idx",
1028
- "columns": [
1029
- "id"
1030
- ]
1031
- },
1032
1055
  {
1033
1056
  "name": "content_contribution_revisions_slug_context_idx",
1034
1057
  "columns": [
@@ -1036,6 +1059,12 @@
1036
1059
  "context"
1037
1060
  ],
1038
1061
  "unique": true
1062
+ },
1063
+ {
1064
+ "name": "content_contribution_revisions_created_at_idx",
1065
+ "columns": [
1066
+ "created_at"
1067
+ ]
1039
1068
  }
1040
1069
  ],
1041
1070
  "version": "cc3e0dfa"
@@ -1378,12 +1407,6 @@
1378
1407
  }
1379
1408
  },
1380
1409
  "indexes": [
1381
- {
1382
- "name": "content_contribution_types_id_idx",
1383
- "columns": [
1384
- "id"
1385
- ]
1386
- },
1387
1410
  {
1388
1411
  "name": "content_contribution_types_key_idx",
1389
1412
  "columns": [
@@ -1392,9 +1415,17 @@
1392
1415
  "unique": true
1393
1416
  },
1394
1417
  {
1395
- "name": "content_contribution_types_tenant_id_idx",
1418
+ "name": "content_contribution_types_slug_context_idx",
1419
+ "columns": [
1420
+ "slug",
1421
+ "context"
1422
+ ]
1423
+ },
1424
+ {
1425
+ "name": "content_contribution_types_tenant_id_created_at_idx",
1396
1426
  "columns": [
1397
- "tenant_id"
1427
+ "tenant_id",
1428
+ "created_at"
1398
1429
  ]
1399
1430
  }
1400
1431
  ],
@@ -1463,12 +1494,6 @@
1463
1494
  }
1464
1495
  },
1465
1496
  "indexes": [
1466
- {
1467
- "name": "content_contribution_types_id_idx",
1468
- "columns": [
1469
- "id"
1470
- ]
1471
- },
1472
1497
  {
1473
1498
  "name": "content_contribution_types_slug_context_idx",
1474
1499
  "columns": [
@@ -1476,6 +1501,12 @@
1476
1501
  "context"
1477
1502
  ],
1478
1503
  "unique": true
1504
+ },
1505
+ {
1506
+ "name": "content_contribution_types_created_at_idx",
1507
+ "columns": [
1508
+ "created_at"
1509
+ ]
1479
1510
  }
1480
1511
  ],
1481
1512
  "version": "9c9a0367"
@@ -1990,22 +2021,35 @@
1990
2021
  },
1991
2022
  "indexes": [
1992
2023
  {
1993
- "name": "content_contributions_id_idx",
2024
+ "name": "content_contributions_slug_context_idx",
1994
2025
  "columns": [
1995
- "id"
2026
+ "slug",
2027
+ "context"
1996
2028
  ]
1997
2029
  },
1998
2030
  {
1999
- "name": "content_contributions_id_idx",
2031
+ "name": "content_contributions_tenant_id_created_at_idx",
2000
2032
  "columns": [
2001
- "id"
2002
- ],
2003
- "unique": true
2033
+ "tenant_id",
2034
+ "created_at"
2035
+ ]
2036
+ },
2037
+ {
2038
+ "name": "content_contributions_contributor_id_idx",
2039
+ "columns": [
2040
+ "contributor_id"
2041
+ ]
2042
+ },
2043
+ {
2044
+ "name": "content_contributions_source_message_id_idx",
2045
+ "columns": [
2046
+ "source_message_id"
2047
+ ]
2004
2048
  },
2005
2049
  {
2006
- "name": "content_contributions_tenant_id_idx",
2050
+ "name": "content_contributions_promoted_content_id_idx",
2007
2051
  "columns": [
2008
- "tenant_id"
2052
+ "promoted_content_id"
2009
2053
  ]
2010
2054
  }
2011
2055
  ],
@@ -2168,12 +2212,6 @@
2168
2212
  }
2169
2213
  },
2170
2214
  "indexes": [
2171
- {
2172
- "name": "content_contributions_id_idx",
2173
- "columns": [
2174
- "id"
2175
- ]
2176
- },
2177
2215
  {
2178
2216
  "name": "content_contributions_slug_context_idx",
2179
2217
  "columns": [
@@ -2181,6 +2219,12 @@
2181
2219
  "context"
2182
2220
  ],
2183
2221
  "unique": true
2222
+ },
2223
+ {
2224
+ "name": "content_contributions_created_at_idx",
2225
+ "columns": [
2226
+ "created_at"
2227
+ ]
2184
2228
  }
2185
2229
  ],
2186
2230
  "version": "641c0cc8"
@@ -2372,12 +2416,6 @@
2372
2416
  }
2373
2417
  },
2374
2418
  "indexes": [
2375
- {
2376
- "name": "content_contributors_id_idx",
2377
- "columns": [
2378
- "id"
2379
- ]
2380
- },
2381
2419
  {
2382
2420
  "name": "content_contributors_email_idx",
2383
2421
  "columns": [
@@ -2386,9 +2424,23 @@
2386
2424
  "unique": true
2387
2425
  },
2388
2426
  {
2389
- "name": "content_contributors_tenant_id_idx",
2427
+ "name": "content_contributors_slug_context_idx",
2428
+ "columns": [
2429
+ "slug",
2430
+ "context"
2431
+ ]
2432
+ },
2433
+ {
2434
+ "name": "content_contributors_tenant_id_created_at_idx",
2435
+ "columns": [
2436
+ "tenant_id",
2437
+ "created_at"
2438
+ ]
2439
+ },
2440
+ {
2441
+ "name": "content_contributors_profile_id_idx",
2390
2442
  "columns": [
2391
- "tenant_id"
2443
+ "profile_id"
2392
2444
  ]
2393
2445
  }
2394
2446
  ],
@@ -2485,12 +2537,6 @@
2485
2537
  }
2486
2538
  },
2487
2539
  "indexes": [
2488
- {
2489
- "name": "content_contributors_id_idx",
2490
- "columns": [
2491
- "id"
2492
- ]
2493
- },
2494
2540
  {
2495
2541
  "name": "content_contributors_slug_context_idx",
2496
2542
  "columns": [
@@ -2498,6 +2544,12 @@
2498
2544
  "context"
2499
2545
  ],
2500
2546
  "unique": true
2547
+ },
2548
+ {
2549
+ "name": "content_contributors_created_at_idx",
2550
+ "columns": [
2551
+ "created_at"
2552
+ ]
2501
2553
  }
2502
2554
  ],
2503
2555
  "version": "b457e60b"
@@ -2626,7 +2678,12 @@
2626
2678
  "cli": true,
2627
2679
  "tenantScoped": {
2628
2680
  "mode": "optional"
2629
- }
2681
+ },
2682
+ "conflictColumns": [
2683
+ "tenant_id",
2684
+ "slug",
2685
+ "context"
2686
+ ]
2630
2687
  },
2631
2688
  "extends": "SmrtObject",
2632
2689
  "exportName": "ContentCorrection",
@@ -2741,24 +2798,44 @@
2741
2798
  }
2742
2799
  },
2743
2800
  "indexes": [
2744
- {
2745
- "name": "content_corrections_id_idx",
2746
- "columns": [
2747
- "id"
2748
- ]
2749
- },
2750
2801
  {
2751
2802
  "name": "content_corrections_slug_context_idx",
2752
2803
  "columns": [
2804
+ "tenant_id",
2753
2805
  "slug",
2754
2806
  "context"
2755
2807
  ],
2756
2808
  "unique": true
2757
2809
  },
2758
2810
  {
2759
- "name": "content_corrections_tenant_id_idx",
2811
+ "name": "content_corrections_tenant_id_created_at_idx",
2812
+ "columns": [
2813
+ "tenant_id",
2814
+ "created_at"
2815
+ ]
2816
+ },
2817
+ {
2818
+ "name": "content_corrections_content_id_idx",
2760
2819
  "columns": [
2761
- "tenant_id"
2820
+ "content_id"
2821
+ ]
2822
+ },
2823
+ {
2824
+ "name": "content_corrections_content_version_id_idx",
2825
+ "columns": [
2826
+ "content_version_id"
2827
+ ]
2828
+ },
2829
+ {
2830
+ "name": "content_corrections_fact_id_idx",
2831
+ "columns": [
2832
+ "fact_id"
2833
+ ]
2834
+ },
2835
+ {
2836
+ "name": "content_corrections_replacement_fact_id_idx",
2837
+ "columns": [
2838
+ "replacement_fact_id"
2762
2839
  ]
2763
2840
  }
2764
2841
  ],
@@ -2855,12 +2932,6 @@
2855
2932
  }
2856
2933
  },
2857
2934
  "indexes": [
2858
- {
2859
- "name": "content_corrections_id_idx",
2860
- "columns": [
2861
- "id"
2862
- ]
2863
- },
2864
2935
  {
2865
2936
  "name": "content_corrections_slug_context_idx",
2866
2937
  "columns": [
@@ -2868,6 +2939,12 @@
2868
2939
  "context"
2869
2940
  ],
2870
2941
  "unique": true
2942
+ },
2943
+ {
2944
+ "name": "content_corrections_created_at_idx",
2945
+ "columns": [
2946
+ "created_at"
2947
+ ]
2871
2948
  }
2872
2949
  ],
2873
2950
  "version": "6ebe142d"
@@ -3217,12 +3294,6 @@
3217
3294
  }
3218
3295
  },
3219
3296
  "indexes": [
3220
- {
3221
- "name": "content_feed_sources_id_idx",
3222
- "columns": [
3223
- "id"
3224
- ]
3225
- },
3226
3297
  {
3227
3298
  "name": "content_feed_sources_tenant_id_feed_url_idx",
3228
3299
  "columns": [
@@ -3230,6 +3301,20 @@
3230
3301
  "feed_url"
3231
3302
  ],
3232
3303
  "unique": true
3304
+ },
3305
+ {
3306
+ "name": "content_feed_sources_slug_context_idx",
3307
+ "columns": [
3308
+ "slug",
3309
+ "context"
3310
+ ]
3311
+ },
3312
+ {
3313
+ "name": "content_feed_sources_tenant_id_created_at_idx",
3314
+ "columns": [
3315
+ "tenant_id",
3316
+ "created_at"
3317
+ ]
3233
3318
  }
3234
3319
  ],
3235
3320
  "version": "bbcb36e5"
@@ -3335,12 +3420,6 @@
3335
3420
  }
3336
3421
  },
3337
3422
  "indexes": [
3338
- {
3339
- "name": "content_feed_sources_id_idx",
3340
- "columns": [
3341
- "id"
3342
- ]
3343
- },
3344
3423
  {
3345
3424
  "name": "content_feed_sources_slug_context_idx",
3346
3425
  "columns": [
@@ -3348,6 +3427,12 @@
3348
3427
  "context"
3349
3428
  ],
3350
3429
  "unique": true
3430
+ },
3431
+ {
3432
+ "name": "content_feed_sources_created_at_idx",
3433
+ "columns": [
3434
+ "created_at"
3435
+ ]
3351
3436
  }
3352
3437
  ],
3353
3438
  "version": "bb0cca9e"
@@ -3630,12 +3715,6 @@
3630
3715
  }
3631
3716
  },
3632
3717
  "indexes": [
3633
- {
3634
- "name": "content_governance_assignments_id_idx",
3635
- "columns": [
3636
- "id"
3637
- ]
3638
- },
3639
3718
  {
3640
3719
  "name": "content_governance_assignments_key_idx",
3641
3720
  "columns": [
@@ -3644,9 +3723,17 @@
3644
3723
  "unique": true
3645
3724
  },
3646
3725
  {
3647
- "name": "content_governance_assignments_tenant_id_idx",
3726
+ "name": "content_governance_assignments_slug_context_idx",
3648
3727
  "columns": [
3649
- "tenant_id"
3728
+ "slug",
3729
+ "context"
3730
+ ]
3731
+ },
3732
+ {
3733
+ "name": "content_governance_assignments_tenant_id_created_at_idx",
3734
+ "columns": [
3735
+ "tenant_id",
3736
+ "created_at"
3650
3737
  ]
3651
3738
  }
3652
3739
  ],
@@ -3729,12 +3816,6 @@
3729
3816
  }
3730
3817
  },
3731
3818
  "indexes": [
3732
- {
3733
- "name": "content_governance_assignments_id_idx",
3734
- "columns": [
3735
- "id"
3736
- ]
3737
- },
3738
3819
  {
3739
3820
  "name": "content_governance_assignments_slug_context_idx",
3740
3821
  "columns": [
@@ -3742,6 +3823,12 @@
3742
3823
  "context"
3743
3824
  ],
3744
3825
  "unique": true
3826
+ },
3827
+ {
3828
+ "name": "content_governance_assignments_created_at_idx",
3829
+ "columns": [
3830
+ "created_at"
3831
+ ]
3745
3832
  }
3746
3833
  ],
3747
3834
  "version": "21471529"
@@ -3809,12 +3896,6 @@
3809
3896
  }
3810
3897
  },
3811
3898
  "indexes": [
3812
- {
3813
- "name": "content_governance_policies_id_idx",
3814
- "columns": [
3815
- "id"
3816
- ]
3817
- },
3818
3899
  {
3819
3900
  "name": "content_governance_policies_slug_context_idx",
3820
3901
  "columns": [
@@ -3822,6 +3903,12 @@
3822
3903
  "context"
3823
3904
  ],
3824
3905
  "unique": true
3906
+ },
3907
+ {
3908
+ "name": "content_governance_policies_created_at_idx",
3909
+ "columns": [
3910
+ "created_at"
3911
+ ]
3825
3912
  }
3826
3913
  ],
3827
3914
  "version": "e2da0e5b"
@@ -4029,12 +4116,6 @@
4029
4116
  }
4030
4117
  },
4031
4118
  "indexes": [
4032
- {
4033
- "name": "content_governance_policies_id_idx",
4034
- "columns": [
4035
- "id"
4036
- ]
4037
- },
4038
4119
  {
4039
4120
  "name": "content_governance_policies_key_idx",
4040
4121
  "columns": [
@@ -4043,9 +4124,17 @@
4043
4124
  "unique": true
4044
4125
  },
4045
4126
  {
4046
- "name": "content_governance_policies_tenant_id_idx",
4127
+ "name": "content_governance_policies_slug_context_idx",
4047
4128
  "columns": [
4048
- "tenant_id"
4129
+ "slug",
4130
+ "context"
4131
+ ]
4132
+ },
4133
+ {
4134
+ "name": "content_governance_policies_tenant_id_created_at_idx",
4135
+ "columns": [
4136
+ "tenant_id",
4137
+ "created_at"
4049
4138
  ]
4050
4139
  }
4051
4140
  ],
@@ -4260,12 +4349,6 @@
4260
4349
  }
4261
4350
  },
4262
4351
  "indexes": [
4263
- {
4264
- "name": "content_governance_profiles_id_idx",
4265
- "columns": [
4266
- "id"
4267
- ]
4268
- },
4269
4352
  {
4270
4353
  "name": "content_governance_profiles_key_idx",
4271
4354
  "columns": [
@@ -4274,9 +4357,17 @@
4274
4357
  "unique": true
4275
4358
  },
4276
4359
  {
4277
- "name": "content_governance_profiles_tenant_id_idx",
4360
+ "name": "content_governance_profiles_slug_context_idx",
4361
+ "columns": [
4362
+ "slug",
4363
+ "context"
4364
+ ]
4365
+ },
4366
+ {
4367
+ "name": "content_governance_profiles_tenant_id_created_at_idx",
4278
4368
  "columns": [
4279
- "tenant_id"
4369
+ "tenant_id",
4370
+ "created_at"
4280
4371
  ]
4281
4372
  }
4282
4373
  ],
@@ -4345,12 +4436,6 @@
4345
4436
  }
4346
4437
  },
4347
4438
  "indexes": [
4348
- {
4349
- "name": "content_governance_profiles_id_idx",
4350
- "columns": [
4351
- "id"
4352
- ]
4353
- },
4354
4439
  {
4355
4440
  "name": "content_governance_profiles_slug_context_idx",
4356
4441
  "columns": [
@@ -4358,6 +4443,12 @@
4358
4443
  "context"
4359
4444
  ],
4360
4445
  "unique": true
4446
+ },
4447
+ {
4448
+ "name": "content_governance_profiles_created_at_idx",
4449
+ "columns": [
4450
+ "created_at"
4451
+ ]
4361
4452
  }
4362
4453
  ],
4363
4454
  "version": "496f0f56"
@@ -4497,12 +4588,6 @@
4497
4588
  }
4498
4589
  },
4499
4590
  "indexes": [
4500
- {
4501
- "name": "content_references_id_idx",
4502
- "columns": [
4503
- "id"
4504
- ]
4505
- },
4506
4591
  {
4507
4592
  "name": "content_references_source_id_target_id_idx",
4508
4593
  "columns": [
@@ -4512,9 +4597,23 @@
4512
4597
  "unique": true
4513
4598
  },
4514
4599
  {
4515
- "name": "content_references_tenant_id_idx",
4600
+ "name": "content_references_slug_context_idx",
4516
4601
  "columns": [
4517
- "tenant_id"
4602
+ "slug",
4603
+ "context"
4604
+ ]
4605
+ },
4606
+ {
4607
+ "name": "content_references_tenant_id_created_at_idx",
4608
+ "columns": [
4609
+ "tenant_id",
4610
+ "created_at"
4611
+ ]
4612
+ },
4613
+ {
4614
+ "name": "content_references_target_id_idx",
4615
+ "columns": [
4616
+ "target_id"
4518
4617
  ]
4519
4618
  }
4520
4619
  ],
@@ -4726,12 +4825,6 @@
4726
4825
  }
4727
4826
  },
4728
4827
  "indexes": [
4729
- {
4730
- "name": "content_references_id_idx",
4731
- "columns": [
4732
- "id"
4733
- ]
4734
- },
4735
4828
  {
4736
4829
  "name": "content_references_slug_context_idx",
4737
4830
  "columns": [
@@ -4739,6 +4832,12 @@
4739
4832
  "context"
4740
4833
  ],
4741
4834
  "unique": true
4835
+ },
4836
+ {
4837
+ "name": "content_references_created_at_idx",
4838
+ "columns": [
4839
+ "created_at"
4840
+ ]
4742
4841
  }
4743
4842
  ],
4744
4843
  "version": "e9ad3cf0"
@@ -4861,7 +4960,12 @@
4861
4960
  "cli": true,
4862
4961
  "tenantScoped": {
4863
4962
  "mode": "optional"
4864
- }
4963
+ },
4964
+ "conflictColumns": [
4965
+ "tenant_id",
4966
+ "slug",
4967
+ "context"
4968
+ ]
4865
4969
  },
4866
4970
  "extends": "SmrtObject",
4867
4971
  "exportName": "ContentReview",
@@ -4959,24 +5063,32 @@
4959
5063
  }
4960
5064
  },
4961
5065
  "indexes": [
4962
- {
4963
- "name": "content_reviews_id_idx",
4964
- "columns": [
4965
- "id"
4966
- ]
4967
- },
4968
5066
  {
4969
5067
  "name": "content_reviews_slug_context_idx",
4970
5068
  "columns": [
5069
+ "tenant_id",
4971
5070
  "slug",
4972
5071
  "context"
4973
5072
  ],
4974
5073
  "unique": true
4975
5074
  },
4976
5075
  {
4977
- "name": "content_reviews_tenant_id_idx",
5076
+ "name": "content_reviews_tenant_id_created_at_idx",
5077
+ "columns": [
5078
+ "tenant_id",
5079
+ "created_at"
5080
+ ]
5081
+ },
5082
+ {
5083
+ "name": "content_reviews_content_id_idx",
4978
5084
  "columns": [
4979
- "tenant_id"
5085
+ "content_id"
5086
+ ]
5087
+ },
5088
+ {
5089
+ "name": "content_reviews_content_version_id_idx",
5090
+ "columns": [
5091
+ "content_version_id"
4980
5092
  ]
4981
5093
  }
4982
5094
  ],
@@ -5121,12 +5233,6 @@
5121
5233
  }
5122
5234
  },
5123
5235
  "indexes": [
5124
- {
5125
- "name": "content_reviews_id_idx",
5126
- "columns": [
5127
- "id"
5128
- ]
5129
- },
5130
5236
  {
5131
5237
  "name": "content_reviews_slug_context_idx",
5132
5238
  "columns": [
@@ -5134,6 +5240,12 @@
5134
5240
  "context"
5135
5241
  ],
5136
5242
  "unique": true
5243
+ },
5244
+ {
5245
+ "name": "content_reviews_created_at_idx",
5246
+ "columns": [
5247
+ "created_at"
5248
+ ]
5137
5249
  }
5138
5250
  ],
5139
5251
  "version": "03b7d1d3"
@@ -6601,7 +6713,7 @@
6601
6713
  ],
6602
6714
  "schema": {
6603
6715
  "tableName": "contents",
6604
- "ddl": "CREATE TABLE IF NOT EXISTS \"contents\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"_meta_type\" TEXT NOT NULL,\n \"_meta_data\" JSON,\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID,\n \"type\" TEXT,\n \"variant\" TEXT,\n \"file_key\" TEXT,\n \"author\" TEXT,\n \"name\" TEXT DEFAULT '',\n \"title\" TEXT,\n \"description\" TEXT,\n \"body\" TEXT,\n \"body_format\" TEXT,\n \"publish_date\" TIMESTAMP,\n \"url\" TEXT,\n \"source\" TEXT,\n \"original_url\" TEXT,\n \"language\" TEXT,\n \"tags\" JSON DEFAULT '[]',\n \"category\" TEXT,\n \"status\" TEXT DEFAULT 'draft',\n \"state\" TEXT DEFAULT 'active',\n \"metadata\" JSON DEFAULT '{}',\n \"thumbnail_asset_id\" UUID\n);",
6716
+ "ddl": "CREATE TABLE IF NOT EXISTS \"contents\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"_meta_type\" TEXT NOT NULL,\n \"_meta_data\" JSON,\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID,\n \"type\" TEXT,\n \"variant\" TEXT,\n \"file_key\" TEXT,\n \"author\" TEXT,\n \"name\" TEXT DEFAULT '',\n \"title\" TEXT,\n \"description\" TEXT,\n \"body\" TEXT,\n \"body_format\" TEXT,\n \"publish_date\" TIMESTAMP,\n \"url\" TEXT,\n \"source\" TEXT,\n \"original_url\" TEXT,\n \"language\" TEXT,\n \"tags\" JSON DEFAULT '[]',\n \"category\" TEXT,\n \"status\" TEXT DEFAULT 'draft',\n \"state\" TEXT DEFAULT 'active',\n \"metadata\" JSON DEFAULT '{}',\n \"thumbnail_asset_id\" UUID,\n \"feed_source_id\" UUID,\n \"source_guid\" TEXT,\n \"source_name\" TEXT,\n \"source_homepage_url\" TEXT,\n \"external_url\" TEXT,\n \"original_published_at\" TIMESTAMP,\n \"dedupe_key\" TEXT\n);",
6605
6717
  "columns": {
6606
6718
  "id": {
6607
6719
  "type": "UUID",
@@ -6726,18 +6838,42 @@
6726
6838
  "type": "UUID",
6727
6839
  "referenceKind": "crossPackageRef",
6728
6840
  "notNull": false
6841
+ },
6842
+ "feed_source_id": {
6843
+ "type": "UUID",
6844
+ "referenceKind": "foreignKey",
6845
+ "notNull": false
6846
+ },
6847
+ "source_guid": {
6848
+ "type": "TEXT",
6849
+ "notNull": false
6850
+ },
6851
+ "source_name": {
6852
+ "type": "TEXT",
6853
+ "notNull": false
6854
+ },
6855
+ "source_homepage_url": {
6856
+ "type": "TEXT",
6857
+ "notNull": false
6858
+ },
6859
+ "external_url": {
6860
+ "type": "TEXT",
6861
+ "notNull": false
6862
+ },
6863
+ "original_published_at": {
6864
+ "type": "TIMESTAMP",
6865
+ "notNull": false
6866
+ },
6867
+ "dedupe_key": {
6868
+ "type": "TEXT",
6869
+ "notNull": false
6729
6870
  }
6730
6871
  },
6731
6872
  "indexes": [
6732
- {
6733
- "name": "contents_id_idx",
6734
- "columns": [
6735
- "id"
6736
- ]
6737
- },
6738
6873
  {
6739
6874
  "name": "contents_slug_context_meta_type_idx",
6740
6875
  "columns": [
6876
+ "tenant_id",
6741
6877
  "slug",
6742
6878
  "context",
6743
6879
  "_meta_type"
@@ -6751,13 +6887,33 @@
6751
6887
  ]
6752
6888
  },
6753
6889
  {
6754
- "name": "contents_tenant_id_idx",
6890
+ "name": "contents_tenant_id_publish_date_idx",
6891
+ "columns": [
6892
+ "tenant_id",
6893
+ "publish_date"
6894
+ ]
6895
+ },
6896
+ {
6897
+ "name": "contents_tenant_id_created_at_idx",
6898
+ "columns": [
6899
+ "tenant_id",
6900
+ "created_at"
6901
+ ]
6902
+ },
6903
+ {
6904
+ "name": "contents_thumbnail_asset_id_idx",
6905
+ "columns": [
6906
+ "thumbnail_asset_id"
6907
+ ]
6908
+ },
6909
+ {
6910
+ "name": "contents_feed_source_id_idx",
6755
6911
  "columns": [
6756
- "tenant_id"
6912
+ "feed_source_id"
6757
6913
  ]
6758
6914
  }
6759
6915
  ],
6760
- "version": "bb95d001"
6916
+ "version": "e07be74e"
6761
6917
  }
6762
6918
  },
6763
6919
  "@happyvertical/smrt-content:ContentDocument": {
@@ -8222,7 +8378,7 @@
8222
8378
  ],
8223
8379
  "schema": {
8224
8380
  "tableName": "contents",
8225
- "ddl": "CREATE TABLE IF NOT EXISTS \"contents\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"_meta_type\" TEXT NOT NULL,\n \"_meta_data\" JSON,\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID,\n \"type\" TEXT,\n \"variant\" TEXT,\n \"file_key\" TEXT,\n \"author\" TEXT,\n \"name\" TEXT DEFAULT '',\n \"title\" TEXT,\n \"description\" TEXT,\n \"body\" TEXT,\n \"body_format\" TEXT,\n \"publish_date\" TIMESTAMP,\n \"url\" TEXT,\n \"source\" TEXT,\n \"original_url\" TEXT,\n \"language\" TEXT,\n \"tags\" JSON DEFAULT '[]',\n \"category\" TEXT,\n \"status\" TEXT DEFAULT 'draft',\n \"state\" TEXT DEFAULT 'active',\n \"metadata\" JSON DEFAULT '{}',\n \"thumbnail_asset_id\" UUID\n);",
8381
+ "ddl": "CREATE TABLE IF NOT EXISTS \"contents\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"_meta_type\" TEXT NOT NULL,\n \"_meta_data\" JSON,\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID,\n \"type\" TEXT,\n \"variant\" TEXT,\n \"file_key\" TEXT,\n \"author\" TEXT,\n \"name\" TEXT DEFAULT '',\n \"title\" TEXT,\n \"description\" TEXT,\n \"body\" TEXT,\n \"body_format\" TEXT,\n \"publish_date\" TIMESTAMP,\n \"url\" TEXT,\n \"source\" TEXT,\n \"original_url\" TEXT,\n \"language\" TEXT,\n \"tags\" JSON DEFAULT '[]',\n \"category\" TEXT,\n \"status\" TEXT DEFAULT 'draft',\n \"state\" TEXT DEFAULT 'active',\n \"metadata\" JSON DEFAULT '{}',\n \"thumbnail_asset_id\" UUID,\n \"feed_source_id\" UUID,\n \"source_guid\" TEXT,\n \"source_name\" TEXT,\n \"source_homepage_url\" TEXT,\n \"external_url\" TEXT,\n \"original_published_at\" TIMESTAMP,\n \"dedupe_key\" TEXT\n);",
8226
8382
  "columns": {
8227
8383
  "id": {
8228
8384
  "type": "UUID",
@@ -8347,18 +8503,42 @@
8347
8503
  "type": "UUID",
8348
8504
  "referenceKind": "crossPackageRef",
8349
8505
  "notNull": false
8506
+ },
8507
+ "feed_source_id": {
8508
+ "type": "UUID",
8509
+ "referenceKind": "foreignKey",
8510
+ "notNull": false
8511
+ },
8512
+ "source_guid": {
8513
+ "type": "TEXT",
8514
+ "notNull": false
8515
+ },
8516
+ "source_name": {
8517
+ "type": "TEXT",
8518
+ "notNull": false
8519
+ },
8520
+ "source_homepage_url": {
8521
+ "type": "TEXT",
8522
+ "notNull": false
8523
+ },
8524
+ "external_url": {
8525
+ "type": "TEXT",
8526
+ "notNull": false
8527
+ },
8528
+ "original_published_at": {
8529
+ "type": "TIMESTAMP",
8530
+ "notNull": false
8531
+ },
8532
+ "dedupe_key": {
8533
+ "type": "TEXT",
8534
+ "notNull": false
8350
8535
  }
8351
8536
  },
8352
8537
  "indexes": [
8353
- {
8354
- "name": "contents_id_idx",
8355
- "columns": [
8356
- "id"
8357
- ]
8358
- },
8359
8538
  {
8360
8539
  "name": "contents_slug_context_meta_type_idx",
8361
8540
  "columns": [
8541
+ "tenant_id",
8362
8542
  "slug",
8363
8543
  "context",
8364
8544
  "_meta_type"
@@ -8372,13 +8552,33 @@
8372
8552
  ]
8373
8553
  },
8374
8554
  {
8375
- "name": "contents_tenant_id_idx",
8555
+ "name": "contents_tenant_id_publish_date_idx",
8376
8556
  "columns": [
8377
- "tenant_id"
8557
+ "tenant_id",
8558
+ "publish_date"
8559
+ ]
8560
+ },
8561
+ {
8562
+ "name": "contents_tenant_id_created_at_idx",
8563
+ "columns": [
8564
+ "tenant_id",
8565
+ "created_at"
8566
+ ]
8567
+ },
8568
+ {
8569
+ "name": "contents_thumbnail_asset_id_idx",
8570
+ "columns": [
8571
+ "thumbnail_asset_id"
8572
+ ]
8573
+ },
8574
+ {
8575
+ "name": "contents_feed_source_id_idx",
8576
+ "columns": [
8577
+ "feed_source_id"
8378
8578
  ]
8379
8579
  }
8380
8580
  ],
8381
- "version": "e246b9b1"
8581
+ "version": "e07be74e"
8382
8582
  }
8383
8583
  },
8384
8584
  "@happyvertical/smrt-content:Mirror": {
@@ -10029,15 +10229,10 @@
10029
10229
  }
10030
10230
  },
10031
10231
  "indexes": [
10032
- {
10033
- "name": "contents_id_idx",
10034
- "columns": [
10035
- "id"
10036
- ]
10037
- },
10038
10232
  {
10039
10233
  "name": "contents_slug_context_meta_type_idx",
10040
10234
  "columns": [
10235
+ "tenant_id",
10041
10236
  "slug",
10042
10237
  "context",
10043
10238
  "_meta_type"
@@ -10051,13 +10246,33 @@
10051
10246
  ]
10052
10247
  },
10053
10248
  {
10054
- "name": "contents_tenant_id_idx",
10249
+ "name": "contents_tenant_id_publish_date_idx",
10055
10250
  "columns": [
10056
- "tenant_id"
10251
+ "tenant_id",
10252
+ "publish_date"
10253
+ ]
10254
+ },
10255
+ {
10256
+ "name": "contents_tenant_id_created_at_idx",
10257
+ "columns": [
10258
+ "tenant_id",
10259
+ "created_at"
10260
+ ]
10261
+ },
10262
+ {
10263
+ "name": "contents_thumbnail_asset_id_idx",
10264
+ "columns": [
10265
+ "thumbnail_asset_id"
10266
+ ]
10267
+ },
10268
+ {
10269
+ "name": "contents_feed_source_id_idx",
10270
+ "columns": [
10271
+ "feed_source_id"
10057
10272
  ]
10058
10273
  }
10059
10274
  ],
10060
- "version": "f91f958a"
10275
+ "version": "e07be74e"
10061
10276
  }
10062
10277
  },
10063
10278
  "@happyvertical/smrt-content:ContentVersion": {
@@ -10312,12 +10527,6 @@
10312
10527
  }
10313
10528
  },
10314
10529
  "indexes": [
10315
- {
10316
- "name": "content_versions_id_idx",
10317
- "columns": [
10318
- "id"
10319
- ]
10320
- },
10321
10530
  {
10322
10531
  "name": "content_versions_content_id_version_idx",
10323
10532
  "columns": [
@@ -10327,9 +10536,17 @@
10327
10536
  "unique": true
10328
10537
  },
10329
10538
  {
10330
- "name": "content_versions_tenant_id_idx",
10539
+ "name": "content_versions_slug_context_idx",
10331
10540
  "columns": [
10332
- "tenant_id"
10541
+ "slug",
10542
+ "context"
10543
+ ]
10544
+ },
10545
+ {
10546
+ "name": "content_versions_tenant_id_created_at_idx",
10547
+ "columns": [
10548
+ "tenant_id",
10549
+ "created_at"
10333
10550
  ]
10334
10551
  }
10335
10552
  ],
@@ -10497,12 +10714,6 @@
10497
10714
  }
10498
10715
  },
10499
10716
  "indexes": [
10500
- {
10501
- "name": "content_versions_id_idx",
10502
- "columns": [
10503
- "id"
10504
- ]
10505
- },
10506
10717
  {
10507
10718
  "name": "content_versions_slug_context_idx",
10508
10719
  "columns": [
@@ -10510,6 +10721,12 @@
10510
10721
  "context"
10511
10722
  ],
10512
10723
  "unique": true
10724
+ },
10725
+ {
10726
+ "name": "content_versions_created_at_idx",
10727
+ "columns": [
10728
+ "created_at"
10729
+ ]
10513
10730
  }
10514
10731
  ],
10515
10732
  "version": "56acd806"
@@ -12079,9 +12296,24 @@
12079
12296
  ]
12080
12297
  },
12081
12298
  "cli": true,
12299
+ "indexes": [
12300
+ {
12301
+ "name": "contents_tenant_id_publish_date_idx",
12302
+ "columns": [
12303
+ "tenantId",
12304
+ "publish_date"
12305
+ ]
12306
+ }
12307
+ ],
12082
12308
  "tenantScoped": {
12083
12309
  "mode": "optional"
12084
- }
12310
+ },
12311
+ "conflictColumns": [
12312
+ "tenant_id",
12313
+ "slug",
12314
+ "context",
12315
+ "_meta_type"
12316
+ ]
12085
12317
  },
12086
12318
  "extends": "SmrtObject",
12087
12319
  "exportName": "Content",
@@ -12252,15 +12484,10 @@
12252
12484
  }
12253
12485
  },
12254
12486
  "indexes": [
12255
- {
12256
- "name": "contents_id_idx",
12257
- "columns": [
12258
- "id"
12259
- ]
12260
- },
12261
12487
  {
12262
12488
  "name": "contents_slug_context_meta_type_idx",
12263
12489
  "columns": [
12490
+ "tenant_id",
12264
12491
  "slug",
12265
12492
  "context",
12266
12493
  "_meta_type"
@@ -12274,9 +12501,29 @@
12274
12501
  ]
12275
12502
  },
12276
12503
  {
12277
- "name": "contents_tenant_id_idx",
12504
+ "name": "contents_tenant_id_publish_date_idx",
12505
+ "columns": [
12506
+ "tenant_id",
12507
+ "publish_date"
12508
+ ]
12509
+ },
12510
+ {
12511
+ "name": "contents_tenant_id_created_at_idx",
12512
+ "columns": [
12513
+ "tenant_id",
12514
+ "created_at"
12515
+ ]
12516
+ },
12517
+ {
12518
+ "name": "contents_thumbnail_asset_id_idx",
12519
+ "columns": [
12520
+ "thumbnail_asset_id"
12521
+ ]
12522
+ },
12523
+ {
12524
+ "name": "contents_feed_source_id_idx",
12278
12525
  "columns": [
12279
- "tenant_id"
12526
+ "feed_source_id"
12280
12527
  ]
12281
12528
  }
12282
12529
  ],
@@ -12552,12 +12799,6 @@
12552
12799
  }
12553
12800
  },
12554
12801
  "indexes": [
12555
- {
12556
- "name": "contents_id_idx",
12557
- "columns": [
12558
- "id"
12559
- ]
12560
- },
12561
12802
  {
12562
12803
  "name": "contents_slug_context_idx",
12563
12804
  "columns": [
@@ -12565,6 +12806,12 @@
12565
12806
  "context"
12566
12807
  ],
12567
12808
  "unique": true
12809
+ },
12810
+ {
12811
+ "name": "contents_created_at_idx",
12812
+ "columns": [
12813
+ "created_at"
12814
+ ]
12568
12815
  }
12569
12816
  ],
12570
12817
  "version": "c11f9ec0"