Proper statistics implemented for submission lists
This commit is contained in:
parent
81d8d8c017
commit
42915b3920
@ -389,7 +389,8 @@ SheetTypeBonus grading@SheetGrading: Bonus
|
|||||||
SheetTypeNormal grading@SheetGrading: Normal
|
SheetTypeNormal grading@SheetGrading: Normal
|
||||||
SheetTypeInformational grading@SheetGrading: Keine Wertung
|
SheetTypeInformational grading@SheetGrading: Keine Wertung
|
||||||
SheetTypeNotGraded: Unbewertet
|
SheetTypeNotGraded: Unbewertet
|
||||||
SheetTypeInfo: Bonus Blätter zählen, erhöhen aber nicht die maximal erreichbare Punktzahl bzw. Anzahl zu bestehender Blätter. Blätter ohne Wertung werden nirgends angerechnet, die Bewertung durch den Korrektor dient lediglich zur Information an die Teilnehmer.
|
SheetTypeInfo: Bonus Blätter zählen normal, erhöhen aber nicht die maximal erreichbare Punktzahl bzw. Anzahl zu bestehender Blätter. Blätter ohne Wertung werden nirgends angerechnet, die Bewertung durch den Korrektor dient lediglich zur Information an die Teilnehmer.
|
||||||
|
SheetGradingBonusIncluded: Erzielte Bonuspunkte wurden hier bereits zu den normalen Punkten hinzugezählt.
|
||||||
|
|
||||||
SheetTypeBonus': Bonus
|
SheetTypeBonus': Bonus
|
||||||
SheetTypeNormal': Normal
|
SheetTypeNormal': Normal
|
||||||
|
|||||||
@ -383,10 +383,10 @@ correctionsR whereClause (formColonnade -> displayColumns) psValidator actions =
|
|||||||
let route = CSubmissionR tid ssh csh shn cID SAssignR
|
let route = CSubmissionR tid ssh csh shn cID SAssignR
|
||||||
(== Authorized) <$> evalAccessDB route True
|
(== Authorized) <$> evalAccessDB route True
|
||||||
|
|
||||||
gradeSummaryWidget :: SheetTypeSummary -> Widget UniWorX IO ()
|
gradeSummaryWidget :: SheetTypeSummary -> Widget
|
||||||
gradeSummaryWidget sts =
|
gradeSummaryWidget sts =
|
||||||
let SheetTypeSummary{..} = addBonusToPoints sts
|
let SheetTypeSummary{..} = addBonusToPoints sts
|
||||||
sumSummaries = (normalSummary <> bonusSummary <> informationalSummary) # _numSheets %~ (<> numNotGraded)
|
sumSummaries = (normalSummary <> bonusSummary <> informationalSummary) -- # _numSheets %~ (<> numNotGraded)
|
||||||
hasPassings = positiveSum $ numGradePasses sumSummaries
|
hasPassings = positiveSum $ numGradePasses sumSummaries
|
||||||
hasPoints = positiveSum $ sumGradePoints sumSummaries
|
hasPoints = positiveSum $ sumGradePoints sumSummaries
|
||||||
rowWdgts = [ $(widgetFile "widgets/gradingSummaryRow")
|
rowWdgts = [ $(widgetFile "widgets/gradingSummaryRow")
|
||||||
@ -395,7 +395,9 @@ gradeSummaryWidget sts =
|
|||||||
, (MsgSheetTypeBonus' ,bonusSummary)
|
, (MsgSheetTypeBonus' ,bonusSummary)
|
||||||
, (MsgSheetTypeInformational' ,informationalSummary)
|
, (MsgSheetTypeInformational' ,informationalSummary)
|
||||||
] ]
|
] ]
|
||||||
in $(widgetFile "widgets/gradingSummary")
|
in if 0 == numSheets sumSummaries
|
||||||
|
then mempty
|
||||||
|
else $(widgetFile "widgets/gradingSummary")
|
||||||
|
|
||||||
|
|
||||||
type ActionCorrections' = (ActionCorrections, AForm (HandlerT UniWorX IO) ActionCorrectionsData)
|
type ActionCorrections' = (ActionCorrections, AForm (HandlerT UniWorX IO) ActionCorrectionsData)
|
||||||
|
|||||||
@ -1,27 +1,29 @@
|
|||||||
$# Displays gradings Summary for various purposes
|
$# Displays gradings Summary for various purposes
|
||||||
$# --
|
$# --
|
||||||
<div>
|
<div>
|
||||||
<table>
|
<table .table .table--striped>
|
||||||
<tr>
|
<tr .table__row .table__row--head>
|
||||||
<th>
|
<th>
|
||||||
$# empty cell for row headers
|
$# empty cell for row headers
|
||||||
$maybe _ <- hasPassings
|
$maybe _ <- hasPassings
|
||||||
<th colspan=2>_{MsgSheetGradingPassing'}
|
<th .table__th colspan=2>_{MsgSheetGradingPassing'}
|
||||||
$maybe _ <- hasPoints
|
$maybe _ <- hasPoints
|
||||||
<th colspan=2>_{MsgSheetGradingPoints'}
|
<th .table__th colspan=2>_{MsgSheetGradingPoints'}
|
||||||
<th>_{MsgSheetGradingCount'}
|
<th .table__th>_{MsgSheetGradingCount'}
|
||||||
$# Number of Sheet/Submissions used for calculating maximum passes/points
|
$# Number of Sheet/Submissions used for calculating maximum passes/points
|
||||||
$forall row <- rowWdgts
|
$forall row <- rowWdgts
|
||||||
^{row}
|
^{row}
|
||||||
$maybe nrNoGrade <- positiveSum $ numNotGraded
|
$maybe nrNoGrade <- positiveSum $ numNotGraded
|
||||||
<tr>
|
<tr .table__row>
|
||||||
<th>_{MsgSheetTypeNotGraded}
|
<th .table__th>_{MsgSheetTypeNotGraded}
|
||||||
$maybe _ <- hasPassings
|
$maybe _ <- hasPassings
|
||||||
<td colspan=2>
|
<td colspan=2>
|
||||||
$maybe _ <- hasPoints
|
$maybe _ <- hasPoints
|
||||||
<td colspan=2>
|
<td .table__td colspan=2>
|
||||||
<td>#{display nrNoGrade}
|
<td .table__td>#{display nrNoGrade}
|
||||||
$maybe _ <- positiveSum $ bonusSummary ^. _numSheets
|
$maybe _ <- positiveSum $ bonusSummary ^. _numSheets
|
||||||
<p>_{MsgSheetTypeInfo}
|
<p>_{MsgSheetTypeInfo}
|
||||||
|
<p>_{MsgSheetGradingBonusIncluded}
|
||||||
$nothing
|
$nothing
|
||||||
<p>_{MsgSheetTypeInfo}
|
$maybe _ <- positiveSum $ informationalSummary ^. _numSheets
|
||||||
|
<p>_{MsgSheetTypeInfo}
|
||||||
@ -6,28 +6,28 @@ $# summary :: SheetGradeSummary -- summary to display
|
|||||||
$# sumHeader :: UniWorXMessage -- row header
|
$# sumHeader :: UniWorXMessage -- row header
|
||||||
$#
|
$#
|
||||||
$maybe nrSheets <- positiveSum $ summary ^. _numSheets
|
$maybe nrSheets <- positiveSum $ summary ^. _numSheets
|
||||||
<tr>
|
<tr .table__row >
|
||||||
<th>_{sumHeader}
|
<th .table__th>_{sumHeader}
|
||||||
$maybe _ <- hasPassings
|
$maybe _ <- hasPassings
|
||||||
$with Sum pmax <- sumHeader ^. _numGradePasses
|
$with Sum pmax <- summary ^. _numGradePasses
|
||||||
$maybe Sum pacv <- summary ^. _achievedPasses
|
$maybe Sum pacv <- summary ^. _achievedPasses
|
||||||
<td>
|
<td .table__td>
|
||||||
$if pmax /= 0
|
$if pmax /= 0
|
||||||
#{textPercentInt pacv pmax}
|
#{textPercentInt pacv pmax}
|
||||||
<td>
|
<td .table__td>
|
||||||
#{display pacv} / #{display pmax}
|
#{display pacv} / #{display pmax}
|
||||||
$nothing
|
$nothing
|
||||||
<td colspan=2>
|
<td .table__td colspan=2>
|
||||||
#{display pmax }
|
#{display pmax }
|
||||||
$maybe _ <- hasPoints
|
$maybe _ <- hasPoints
|
||||||
$with Sum pmax <- sumHeader ^. _sumGradePoints
|
$with Sum pmax <- summary ^. _sumGradePoints
|
||||||
$maybe Sum pacv <- summary ^. _achievedPoints
|
$maybe Sum pacv <- summary ^. _achievedPoints
|
||||||
<td>
|
<td .table__td>
|
||||||
$if pmax /= 0
|
$if pmax /= 0
|
||||||
#{textPercent $ realToFrac $ pacv / pmax}
|
#{textPercent $ realToFrac $ pacv / pmax}
|
||||||
<td>
|
<td .table__td>
|
||||||
#{display pacv} / #{display pmax}
|
#{display pacv} / #{display pmax}
|
||||||
$nothing
|
$nothing
|
||||||
<td colspan=2>
|
<td .table__td colspan=2>
|
||||||
#{display pmax }
|
#{display pmax }
|
||||||
<td>#{display nrSheets}
|
<td .table__td>#{display nrSheets}
|
||||||
Reference in New Issue
Block a user