datasource db { provider = "sqlite" // Wasp requires that the url is set to the DATABASE_URL environment variable. // For production deployment switch provider to "postgresql" (SQLite is unsupported in prod). url = env("DATABASE_URL") } // Wasp requires the `prisma-client-js` generator to be present. generator client { provider = "prisma-client-js" } model User { id Int @id @default(autoincrement()) specs Spec[] } model Spec { id Int @id @default(autoincrement()) title String createdAt DateTime @default(now()) updatedAt DateTime @updatedAt sections Section[] user User @relation(fields: [userId], references: [id]) userId Int } model Section { id Int @id @default(autoincrement()) key String title String hint String content String order Int spec Spec @relation(fields: [specId], references: [id], onDelete: Cascade) specId Int @@unique([specId, key]) }