Documentation
¶
Index ¶
- type AsanaService
- func (a *AsanaService) CreateComment(msg entities.Message) error
- func (a *AsanaService) GetTaskName(mention *entities.TaskMention) (string, error)
- func (a *AsanaService) GetTaskShortLink(mention *entities.TaskMention) (string, error)
- func (a *AsanaService) UpdateCustomField(mention *entities.TaskMention, customFieldName, value string) error
- func (a *AsanaService) UpdateLastCommitInfo(msg entities.Message) error
- type ITaskManager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AsanaService ¶
type AsanaService struct {
// contains filtered or unexported fields
}
func NewAsanaService ¶
func NewAsanaService( apiKey string, l *zerolog.Logger, cfg *config.HTTPAPI, ff *config.FeatureFlags, ) *AsanaService
NewAsanaService creates a new instance of the Asana service
func (*AsanaService) CreateComment ¶
func (a *AsanaService) CreateComment(msg entities.Message) error
func (*AsanaService) GetTaskName ¶
func (a *AsanaService) GetTaskName(mention *entities.TaskMention) (string, error)
func (*AsanaService) GetTaskShortLink ¶
func (a *AsanaService) GetTaskShortLink(mention *entities.TaskMention) (string, error)
func (*AsanaService) UpdateCustomField ¶
func (a *AsanaService) UpdateCustomField(mention *entities.TaskMention, customFieldName, value string) error
func (*AsanaService) UpdateLastCommitInfo ¶
func (a *AsanaService) UpdateLastCommitInfo(msg entities.Message) error
type ITaskManager ¶
type ITaskManager interface {
// UpdateCustomField updates the custom field of a task
UpdateCustomField(mention *entities.TaskMention, customFieldName string, value string) error
// CreateComment creates a comment on all message related tasks
CreateComment(msg entities.Message) error
// UpdateLastCommitInfo updates the last commit info of a task
// via custom field or creating a comment
UpdateLastCommitInfo(msg entities.Message) error
// GetTaskShortLink returns the short link of a task
//
// todo: can be united with GetTaskName if update the api of the golang asana client
// now doesn't use the asana client, creates only with the task_id
GetTaskShortLink(mention *entities.TaskMention) (string, error)
// GetTaskName returns the name of a task
GetTaskName(mention *entities.TaskMention) (string, error)
}
ITaskManager is the interface for the task manager
Implementations: AsanaService
Click to show internal directories.
Click to hide internal directories.