memos/store/tag.go

32 lines
552 B
Go
Raw Normal View History

package store
import (
"context"
)
type Tag struct {
Name string
2023-08-04 16:55:07 +03:00
CreatorID int32
}
type FindTag struct {
2023-08-04 16:55:07 +03:00
CreatorID int32
}
type DeleteTag struct {
Name string
2023-08-04 16:55:07 +03:00
CreatorID int32
}
func (s *Store) UpsertTag(ctx context.Context, upsert *Tag) (*Tag, error) {
2023-09-26 14:37:22 +03:00
return s.driver.UpsertTag(ctx, upsert)
}
func (s *Store) ListTags(ctx context.Context, find *FindTag) ([]*Tag, error) {
2023-09-26 14:37:22 +03:00
return s.driver.ListTags(ctx, find)
}
func (s *Store) DeleteTag(ctx context.Context, delete *DeleteTag) error {
2023-09-26 14:37:22 +03:00
return s.driver.DeleteTag(ctx, delete)
}