@creator.co/creatorco-prisma-client 1.0.34-alpha-925d6bb → 1.0.34
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.
- package/edge.js +42 -8
- package/index-browser.js +38 -4
- package/index.d.ts +7784 -2939
- package/index.js +42 -8
- package/package.json +1 -1
- package/schema.prisma +62 -18
- package/wasm.js +38 -4
package/package.json
CHANGED
package/schema.prisma
CHANGED
|
@@ -70,7 +70,7 @@ model User {
|
|
|
70
70
|
socialProfiles SocialProfile[]
|
|
71
71
|
rakutenActivity RakutenActivity[]
|
|
72
72
|
impactRadiusEvents ImpactRadiusEvent[]
|
|
73
|
-
|
|
73
|
+
|
|
74
74
|
@@index([phoneCode, phone])
|
|
75
75
|
@@map("user")
|
|
76
76
|
// @@fulltext([firstName, lastName])
|
|
@@ -344,7 +344,7 @@ model Brand {
|
|
|
344
344
|
sequences Sequence[]
|
|
345
345
|
impactRadiusEvents ImpactRadiusEvent[]
|
|
346
346
|
shopifyStores ShopifyStore[]
|
|
347
|
-
|
|
347
|
+
productLists ProductList[]
|
|
348
348
|
|
|
349
349
|
// for agencies
|
|
350
350
|
parentBrandId Int?
|
|
@@ -517,7 +517,8 @@ model Campaign {
|
|
|
517
517
|
categories CampaignToCategory[]
|
|
518
518
|
optIns OptIn[]
|
|
519
519
|
images CampaignToImage[]
|
|
520
|
-
variables
|
|
520
|
+
variables Variable[]
|
|
521
|
+
productLists CampaignToProductList[]
|
|
521
522
|
countries CampaignToCountry[]
|
|
522
523
|
campaignPins CampaignPin[]
|
|
523
524
|
socialPosts SocialPost[]
|
|
@@ -584,15 +585,59 @@ model CampaignToCountry {
|
|
|
584
585
|
@@map("campaigntocountry")
|
|
585
586
|
}
|
|
586
587
|
|
|
587
|
-
model
|
|
588
|
+
model ProductList {
|
|
589
|
+
id Int @id @default(autoincrement())
|
|
590
|
+
title String
|
|
591
|
+
description String? @db.Text
|
|
592
|
+
metaData Json @default("{}")
|
|
593
|
+
|
|
594
|
+
brandId Int
|
|
595
|
+
|
|
596
|
+
brand Brand @relation(fields: [brandId], references: [id], onDelete: Cascade)
|
|
597
|
+
|
|
598
|
+
items ProductListItem[]
|
|
599
|
+
campaignProductLists CampaignToProductList[]
|
|
600
|
+
|
|
601
|
+
@@index([brandId])
|
|
602
|
+
@@map("product_list")
|
|
603
|
+
}
|
|
604
|
+
|
|
605
|
+
model ProductListItem {
|
|
606
|
+
id Int @id @default(autoincrement())
|
|
607
|
+
title String
|
|
608
|
+
description String? @db.Text
|
|
609
|
+
metaData Json @default("{}")
|
|
610
|
+
|
|
611
|
+
productListId Int
|
|
612
|
+
productList ProductList @relation(fields: [productListId], references: [id], onDelete: Cascade)
|
|
613
|
+
optins OptinToProductListItem[]
|
|
614
|
+
|
|
615
|
+
@@index([productListId])
|
|
616
|
+
@@map("product_list_item")
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
model CampaignToProductList {
|
|
588
620
|
campaignId Int
|
|
589
|
-
|
|
621
|
+
productListId Int
|
|
590
622
|
|
|
591
623
|
campaign Campaign @relation(fields: [campaignId], references: [id], onDelete: Cascade)
|
|
592
|
-
|
|
624
|
+
productList ProductList @relation(fields: [productListId], references: [id])
|
|
625
|
+
|
|
626
|
+
@@id([campaignId, productListId])
|
|
627
|
+
@@index([productListId])
|
|
628
|
+
@@map("campaign_to_product_list")
|
|
629
|
+
}
|
|
593
630
|
|
|
594
|
-
|
|
595
|
-
|
|
631
|
+
model OptinToProductListItem {
|
|
632
|
+
optInId Int
|
|
633
|
+
productListItemId Int
|
|
634
|
+
|
|
635
|
+
optIn OptIn @relation(fields: [optInId], references: [id], onDelete: Cascade)
|
|
636
|
+
productListItem ProductListItem @relation(fields: [productListItemId], references: [id], onDelete: Cascade)
|
|
637
|
+
|
|
638
|
+
@@id([optInId, productListItemId])
|
|
639
|
+
@@index([productListItemId])
|
|
640
|
+
@@map("optin_to_product_list_item")
|
|
596
641
|
}
|
|
597
642
|
|
|
598
643
|
model Variable {
|
|
@@ -601,11 +646,9 @@ model Variable {
|
|
|
601
646
|
description String? @db.Text
|
|
602
647
|
metaData Json @default("{}")
|
|
603
648
|
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
brand Brand @relation(fields: [brandId], references: [id], onDelete: Cascade)
|
|
649
|
+
campaignId Int
|
|
607
650
|
|
|
608
|
-
|
|
651
|
+
campaign Campaign @relation(fields: [campaignId], references: [id], onDelete: Cascade)
|
|
609
652
|
|
|
610
653
|
options VariableOption[]
|
|
611
654
|
optInVariables OptInVariable[]
|
|
@@ -719,6 +762,7 @@ model OptIn {
|
|
|
719
762
|
campaignInvites CampaignInvite[]
|
|
720
763
|
trolleyPayments TrolleyPayment[]
|
|
721
764
|
affiliateClicks AffiliateClick[]
|
|
765
|
+
productListItems OptinToProductListItem[]
|
|
722
766
|
|
|
723
767
|
@@index([userId])
|
|
724
768
|
@@index([campaignId])
|
|
@@ -1255,7 +1299,7 @@ model ShopifyStore {
|
|
|
1255
1299
|
accessToken String? @map("access_token")
|
|
1256
1300
|
syncStatus ShopifyStoreSyncStatus @default(syncing) @map("sync_status")
|
|
1257
1301
|
lastSynced DateTime? @map("last_synced")
|
|
1258
|
-
metaData Json @default("{}") @map("meta_data")
|
|
1302
|
+
metaData Json @default("{}") @map("meta_data")
|
|
1259
1303
|
|
|
1260
1304
|
brandId Int @map("brand_id")
|
|
1261
1305
|
|
|
@@ -1281,14 +1325,14 @@ model ShopifyProduct {
|
|
|
1281
1325
|
imageUrl String @db.Text @map("image_url")
|
|
1282
1326
|
|
|
1283
1327
|
metaData Json @default("{}") @map("meta_data")
|
|
1284
|
-
|
|
1328
|
+
|
|
1285
1329
|
shopifyStoreId Int @map("shopify_store_id")
|
|
1286
1330
|
|
|
1287
1331
|
campaignToShopifyProducts CampaignToShopifyProduct[]
|
|
1288
1332
|
variations ShopifyProductVariation[]
|
|
1289
1333
|
|
|
1290
1334
|
shopifyStore ShopifyStore @relation(fields: [shopifyStoreId], references: [id], onDelete: Cascade)
|
|
1291
|
-
|
|
1335
|
+
|
|
1292
1336
|
@@map("shopify_product")
|
|
1293
1337
|
}
|
|
1294
1338
|
|
|
@@ -1299,11 +1343,11 @@ model ShopifyProductVariation {
|
|
|
1299
1343
|
imageUrl String @db.Text @map("image_url")
|
|
1300
1344
|
|
|
1301
1345
|
metaData Json @default("{}") @map("meta_data")
|
|
1302
|
-
|
|
1346
|
+
|
|
1303
1347
|
shopifyProductId Int @map("shopify_product_id")
|
|
1304
1348
|
|
|
1305
1349
|
shopifyProduct ShopifyProduct @relation(fields: [shopifyProductId], references: [id], onDelete: Cascade)
|
|
1306
|
-
|
|
1350
|
+
|
|
1307
1351
|
@@map("shopify_product_variation")
|
|
1308
1352
|
}
|
|
1309
1353
|
|
|
@@ -1316,4 +1360,4 @@ model CampaignToShopifyProduct {
|
|
|
1316
1360
|
|
|
1317
1361
|
@@id([campaignId, shopifyProductId])
|
|
1318
1362
|
@@map("campaign_to_shopify_product")
|
|
1319
|
-
}
|
|
1363
|
+
}
|
package/wasm.js
CHANGED
|
@@ -458,9 +458,30 @@ exports.Prisma.CampaignToCountryScalarFieldEnum = {
|
|
|
458
458
|
countryId: 'countryId'
|
|
459
459
|
};
|
|
460
460
|
|
|
461
|
-
exports.Prisma.
|
|
461
|
+
exports.Prisma.ProductListScalarFieldEnum = {
|
|
462
|
+
id: 'id',
|
|
463
|
+
title: 'title',
|
|
464
|
+
description: 'description',
|
|
465
|
+
metaData: 'metaData',
|
|
466
|
+
brandId: 'brandId'
|
|
467
|
+
};
|
|
468
|
+
|
|
469
|
+
exports.Prisma.ProductListItemScalarFieldEnum = {
|
|
470
|
+
id: 'id',
|
|
471
|
+
title: 'title',
|
|
472
|
+
description: 'description',
|
|
473
|
+
metaData: 'metaData',
|
|
474
|
+
productListId: 'productListId'
|
|
475
|
+
};
|
|
476
|
+
|
|
477
|
+
exports.Prisma.CampaignToProductListScalarFieldEnum = {
|
|
462
478
|
campaignId: 'campaignId',
|
|
463
|
-
|
|
479
|
+
productListId: 'productListId'
|
|
480
|
+
};
|
|
481
|
+
|
|
482
|
+
exports.Prisma.OptinToProductListItemScalarFieldEnum = {
|
|
483
|
+
optInId: 'optInId',
|
|
484
|
+
productListItemId: 'productListItemId'
|
|
464
485
|
};
|
|
465
486
|
|
|
466
487
|
exports.Prisma.VariableScalarFieldEnum = {
|
|
@@ -468,7 +489,7 @@ exports.Prisma.VariableScalarFieldEnum = {
|
|
|
468
489
|
title: 'title',
|
|
469
490
|
description: 'description',
|
|
470
491
|
metaData: 'metaData',
|
|
471
|
-
|
|
492
|
+
campaignId: 'campaignId'
|
|
472
493
|
};
|
|
473
494
|
|
|
474
495
|
exports.Prisma.VariableOptionScalarFieldEnum = {
|
|
@@ -1063,6 +1084,16 @@ exports.Prisma.CampaignToImageOrderByRelevanceFieldEnum = {
|
|
|
1063
1084
|
type: 'type'
|
|
1064
1085
|
};
|
|
1065
1086
|
|
|
1087
|
+
exports.Prisma.ProductListOrderByRelevanceFieldEnum = {
|
|
1088
|
+
title: 'title',
|
|
1089
|
+
description: 'description'
|
|
1090
|
+
};
|
|
1091
|
+
|
|
1092
|
+
exports.Prisma.ProductListItemOrderByRelevanceFieldEnum = {
|
|
1093
|
+
title: 'title',
|
|
1094
|
+
description: 'description'
|
|
1095
|
+
};
|
|
1096
|
+
|
|
1066
1097
|
exports.Prisma.VariableOrderByRelevanceFieldEnum = {
|
|
1067
1098
|
title: 'title',
|
|
1068
1099
|
description: 'description'
|
|
@@ -1286,7 +1317,10 @@ exports.Prisma.ModelName = {
|
|
|
1286
1317
|
CampaignToImage: 'CampaignToImage',
|
|
1287
1318
|
CampaignToCategory: 'CampaignToCategory',
|
|
1288
1319
|
CampaignToCountry: 'CampaignToCountry',
|
|
1289
|
-
|
|
1320
|
+
ProductList: 'ProductList',
|
|
1321
|
+
ProductListItem: 'ProductListItem',
|
|
1322
|
+
CampaignToProductList: 'CampaignToProductList',
|
|
1323
|
+
OptinToProductListItem: 'OptinToProductListItem',
|
|
1290
1324
|
Variable: 'Variable',
|
|
1291
1325
|
VariableOption: 'VariableOption',
|
|
1292
1326
|
Step: 'Step',
|