atas/docs/schema.dbml
2025-01-14 23:15:37 +01:00

61 lines
1.2 KiB
Plaintext

//// ------------------------------------------------------
//// THIS FILE WAS AUTOMATICALLY GENERATED (DO NOT MODIFY)
//// ------------------------------------------------------
Project "AssetFlow" {
database_type: ''
Note: ''
}
Table AlarmContacts {
id Int [pk, increment]
name String [not null]
phone String [unique, not null]
comment String
Prios Priorities [not null]
}
Table Priorities {
id Int [pk, increment]
Contact AlarmContacts [not null]
contactId Int [not null]
priority Int [not null]
actionplan ActionPlan [not null]
actionplanId Int [not null]
indexes {
(priority, actionplanId) [unique]
}
}
Table ActionPlan {
id Int [pk, increment]
name String [not null]
comment String
prio Priorities [not null]
content Content [not null]
}
Table Content {
id Int [pk, increment]
type contentType [not null]
name String [not null]
filename String [not null]
actionplan ActionPlan [not null]
}
Table ActionPlanToContent {
contentId Int [ref: > Content.id]
actionplanId Int [ref: > ActionPlan.id]
}
Enum contentType {
voice_alarm
voice_explainer
voice_acknowledgement
voice_ending
}
Ref: Priorities.contactId > AlarmContacts.id
Ref: Priorities.actionplanId > ActionPlan.id