33 lines
728 B
Plaintext
33 lines
728 B
Plaintext
datasource db {
|
|
provider = "postgresql"
|
|
url = env("DATABASE_URL")
|
|
}
|
|
|
|
generator client {
|
|
provider = "prisma-client-js"
|
|
}
|
|
|
|
model Post {
|
|
id Int @id @default(autoincrement())
|
|
slug String @unique @db.Text
|
|
title String @db.Text
|
|
contentRendered Json @db.Json
|
|
contentMarkdown String @db.Text
|
|
blurb String @db.Text
|
|
publishedDate DateTime @db.Timestamp(6)
|
|
is_draft Boolean
|
|
tags Tag[]
|
|
}
|
|
|
|
model Tag {
|
|
id Int @id @default(autoincrement())
|
|
name String @unique
|
|
posts Post[]
|
|
}
|
|
|
|
model User {
|
|
id Int @id @default(autoincrement())
|
|
username String @unique
|
|
password String
|
|
}
|