76 lines
3.2 KiB
PHP
76 lines
3.2 KiB
PHP
<x-card.card class="px-3">
|
|
<x-table.table>
|
|
<thead>
|
|
<tr>
|
|
<x-table.th>Rank</x-table.th>
|
|
<x-table.th>ID</x-table.th>
|
|
<x-table.th>Draw #</x-table.th>
|
|
<x-table.th>Student Name</x-table.th>
|
|
<x-table.th>Total Score</x-table.th>
|
|
<x-table.th>Votes</x-table.th>
|
|
@if($scoringComplete)
|
|
<x-table.th>Pass?</x-table.th>
|
|
@endif
|
|
</tr>
|
|
</thead>
|
|
|
|
<x-table.body>
|
|
@foreach($entries as $entry)
|
|
@php
|
|
if ($entry->score_totals[0] < 0) {
|
|
$score = $entry->score_message;
|
|
} else {
|
|
$score = number_format($entry->score_totals[0] ?? 0,4);
|
|
}
|
|
@endphp
|
|
<tr>
|
|
<x-table.td>{{ $entry->rank }}</x-table.td>
|
|
<x-table.td>{{ $entry->id }}</x-table.td>
|
|
<x-table.td>{{ $entry->draw_number }}</x-table.td>
|
|
<x-table.td class="flex flex-col">
|
|
<span>{{ $entry->student->full_name() }}</span>
|
|
<span class="text-xs text-gray-400">{{ $entry->student->school->name }}</span>
|
|
</x-table.td>
|
|
<x-table.td>{{ $score }}</x-table.td>
|
|
|
|
<x-table.td class="flex space-x-1">
|
|
@foreach($entry->advancementVotes as $vote)
|
|
<div x-data="{ showJudgeName: false, timeout: null }"
|
|
x-on:mouseover="clearTimeout(timeout); timeout = setTimeout(() => showJudgeName = true, 300)"
|
|
x-on:mouseleave="clearTimeout(timeout); showJudgeName = false">
|
|
|
|
<x-tooltip x-show="showJudgeName">
|
|
{{ $vote->judge->full_name() }}
|
|
</x-tooltip>
|
|
@switch($vote->vote)
|
|
@case('yes')
|
|
<x-icons.thumbs-up color="green"/>
|
|
@break
|
|
@case('no')
|
|
<x-icons.thumbs-down color="red"/>
|
|
@break
|
|
@case('dq')
|
|
<x-icons.circle-slash-no color="red"/>
|
|
@break
|
|
@endswitch
|
|
</div>
|
|
@endforeach
|
|
</x-table.td>
|
|
@if( $audition->hasFlag('advancement_published') )
|
|
<x-table.td>
|
|
@if($entry->hasFlag('will_advance'))
|
|
<x-icons.checkmark color="green"/>
|
|
@endif
|
|
</x-table.td>
|
|
@elseif($scoringComplete)
|
|
<x-table.td>
|
|
<x-form.checkbox name="pass[{{$entry->id}}]" x-ref="checkboxes" class="checkbox"></x-form.checkbox>
|
|
</x-table.td>
|
|
@endif
|
|
|
|
</tr>
|
|
@endforeach
|
|
</x-table.body>
|
|
</x-table.table>
|
|
</x-card.card>
|