package models import "context" type ProjectGroup struct { ID string `json:"id" db:"id"` UserID string `json:"-" db:"user_id"` Name string `json:"name" db:"name"` Abbreviation string `json:"abbreviation" db:"abbreviation"` CategoryNames map[string]string `json:"categoryNames" db:"category_names"` } type ProjectGroupUpdate struct { Name *string `json:"name"` Abbreviation *string `json:"abbreviation"` SetCategoryNames map[string]string `json:"setCategoryNames"` ResetCategoryName *string `json:"resetCategoryName"` } type ProjectGroupFilter struct { UserID string `json:"userId"` } type ProjectGroupRepository interface { Find(ctx context.Context, id string) (*ProjectGroup, error) List(ctx context.Context, filter ProjectGroupFilter) ([]*ProjectGroup, error) Insert(ctx context.Context, group ProjectGroup) error Update(ctx context.Context, group ProjectGroup) error Delete(ctx context.Context, group ProjectGroup) error }