From ea6c7b776126195d3e8e2b4a2562079bd39570a4 Mon Sep 17 00:00:00 2001 From: SJost Date: Thu, 7 Jun 2018 10:39:43 +0200 Subject: [PATCH] Fix for SheetMarking visible to students --- src/Foundation.hs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Foundation.hs b/src/Foundation.hs index e8d7324e3..27e688065 100644 --- a/src/Foundation.hs +++ b/src/Foundation.hs @@ -268,8 +268,10 @@ knownTags = -- should not throw exceptions, i.e. no getBy404 or requireAuthId Entity sid Sheet{..} <- MaybeT . getBy $ CourseSheet cid shn cTime <- liftIO getCurrentTime case subRoute of + SFileR SheetExercise _ -> guard $ maybe False (<= cTime) sheetVisibleFrom SFileR SheetHint _ -> guard $ maybe False (<= cTime) sheetHintFrom SFileR SheetSolution _ -> guard $ maybe False (<= cTime) sheetSolutionFrom + SFileR SheetMarking _ -> return False -- only for correctors and lecturers SubmissionR NewSubmission -> guard $ sheetActiveFrom <= cTime && cTime <= sheetActiveTo _ -> guard $ maybe False (<= cTime) sheetVisibleFrom return Authorized