auditionadmin/resources/views/recap/recap.blade.php

42 lines
1.6 KiB
PHP

<x-layout.app>
<x-layout.page-header>{{$audition->name}} Recap</x-layout.page-header>
<x-card.card class="mt-3">
<x-card.heading>
<x-slot:subheading>The final score is calculated by multiplying each subscore by its weight, the dividing the total by the total of the weights</x-slot:subheading>
</x-card.heading>
<x-table.table>
<thead>
<tr>
<x-table.th>#</x-table.th>
<x-table.th>Name</x-table.th>
@foreach($subscores as $subscore)
<x-table.th>
{{ $subscore->name }}<br>
Weight: {{ $subscore->weight }}<br>
Max: {{ $subscore->max_score }}
</x-table.th>
@endforeach
<x-table.th>Final</x-table.th>
</tr>
</thead>
<x-table.body>
@foreach($recapRows as $row)
<tr>
<x-table.td>{{$row['rank']}}</x-table.td>
<x-table.td>{{$row['name']}}<br>{{$row['school']}}</x-table.td>
@php ($ssOn = 1)
@foreach($subscores as $subscore)
<x-table.td>{{ $row['scores'][$ssOn] }} ( {{ $subscoreOrdinals['entry'.$row['entryId']][$ssOn] }} )</x-table.td>
@php ($ssOn++)
@endforeach
<x-table.td>{{$row['total_score']}}</x-table.td>
</tr>
@endforeach
</x-table.body>
</x-table.table>
</x-card.card>
</x-layout.app>