package model import ( "github.com/google/uuid" "mangezmieux-backend/internal/model" ) type UserRight struct { UserRole []*UserRole `json:"userRole"` } type Resource struct { Id uuid.UUID `json:"id"` Name string `json:"name"` model.Metadata } type RoleVerbResource struct { Id uuid.UUID `json:"id"` Verb string `json:"verb"` RoleId uuid.UUID `json:"role"` ResourceId uuid.UUID `json:"resource"` model.Metadata } type RoleEditable struct { Id uuid.UUID `json:"id"` Name string `json:"name"` model.Metadata } type Role struct { RoleEditable ResourceVerb map[string][]*Verb } type Verb struct { Id uuid.UUID `json:"id"` Verb string `json:"verb"` model.Metadata } type UserRole struct { Id uuid.UUID `json:"id"` RoleId uuid.UUID `json:"role"` UserId uuid.UUID `json:"user"` model.Metadata }