package tables import ( "gorm.io/gorm" ) type Role struct { gorm.Model Name string `gorm:"uniqueIndex;" json:"name"` Key string `gorm:"uniqueIndex;" json:"key"` Users []User `gorm:"many2many:role_user"` }