-- SPDX-FileCopyrightText: 2022 Gregor Kleen <gregor.kleen@ifi.lmu.de>
--
-- SPDX-License-Identifier: AGPL-3.0-or-later

ExternalExam
  term TermId
  school SchoolId
  courseName (CI Text)
  examName (CI Text)
  defaultTime UTCTime Maybe
  gradingMode ExamGradingMode
  UniqueExternalExam term school courseName examName
  deriving Generic
ExternalExamResult
  user UserId
  exam ExternalExamId
  result ExamResultPassedGrade
  time UTCTime
  lastChanged UTCTime
  UniqueExternalExamResult exam user
  deriving Eq Ord Show Generic
ExternalExamStaff
  user UserId
  exam ExternalExamId
  UniqueExternalExamStaff exam user
  deriving Generic
ExternalExamOfficeSchool
  school SchoolId
  exam ExternalExamId
  UniqueExternalExamOfficeSchool exam school
  deriving Generic