application

package
v0.1.8 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service provides task business logic

func NewService

func NewService(repo domain.Repository, tagRepo tagdomain.Repository, logger *slog.Logger) *Service

NewService creates a new task service

func (*Service) AddChecklistItem added in v0.1.7

func (s *Service) AddChecklistItem(ctx context.Context, taskID uuid.UUID, content string) (*domain.ChecklistItem, error)

AddChecklistItem adds a checklist item to a task.

func (*Service) ArchiveTask added in v0.1.3

func (s *Service) ArchiveTask(ctx context.Context, id uuid.UUID) (*domain.Task, error)

ArchiveTask archives a task

func (*Service) CreateTask

func (s *Service) CreateTask(ctx context.Context, title, notes string, tagNames []string, startDate *time.Time, checklistItems []string) (*domain.Task, error)

CreateTask creates a new task

func (*Service) DeleteChecklistItem added in v0.1.7

func (s *Service) DeleteChecklistItem(ctx context.Context, itemID uuid.UUID) error

DeleteChecklistItem deletes a checklist item.

func (*Service) DeleteTask

func (s *Service) DeleteTask(ctx context.Context, id uuid.UUID) error

DeleteTask deletes a task

func (*Service) GetTask

func (s *Service) GetTask(ctx context.Context, id uuid.UUID) (*domain.Task, error)

GetTask retrieves a task by ID

func (*Service) ListTasks

func (s *Service) ListTasks(ctx context.Context, filterTagIDs []uuid.UUID, limit, offset int, includeArchived, archivedOnly bool) ([]*domain.Task, error)

ListTasks lists tasks

func (*Service) ReorderChecklistItems added in v0.1.7

func (s *Service) ReorderChecklistItems(ctx context.Context, taskID uuid.UUID, itemIDs []uuid.UUID) ([]domain.ChecklistItem, error)

ReorderChecklistItems sets a new checklist order for all task items.

func (*Service) SetChecklistItemCompleted added in v0.1.7

func (s *Service) SetChecklistItemCompleted(ctx context.Context, itemID uuid.UUID, completed bool) (*domain.ChecklistItem, error)

SetChecklistItemCompleted sets checklist item completion state.

func (*Service) UnarchiveTask added in v0.1.3

func (s *Service) UnarchiveTask(ctx context.Context, id uuid.UUID) (*domain.Task, error)

UnarchiveTask unarchives a task

func (*Service) UpdateChecklistItemContent added in v0.1.7

func (s *Service) UpdateChecklistItemContent(ctx context.Context, itemID uuid.UUID, content string) (*domain.ChecklistItem, error)

UpdateChecklistItemContent updates checklist item text.

func (*Service) UpdateTask

func (s *Service) UpdateTask(ctx context.Context, id uuid.UUID, title, notes string, tagNames []string, startDateProvided bool, startDate *time.Time) (*domain.Task, error)

UpdateTask updates a task

Jump to

Keyboard shortcuts

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