54 lines
1.0 KiB
Plaintext
54 lines
1.0 KiB
Plaintext
// This is your Prisma schema file,
|
|
// learn more about it in the docs: https://pris.ly/d/prisma-schema
|
|
|
|
generator client {
|
|
provider = "prisma-client-js"
|
|
binaryTargets = ["native", "debian-openssl-3.0.x"]
|
|
}
|
|
|
|
datasource db {
|
|
provider = "postgresql"
|
|
url = env("DATABASE_URL")
|
|
}
|
|
|
|
model User {
|
|
id String @id
|
|
name String
|
|
color String
|
|
|
|
inventory Inventory @relation(fields: [inventoryId], references: [id])
|
|
inventoryId Int @unique
|
|
}
|
|
|
|
model Inventory {
|
|
id Int @id @default(autoincrement())
|
|
balance Int @default(0)
|
|
location String @default("pond")
|
|
|
|
items Json @default("[]")
|
|
fishSack Json @default("[]")
|
|
pokemon Json @default("[]")
|
|
|
|
user User?
|
|
}
|
|
|
|
model AuthToken {
|
|
id Int @id @default(autoincrement())
|
|
token String @unique
|
|
}
|
|
|
|
model LocationObjectStorage {
|
|
id String @id
|
|
objects Json @default("[]")
|
|
}
|
|
|
|
model KeyValueStore {
|
|
id Int @id @default(0)
|
|
json Json @default("{}")
|
|
}
|
|
|
|
model UserPermission {
|
|
userId String @id @unique
|
|
groupId String
|
|
}
|