From 8bb61401a77f20fcb35aa05401bf16285aad1d93 Mon Sep 17 00:00:00 2001 From: Sarah Vaupel Date: Wed, 9 Jun 2021 16:56:25 +0200 Subject: [PATCH] fix(exams): set use-custom correctly if forced --- src/Handler/Exam/Form.hs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Handler/Exam/Form.hs b/src/Handler/Exam/Form.hs index af22fca30..ee42effa5 100644 --- a/src/Handler/Exam/Form.hs +++ b/src/Handler/Exam/Form.hs @@ -150,9 +150,7 @@ examForm (Entity _ Course{..}) template csrf = hoist liftHandler $ do <* aformSection MsgExamAuthorshipStatementSection <* optionalActionA ( aopt htmlField - ( fslI MsgExamAuthorshipStatementSchoolDefinition - & addAttr "disabled" "disabled" - ) + (fslI MsgExamAuthorshipStatementSchoolDefinition & addAttr "disabled" "disabled") ((Just . authorshipStatementDefinitionContent . entityVal) <$> mSchoolAuthorshipStatement) <* optionalActionA ( apreq htmlField @@ -170,7 +168,7 @@ examForm (Entity _ Course{..}) template csrf = hoist liftHandler $ do & addAttr "disabled" "disabled" & setTooltip MsgExamAuthorshipStatementUseCustomDefinitionDisabledTip ) - ( bool (Just True) + ( bool (Just False) (Just True) -- TODO: set according to template, if template is empty `Just True` schoolSheetExamAuthorshipStatementAllowOther )