44 lines
1.6 KiB
Plaintext
44 lines
1.6 KiB
Plaintext
model service {
|
|
id BigInt @id @default(autoincrement())
|
|
date_orig BigInt?
|
|
date_suspended BigInt?
|
|
date_next_invoice BigInt?
|
|
date_last_invoice BigInt?
|
|
delivery_id Int?
|
|
device_id Int @default(0) @db.UnsignedInt
|
|
product_id Int?
|
|
comment String? @db.VarChar(255)
|
|
payment_recurrence Int? @db.TinyInt
|
|
status Int? @db.TinyInt
|
|
hijack Int @default(0) @db.TinyInt
|
|
hijack_price Float @default(0)
|
|
hijack_desc String? @db.VarChar(512)
|
|
hijack_download_speed BigInt?
|
|
hijack_upload_speed BigInt?
|
|
hijack_quota_day BigInt?
|
|
hijack_quota_night BigInt?
|
|
date_end_contract BigInt?
|
|
actif_until BigInt?
|
|
forfait_internet Int @default(0) @db.TinyInt
|
|
radius_user String @db.VarChar(24)
|
|
radius_pwd String @db.VarChar(16)
|
|
radius_conso Boolean @default(false)
|
|
|
|
@@index([date_orig], map: "date_orig")
|
|
@@index([delivery_id], map: "delivery_id")
|
|
@@index([device_id], map: "device_id")
|
|
@@index([id, status], map: "id")
|
|
@@index([product_id], map: "product_id")
|
|
}
|
|
|
|
model service_snapshot {
|
|
id Int @id @default(autoincrement()) @db.UnsignedInt
|
|
date BigInt @db.UnsignedBigInt
|
|
account_id Int @db.UnsignedInt
|
|
service_id Int @db.UnsignedInt
|
|
quota_day BigInt @default(0) @db.UnsignedBigInt
|
|
quota_night BigInt @default(0) @db.UnsignedBigInt
|
|
|
|
@@index([account_id], map: "account_id")
|
|
@@index([service_id], map: "service_id")
|
|
} |