role.go 220 B

12345678910111213
  1. package role
  2. import (
  3. "github.com/qor5/x/perm"
  4. "gorm.io/gorm"
  5. )
  6. type Role struct {
  7. gorm.Model
  8. Name string `gorm:"unique"`
  9. Permissions []*perm.DefaultDBPolicy `gorm:"foreignKey:ReferID"`
  10. }