refactor(course-users): minor refactor for tooltips

This commit is contained in:
Sarah Vaupel 2020-03-02 15:53:46 +01:00 committed by Gregor Kleen
parent 1bc14c9e19
commit 1cc9e7c929
5 changed files with 13 additions and 26 deletions

View File

@ -815,18 +815,5 @@
"usedIds": []
}
}
],
"mini-css-extract-plugin node_modules/css-loader/dist/cjs.js??ref--6-1!node_modules/postcss-loader/src/index.js??ref--6-2!node_modules/resolve-url-loader/index.js??ref--6-3!node_modules/sass-loader/dist/cjs.js??ref--6-4!frontend/src/utils/inputs/radiobox.sass": [
{
"modules": {
"byIdentifier": {},
"usedIds": {}
},
"chunks": {
"byName": {},
"bySource": {},
"usedIds": []
}
}
]
}

View File

@ -185,7 +185,8 @@ postAUsersR tid ssh ash = do
contents <- innerCell ^. cellContents
return $ if
| null courses -> contents
| otherwise -> $(widgetFile "table/cell/allocation-courses")
| otherwise -> let tooltipContent = $(widgetFile "table/cell/allocation-courses")
in $(widgetFile "widgets/tooltip_no-handle")
dbtSorting = mconcat
[ sortUserName' $ queryUser . $(multifocusG 2) (to (E.^. UserDisplayName)) (to (E.^. UserSurname))
, sortUserMatriculation $ queryUser . to (E.^. UserMatrikelnummer)

View File

@ -507,7 +507,7 @@ postCUsersR tid ssh csh = do
, pure $ colUserComment tid ssh csh
]
psValidator = def & defaultSortingByName
hasExams = not $ null examOccurrencesPerExam
hasExams = not $ null exams
examOccActs :: Map ExamId (AForm Handler (ExamId, Maybe ExamOccurrenceId))
examOccActs = examOccurrencesPerExam
& (map (bimap entityKey hoistMaybe))
@ -541,9 +541,6 @@ postCUsersR tid ssh csh = do
Nothing
, singletonMap CourseUserRegisterExam $ CourseUserRegisterExamData <$>
multiActionAOpts examOccActs examActs (fslI MsgCourseExam) Nothing
--apopt (selectField' Nothing . fmap (fmap entityKey) $ optionsPersistCryptoId [ExamCourse ==. cid] [Asc ExamName] examName)
-- (fslI MsgCourseExam)
-- Nothing
, if
| mayRegister
-> singletonMap CourseUserDeregister $ courseUserDeregisterForm cid

View File

@ -1,9 +1,5 @@
$newline never
<div .tooltip .tooltip--spread .tooltip--no-handle>
<div>
^{contents}
<div .tooltip__content>
<ul>
$forall Entity _ Course{courseTerm, courseSchool, courseName} <- courses
<li>
#{courseTerm} - #{courseSchool} - #{courseName}
<ul>
$forall Entity _ Course{courseTerm, courseSchool, courseName} <- courses
<li>
#{courseTerm} - #{courseSchool} - #{courseName}

View File

@ -0,0 +1,6 @@
$newline never
<div .tooltip .tooltip--spread .tooltip--no-handle>
<div>
^{contents}
<div .tooltip__content>
^{tooltipContent}