From abb7e7bab3b6d832eff23574ae4c337cff2a736c Mon Sep 17 00:00:00 2001 From: grey Date: Sun, 9 Jul 2023 20:17:05 +0200 Subject: [PATCH] introduction of proper text length limiting --- prisma/schema.prisma | 5 +++-- src/frontend/items.eta.html | 10 +++++----- src/frontend/manage/categoryManager.eta.html | 4 ++-- src/frontend/manage/storageManager.eta.html | 2 +- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 3774d74..076058e 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -32,12 +32,13 @@ enum itemStatus { lost } +// comments and descriptions -> @db.VarChar(2048) model Item { id Int @id @unique @default(autoincrement()) SKU String? @unique amount Int @default(1) name String - comment String? + comment String? @db.VarChar(2048) status itemStatus @default(normal) /// TODO: Would it be better to create a separate model for this as well instead of providing several static statuses to choose from(enum)? contactInfo contactInfo? @relation(fields: [contactInfoId], references: [id]) @@ -81,7 +82,7 @@ model StorageUnit { model itemCategory { id Int @id @default(autoincrement()) name String @unique - description String? + description String? @db.VarChar(2048) Item Item[] } diff --git a/src/frontend/items.eta.html b/src/frontend/items.eta.html index 9487ebb..ec1078a 100644 --- a/src/frontend/items.eta.html +++ b/src/frontend/items.eta.html @@ -11,12 +11,12 @@