feat: reklam arastirma modullerini etkinlestir

This commit is contained in:
2026-08-09 08:54:42 +03:00
parent d29e2ecc6f
commit 4b4e00c6ee
10 changed files with 319 additions and 19 deletions
+18
View File
@@ -122,6 +122,7 @@ model User {
savedAds SavedAd[]
filterPresets FilterPreset[]
trackedStores TrackedStore[]
trackedBrands TrackedBrand[]
exportJobs ExportJob[]
apiKeys ApiKey[]
creditTransactions CreditTransaction[] @relation("CreditOwner")
@@ -224,6 +225,7 @@ model BrandPage {
store Store? @relation(fields: [storeId], references: [id], onDelete: SetNull)
ads Ad[]
trackedBy TrackedBrand[]
@@unique([source, externalPageId])
@@index([websiteDomain])
@@ -517,6 +519,22 @@ model TrackedStore {
@@index([storeId])
}
model TrackedBrand {
id String @id @default(cuid())
userId String
brandPageId String
notes String?
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
brandPage BrandPage @relation(fields: [brandPageId], references: [id], onDelete: Cascade)
@@unique([userId, brandPageId])
@@index([userId])
@@index([brandPageId])
}
model FilterPreset {
id String @id @default(cuid())
userId String