parent
9d9ead95d8
commit
0bb9a0fa60
@ -186,7 +186,7 @@ getSheetListR tid ssh csh = do
|
|||||||
let
|
let
|
||||||
hasSFT :: (E.Value Bool, E.Value Bool, E.Value Bool, E.Value Bool) -> [SheetFileType]
|
hasSFT :: (E.Value Bool, E.Value Bool, E.Value Bool, E.Value Bool) -> [SheetFileType]
|
||||||
hasSFT (E.Value hasExercise, E.Value hasHint, E.Value hasSolution, E.Value hasMarking)
|
hasSFT (E.Value hasExercise, E.Value hasHint, E.Value hasSolution, E.Value hasMarking)
|
||||||
= [ sft | sft <- [minBound..maxBound]
|
= [ sft | sft <- universeF
|
||||||
, sft /= SheetExercise || hasExercise
|
, sft /= SheetExercise || hasExercise
|
||||||
, sft /= SheetHint || hasHint
|
, sft /= SheetHint || hasHint
|
||||||
, sft /= SheetSolution || hasSolution
|
, sft /= SheetSolution || hasSolution
|
||||||
@ -204,7 +204,7 @@ getSheetListR tid ssh csh = do
|
|||||||
E.where_ $ sheet E.^. SheetCourse E.==. E.val cid
|
E.where_ $ sheet E.^. SheetCourse E.==. E.val cid
|
||||||
|
|
||||||
sheetFilter :: SheetName -> DB Bool
|
sheetFilter :: SheetName -> DB Bool
|
||||||
sheetFilter sheetName = (== Authorized) <$> evalAccessDB (CSheetR tid ssh csh sheetName SShowR) False
|
sheetFilter sheetName = hasReadAccessTo $ CSheetR tid ssh csh sheetName SShowR
|
||||||
|
|
||||||
sheetCol = widgetColonnade . mconcat $
|
sheetCol = widgetColonnade . mconcat $
|
||||||
[ -- dbRow ,
|
[ -- dbRow ,
|
||||||
@ -220,9 +220,9 @@ getSheetListR tid ssh csh = do
|
|||||||
| let existingSFTs = hasSFT existFiles
|
| let existingSFTs = hasSFT existFiles
|
||||||
, sft <- [minBound..maxBound]
|
, sft <- [minBound..maxBound]
|
||||||
, let link = CSheetR tid ssh csh sheetName $ SZipR sft
|
, let link = CSheetR tid ssh csh sheetName $ SZipR sft
|
||||||
, let icn = toWidget $ sheetFile2markup sft
|
, let icn = toWgt $ sheetFile2markup sft
|
||||||
, let icnCell = if sft `elem` existingSFTs
|
, let icnCell = if sft `elem` existingSFTs
|
||||||
then linkEmptyCell link icn
|
then linkEitherCell link (icn, [whamlet| |])
|
||||||
else spacerCell
|
else spacerCell
|
||||||
] id & cellAttrs <>~ [("class","list--inline list--space-separated")]
|
] id & cellAttrs <>~ [("class","list--inline list--space-separated")]
|
||||||
, sortable (Just "submission-since") (i18nCell MsgSheetActiveFrom)
|
, sortable (Just "submission-since") (i18nCell MsgSheetActiveFrom)
|
||||||
|
|||||||
@ -482,6 +482,11 @@ ul.list--inline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.list--icon-width li {
|
||||||
|
width: 1rem;
|
||||||
|
height: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
/* DEFINITION LIST */
|
/* DEFINITION LIST */
|
||||||
.deflist {
|
.deflist {
|
||||||
display: grid;
|
display: grid;
|
||||||
@ -626,7 +631,7 @@ section {
|
|||||||
grid-column: 1;
|
grid-column: 1;
|
||||||
|
|
||||||
max-width: none;
|
max-width: none;
|
||||||
|
|
||||||
padding-left: 40px;
|
padding-left: 40px;
|
||||||
|
|
||||||
&::before {
|
&::before {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user