mirror of
https://github.com/Drop-OSS/drop.git
synced 2025-11-13 08:12:40 +10:00
feat(DB): Updated DB for news articles to be stored in the DB
This commit is contained in:
13
prisma/schema/news.prisma
Normal file
13
prisma/schema/news.prisma
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
model News {
|
||||||
|
id String @id @default(uuid())
|
||||||
|
title String
|
||||||
|
content String @db.Text
|
||||||
|
excerpt String
|
||||||
|
tags String[]
|
||||||
|
image String?
|
||||||
|
publishedAt DateTime @default(now())
|
||||||
|
author User @relation(fields: [authorId], references: [id])
|
||||||
|
authorId String
|
||||||
|
|
||||||
|
@@map("news")
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user