feat(platform): add the notification inbox and deterministic match search
This commit is contained in:
1 parent
5edff21d2d
commit
0b11021b16
169 files changed
+17083
-443
No files matched your search
@@ -37,6 +37,20 @@ func EvidencePositionOf(fact domain.EvidenceFact) EvidencePosition {
|
||||
return EvidencePosition{OccurredAt: snapshot.OccurredAt, ID: snapshot.ID}
|
||||
}
|
||||
|
||||
// EvidenceCandidateCategories names the categories that the card of one
|
||||
// candidate shows, which are the categories whose supporting facts a batch
|
||||
// read may return.
|
||||
type EvidenceCandidateCategories struct {
|
||||
CandidateID uuid.UUID
|
||||
Categories []domain.CandidateViewCategory
|
||||
}
|
||||
|
||||
// CategoryKey is a specialization and a grade.
|
||||
type CategoryKey struct {
|
||||
Specialization domain.SpecializationCode
|
||||
Grade domain.GradeCode
|
||||
}
|
||||
|
||||
// EvidenceRepository reads the skill evidence projection. It never reads an
|
||||
// assessment result, answer, attempt, or review: the projection is the only
|
||||
// source, so no answer, failure, or anti-cheat datum can reach a caller.
|
||||
@@ -59,6 +73,24 @@ type EvidenceRepository interface {
|
||||
categories []domain.CandidateViewCategory,
|
||||
) ([]domain.EvidenceOrganizationFact, error)
|
||||
|
||||
// ListOrganizationFactsBatch is ListOrganizationFacts for many candidates in
|
||||
// one statement, with the same barriers: the effective publication view,
|
||||
// the exclusion of the candidates that hide the organization, the
|
||||
// categories field, and only visible measurements. A candidate with no
|
||||
// permitted fact has no entry in the result. The result is for the caller's
|
||||
// grouping and is never returned as it is.
|
||||
ListOrganizationFactsBatch(
|
||||
ctx context.Context,
|
||||
organizationID uuid.UUID,
|
||||
requests []EvidenceCandidateCategories,
|
||||
) (map[uuid.UUID][]domain.EvidenceOrganizationFact, error)
|
||||
|
||||
// CountComparableRealCategories returns, for each given category, how many
|
||||
// candidates hold it from a source that is not a synthetic demonstration:
|
||||
// the size of the comparable real cohort. A category nobody holds from a
|
||||
// real source is absent. It returns counts only.
|
||||
CountComparableRealCategories(ctx context.Context, categories []CategoryKey) (map[CategoryKey]int64, error)
|
||||
|
||||
// ListPreviewFacts returns the same selection for the candidate's own card
|
||||
// preview. It applies no organization and no cohort, and the caller has
|
||||
// locked the effective C2 and publication.
|
||||
|
||||
Reference in new issue
Block a user