mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-04 15:07:13 +01:00
fiddle on schema
This commit is contained in:
@@ -0,0 +1,7 @@
|
|||||||
|
-- AlterTable
|
||||||
|
ALTER TABLE "Bill" ALTER COLUMN "createdAt" SET DATA TYPE TIMESTAMP(3),
|
||||||
|
ALTER COLUMN "updatedAt" SET DATA TYPE TIMESTAMP(3);
|
||||||
|
|
||||||
|
-- AlterTable
|
||||||
|
ALTER TABLE "Booking" ALTER COLUMN "createdAt" SET DATA TYPE TIMESTAMP(3),
|
||||||
|
ALTER COLUMN "updatedAt" SET DATA TYPE TIMESTAMP(3);
|
||||||
@@ -22,8 +22,8 @@ enum BillStatus {
|
|||||||
|
|
||||||
model Bill {
|
model Bill {
|
||||||
id Int @id @default(autoincrement())
|
id Int @id @default(autoincrement())
|
||||||
createdAt DateTime @default(now()) @db.Date
|
createdAt DateTime @default(now())
|
||||||
updatedAt DateTime @updatedAt @db.Date
|
updatedAt DateTime @updatedAt
|
||||||
milageEnd Int
|
milageEnd Int
|
||||||
milageStart Int
|
milageStart Int
|
||||||
status BillStatus @default(UNINVOICED)
|
status BillStatus @default(UNINVOICED)
|
||||||
@@ -42,8 +42,8 @@ enum BookingStatus {
|
|||||||
model Booking {
|
model Booking {
|
||||||
id String @id @default(uuid())
|
id String @id @default(uuid())
|
||||||
uuid String @unique @default(uuid())
|
uuid String @unique @default(uuid())
|
||||||
createdAt DateTime @default(now()) @db.Date
|
createdAt DateTime @default(now())
|
||||||
updatedAt DateTime @updatedAt @db.Date
|
updatedAt DateTime @updatedAt
|
||||||
bill Bill? @relation(fields: [billId], references: [id], onDelete: Cascade)
|
bill Bill? @relation(fields: [billId], references: [id], onDelete: Cascade)
|
||||||
billId Int? @unique
|
billId Int? @unique
|
||||||
calendarEventId String?
|
calendarEventId String?
|
||||||
|
|||||||
Reference in New Issue
Block a user