156 lines
3.9 KiB
Plaintext
156 lines
3.9 KiB
Plaintext
User
|
|
ident Text
|
|
password Text Maybe
|
|
UniqueUser ident
|
|
deriving Typeable
|
|
Email
|
|
email Text
|
|
userId UserId Maybe
|
|
verkey Text Maybe
|
|
UniqueEmail email
|
|
Comment json -- Adding "json" causes ToJSON and FromJSON instances to be derived.
|
|
message Text
|
|
userId UserId Maybe
|
|
deriving Eq
|
|
deriving Show
|
|
--
|
|
-- above from Template, needs editing
|
|
--
|
|
Term json
|
|
name Text
|
|
start UTCTime
|
|
end UTCTime
|
|
holidays [UTCTime]
|
|
UniqueTerm name
|
|
deriving Eq
|
|
School json
|
|
name Text
|
|
UniqueSchool name
|
|
deriving Eq
|
|
Degree json
|
|
name Text
|
|
schoolId SchoolId
|
|
UniqueDegree name schoolId
|
|
deriving Eq
|
|
DegreeCourse json
|
|
degreeId DegreeId
|
|
courseId CourseId
|
|
UniqueDegreeCourse degreeId courseId
|
|
Course json
|
|
name Text
|
|
owner UserId
|
|
schoolId SchoolId
|
|
termId TermId Maybe
|
|
capacity Int Maybe
|
|
created UTCTime
|
|
changed UTCTime
|
|
registerFrom UTCTime
|
|
registerTo UTCTime
|
|
Lecturer
|
|
userId UserId
|
|
courseId CourseId
|
|
UniqueLecturer userId courseId
|
|
CourseParticipant
|
|
userId UserId
|
|
courseId CourseId
|
|
registration UTCTime
|
|
UniqueCourseParticipant userId courseId
|
|
Sheet
|
|
courseId CourseId
|
|
name Text
|
|
sheetType SheetType
|
|
maxPoints Double Maybe
|
|
requiredPoints Double Maybe
|
|
exerciseId FileId Maybe
|
|
hintId FileId Maybe
|
|
solutionId FileId Maybe
|
|
markingId FileId Maybe
|
|
markingText Text
|
|
activeFrom UTCTime
|
|
activeTo UTCTime
|
|
hintFrom UTCTime Maybe
|
|
solutionFrom UTCTime Maybe
|
|
created UTCTime
|
|
changed UTCTime
|
|
createdBy UserId
|
|
changedBy UserId
|
|
File
|
|
title Text
|
|
content ByteString
|
|
Submission
|
|
sheetId SheetId
|
|
fileId FileId
|
|
updateId FileId Maybe
|
|
ratingBy UserId Maybe
|
|
ratingPoints Double Maybe
|
|
ratingComment Text Maybe
|
|
rated UTCTime Maybe
|
|
created UTCTime
|
|
changed UTCTime
|
|
createdBy UserId
|
|
changedBy UserId
|
|
SubmissionUser
|
|
userId UserId
|
|
submissionId SubmissionId
|
|
UniqueSubmissionUser userId submissionId
|
|
SubmissionGroup
|
|
courseId CourseId
|
|
name Text
|
|
created UTCTime
|
|
changed UTCTime
|
|
createdBy UserId
|
|
changedBy UserId
|
|
SubmissionGroupUser
|
|
submissionGroupId SubmissionGroupId
|
|
userId UserId
|
|
UniqueSubmissionGroupUser submissionGroupId userId
|
|
Tutorial json
|
|
name Text
|
|
tutor UserId
|
|
TutorialUser
|
|
userId UserId
|
|
tutorialId TutorialId
|
|
UniqueTutorialUser userId tutorialId
|
|
Booking
|
|
termId TermId
|
|
begin UTCTime
|
|
end UTCTime
|
|
weekly Bool
|
|
exceptions [UTCTime]
|
|
created UTCTime
|
|
changed UTCTime
|
|
createdBy UserId
|
|
changedBy UserId
|
|
Room
|
|
name Text
|
|
capacity Int Maybe
|
|
building Text
|
|
RoomCourse
|
|
courseId CourseId
|
|
tutorialId TutorialId Maybe
|
|
examId ExamId Maybe
|
|
roomId RoomId
|
|
bookingId BookingId
|
|
UniqueRoomCourse courseId roomId bookingId
|
|
Exam
|
|
courseId CourseId
|
|
name Text
|
|
description Text
|
|
begin UTCTime
|
|
end UTCTime
|
|
registrationBegin UTCTime
|
|
registrationEnd UTCTime
|
|
deregistrationEnd UTCTime
|
|
ratingVisible Bool
|
|
statisticsVisible Bool
|
|
created UTCTime
|
|
changed UTCTime
|
|
createdBy UserId
|
|
changedBy UserId
|
|
ExamUser
|
|
userId UserId
|
|
examId ExamId
|
|
-- CONTINUE HERE: Inlcude rating in this table or seperatly?
|
|
UniqueExamUser userId examId
|
|
-- By default this file is used in Model.hs (which is imported by Foundation.hs)
|