bins

package
v0.4.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 24, 2021 License: GPL-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package bins provides access to a project's ticket bins via the Lighthouse API. http://help.lighthouseapp.com/kb/api/ticket-bins.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bin

type Bin struct {
	Default      bool       `json:"default"`
	ID           int        `json:"id"`
	Name         string     `json:"name"`
	Position     int        `json:"position"`
	ProjectID    int        `json:"project_id"`
	Query        string     `json:"query"`
	Shared       bool       `json:"shared"`
	TicketsCount int        `json:"tickets_count"`
	UpdatedAt    *time.Time `json:"updated_at"`
	UserID       int        `json:"user_id"`
	Global       bool       `json:"global"`
}

type BinCreate

type BinCreate struct {
	Default bool   `json:"default"`
	Name    string `json:"name"`
	Query   string `json:"query"`
}

type BinUpdate

type BinUpdate struct {
	Default bool   `json:"default"`
	Name    string `json:"name"`
	Query   string `json:"query"`
}

type Bins

type Bins []*Bin

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(s *lighthouse.Service, projectID int) *Service

func (*Service) Create

func (s *Service) Create(b *Bin) (*Bin, error)

Only the fields in BinCreate can be set.

func (*Service) Delete

func (s *Service) Delete(idOrName string) error

func (*Service) DeleteByID added in v0.4.1

func (s *Service) DeleteByID(id int) error

func (*Service) DeleteByName added in v0.4.1

func (s *Service) DeleteByName(name string) error

func (*Service) Get

func (s *Service) Get(idOrName string) (*Bin, error)

func (*Service) GetByID added in v0.4.1

func (s *Service) GetByID(id int) (*Bin, error)

func (*Service) GetByName added in v0.4.1

func (s *Service) GetByName(name string) (*Bin, error)

func (*Service) List

func (s *Service) List() (Bins, error)

func (*Service) Update

func (s *Service) Update(b *Bin) error

Only the fields in BinUpdate can be set.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL