Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CollectRepo ¶ added in v0.32.0
type CollectRepo interface {
// GetIndexCollect get and index colelct item if exists
GetIndexCollect(ctx context.Context, id model.IndexID, uid model.UserID) (*IndexCollect, error)
// AddIndexCollect add an index collect to given user
AddIndexCollect(ctx context.Context, id model.IndexID, uid model.UserID) error
// DeleteIndexCollect remove index collect from given user
DeleteIndexCollect(ctx context.Context, id model.IndexID, uid model.UserID) error
}
type IndexCollect ¶ added in v0.32.0
type Repo ¶ added in v0.30.3
type Repo interface {
IndexRepo
SubjectRepo
CollectRepo
}
type SubjectRepo ¶ added in v0.32.0
type SubjectRepo interface {
CountSubjects(ctx context.Context, id model.IndexID, subjectType model.SubjectType) (int64, error)
ListSubjects(
ctx context.Context, id model.IndexID, subjectType model.SubjectType, limit, offset int,
) ([]Subject, error)
AddOrUpdateIndexSubject(
ctx context.Context, id model.IndexID, subjectID model.SubjectID, sort uint32, comment string,
) (*Subject, error)
DeleteIndexSubject(
ctx context.Context, id model.IndexID, subjectID model.SubjectID,
) error
}
Click to show internal directories.
Click to hide internal directories.