Improve model and add roles
This commit is contained in:
parent
c8fedfbc8a
commit
455930b4c2
5 changed files with 32 additions and 38 deletions
|
|
@ -2,16 +2,12 @@ package models
|
|||
|
||||
import "gorm.io/gorm"
|
||||
|
||||
type ParentSection struct {
|
||||
gorm.Model
|
||||
Name string
|
||||
ShortName string
|
||||
}
|
||||
|
||||
type Section struct {
|
||||
gorm.Model
|
||||
Name string
|
||||
ShortName string
|
||||
ParentSectionID uint
|
||||
ParentSection ParentSection
|
||||
Name string
|
||||
ShortName string
|
||||
ParentSectionID uint
|
||||
ParentSection *Section
|
||||
ContainsMembers bool
|
||||
ContainsContacts bool
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue