chore: remove TODO marker

This commit is contained in:
Wolfgang Witt 2021-03-01 17:44:49 +01:00 committed by Wolfgang Witt
parent 767090ded1
commit a7671dbec6

View File

@ -115,9 +115,6 @@ postEAutoOccurrenceR tid ssh csh examn = do
return (uid, (userRec, examRegistrationOccurrence))
occurrences' = Map.fromList $ map (\(Entity eoId ExamOccurrence{..}) -> (eoId, fromIntegral examOccurrenceCapacity)) occurrences
autoOccurrenceResult = examAutoOccurrence eId examOccurrenceRule eaofConfig occurrences' participants'
-- TODO catch error here
-- lookup from ExamOccurrenceId -> Name can happen here
-- examOccurrenceName :: CI Text is probably the right one
(eaofMapping, eaofAssignment) <- case autoOccurrenceResult of
(Left e) -> do
addMessageI Error e
@ -145,7 +142,6 @@ postEAutoOccurrenceR tid ssh csh examn = do
fmap fold . iforM eaofAssignment $ \pid occ -> case occ of
Just _ -> Sum <$> updateWhereCount [ ExamRegistrationExam ==. eId, ExamRegistrationUser ==. pid, ExamRegistrationOccurrence ==. Nothing ] [ ExamRegistrationOccurrence =. occ ]
Nothing -> return mempty
-- TODO here we produce the html redirect
addMessageI Success $ MsgExamAutoOccurrenceParticipantsAssigned assignedCount
redirect $ CExamR tid ssh csh examn EUsersR