package quartermaster type Location struct { ID int `json:"id"` Name string `json:"name"` Description string `json:"description"` Parent *Location `json:"parent,omitempty"` } type LocationService interface { Location(int) (*Location, error) AddLocation(*Location) (*Location, error) UpdateLocation(*Location) error DeleteLocation(*Location) error GetChildren(*Location) ([]*Location, error) GetItems(*Location) (map[*Item]int, error) GetTopLocations() ([]*Location, error) }