Start working on the database creation. throw the endpoint with the unique generatedId.

This commit is contained in:
charles-gauthereau
2024-11-27 19:44:16 +01:00
parent 7adaa44c98
commit 319662e39c
5 changed files with 127 additions and 37 deletions
+4 -2
View File
@@ -100,12 +100,14 @@ model Database {
id String @id @default(cuid())
name String
dbms Dbms
generatedId String @unique
description String?
backupPolicy String? @map("backup_policy")
createdAt DateTime @default(now()) @map("created_at")
agentId String @map("agent_id")
agent Agent @relation(fields: [agentId], references: [id], onDelete: Cascade)
agentId String @map("agent_id")
agent Agent @relation(fields: [agentId], references: [id], onDelete: Cascade)
lastContact DateTime? @map("last_contact")
backups Backup[]
restaurations Restauration[]