fradrive/templates/allocation/accept.hamlet
2020-03-11 14:16:02 +01:00

87 lines
2.7 KiB
Plaintext

$newline never
#{csrf}
^{fvInput prevAllocView}
<h2>
_{MsgComputedAllocation}
<dl .deflist>
<dt .deflist__dt>
_{MsgAllocationRequestedPlaces}
<dd .deflist__dd>
#{allocationPlacesRequested}
<dt .deflist__dt>
_{MsgAllocationOfferedPlaces}
<dd .deflist__dd>
#{allocationCapacity}
<dt .deflist__dt>
_{MsgAllocationTime}
<dd .deflist__dd>
^{formatTimeW SelFormatDateTime allocTime}
<dt .deflist__dt>
_{MsgAllocationUnmatchedUsers}
<dd .deflist__dd>
#{unmatchedUsers}
<dt .deflist__dt>
_{MsgAllocationUnmatchedCourses}
<dd .deflist__dd>
#{unmatchedCourses}
<div .scrolltable .scrolltable--bordered>
<table .table .table--striped .table--hover>
<thead>
<tr .table__row .table__row--head>
$if showTerms
<th .table__th>
_{MsgTerm}
$if showSchools
<th .table__th>
_{MsgSchool}
<th .table__th>
_{MsgCourse}
<th .table__th>
_{MsgCourseCapacity}
<th .table__th>
_{MsgCourseAllocationMinCapacity}
<th .table__th>
_{MsgCourseMembers}
<th .table__th>
_{MsgAllocationMatchedUsers}
<tbody>
$forall ((Entity _ AllocationCourse{allocationCourseMinCapacity}, Entity cid Course{courseTerm, courseSchool, courseName, courseCapacity, courseShorthand}, participants), allocated) <- allocationCourses'
<tr .table__row :member cid matchingLogRunCoursesExcluded:.allocation-course--excluded>
$if showTerms
<td .table__td>
<div .table__td-content>
<a href=@{TermCourseListR courseTerm}>
_{ShortTermIdentifier (unTermKey courseTerm)}
$if showSchools
<td .table__td>
<div .table__td-content>
<a href=@{TermSchoolCourseListR courseTerm courseSchool}>
#{courseSchool}
<td .table__td>
<div .table__td-content>
<a href=@{CourseR courseTerm courseSchool courseShorthand CShowR}>
#{courseName}
<td .table__td>
<div .table__td-content>
$maybe capN <- courseCapacity
#{capN}
<td .table__td>
<div .table__td-content>
$if allocationCourseMinCapacity > 1
#{allocationCourseMinCapacity}
<td .table__td>
<div .table__td-content>
#{participants}
$maybe capN <- courseCapacity
<td .table__td .dual-heated style="--hotness: #{allocHeat capN allocated}">
<div .table__td-content>
#{allocated}
$nothing
<td .table__td>
<div .table__td-content>
#{allocated}