added friendly names to db

This commit is contained in:
ryzetech 2023-01-20 08:58:52 +01:00
parent feb82b5870
commit e704f43648
2 changed files with 7 additions and 5 deletions

2
app.js
View file

@ -82,7 +82,7 @@ async function loop() {
let update = await prisma.space.upsert({ let update = await prisma.space.upsert({
where: { id: space.id }, where: { id: space.id },
update: { open: o }, update: { open: o },
create: { id: space.id, open: o } create: { id: space.id, open: o, name: space.name }
}); });
} }
} }

View file

@ -11,7 +11,9 @@ datasource db {
} }
model Space { model Space {
id String @id id String @id
open Boolean name String?
updatedAt DateTime @updatedAt open Boolean
} lastChange DateTime?
updatedAt DateTime @updatedAt
}