diff --git a/prisma/migrations/20250417110704_notification_model/migration.sql b/prisma/migrations/20250417110704_notification_model/migration.sql new file mode 100644 index 0000000..b8c5876 --- /dev/null +++ b/prisma/migrations/20250417110704_notification_model/migration.sql @@ -0,0 +1,18 @@ +-- CreateTable +CREATE TABLE "notification" ( + "id" SERIAL NOT NULL, + "enabled" BOOLEAN NOT NULL DEFAULT true, + "type" TEXT NOT NULL, + "smtpHost" TEXT, + "smtpPort" INTEGER, + "smtpFrom" TEXT, + "smtpUser" TEXT, + "smtpPass" TEXT, + "smtpSecure" BOOLEAN, + "smtpTo" TEXT, + "telegramChatId" TEXT, + "telegramToken" TEXT, + "discordWebhook" TEXT, + + CONSTRAINT "notification_pkey" PRIMARY KEY ("id") +); diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 55fe57d..d963a67 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -53,4 +53,20 @@ model user { id String @id @default(uuid()) email String @unique password String +} + +model notification { + id Int @id @default(autoincrement()) + enabled Boolean @default(true) + type String + smtpHost String? + smtpPort Int? + smtpFrom String? + smtpUser String? + smtpPass String? + smtpSecure Boolean? + smtpTo String? + telegramChatId String? + telegramToken String? + discordWebhook String? } \ No newline at end of file