Plan stuff. Log stuff.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
617 B

4 years ago
  1. package repositories
  2. import (
  3. "context"
  4. "github.com/gisle/stufflog/models"
  5. )
  6. type PeriodRepository interface {
  7. FindID(ctx context.Context, id string) (*models.Period, error)
  8. List(ctx context.Context) ([]*models.Period, error)
  9. ListUser(ctx context.Context, user models.User) ([]*models.Period, error)
  10. ListActivity(ctx context.Context, activity models.Activity) ([]*models.Period, error)
  11. Insert(ctx context.Context, period models.Period) error
  12. Update(ctx context.Context, period models.Period, updates []*models.PeriodUpdate) (*models.Period, error)
  13. Remove(ctx context.Context, period models.Period) error
  14. }