22 lines
696 B
Go
22 lines
696 B
Go
package outbound
|
|
|
|
import (
|
|
"context"
|
|
"errors"
|
|
|
|
"github.com/google/uuid"
|
|
|
|
"lincodex/backend/internal/domain"
|
|
)
|
|
|
|
var ErrPrivacyCohortUnavailable = errors.New("anonymous candidate cohort unavailable")
|
|
|
|
// PrivacyCohortRepository reads the candidates eligible for one
|
|
// organization-scoped anonymous projection. The caller must first authorize
|
|
// an active organization membership. The adapter must select from
|
|
// candidate_effective_publications and exclude the reading organization's
|
|
// hidden candidates in the same SQL statement.
|
|
type PrivacyCohortRepository interface {
|
|
ListVisibleCandidateViewSources(ctx context.Context, organizationID uuid.UUID) ([]domain.CandidateViewSource, error)
|
|
}
|