36 lines
1.5 KiB
PHP
36 lines
1.5 KiB
PHP
@extends('layouts.app')
|
||
|
||
@section('content')
|
||
<div class="bg-white p-6 rounded-xl shadow-md">
|
||
<div class="mb-4">
|
||
<a href="{{ route('admin.sessions') }}" class="text-blue-600 hover:underline text-sm">← Назад</a>
|
||
</div>
|
||
|
||
<h1 class="text-2xl font-bold text-gray-800 mb-2">Сессия #{{ $round->id }}</h1>
|
||
<p class="text-gray-600 mb-4">
|
||
Диапазон: 1–{{ $round->max_score }} |
|
||
Участников: {{ $round->votes->count() }} / {{ $round->max_voters }}
|
||
</p>
|
||
|
||
<div class="bg-blue-50 p-4 rounded-lg mb-6">
|
||
<p class="text-lg font-semibold text-blue-800">
|
||
Средняя оценка: <span class="text-2xl">{{ number_format($round->average_score, 2) }}</span>
|
||
</p>
|
||
</div>
|
||
|
||
@if($round->votes->isEmpty())
|
||
<p class="text-gray-500">Пока никто не проголосовал.</p>
|
||
@else
|
||
<h2 class="text-lg font-medium text-gray-800 mb-3">Участники:</h2>
|
||
<div class="space-y-2">
|
||
@foreach($round->votes as $vote)
|
||
<div class="flex justify-between items-center bg-gray-50 px-4 py-2 rounded">
|
||
<span class="font-medium">{{ $vote->name }}</span>
|
||
<span class="bg-white px-3 py-1 rounded-full font-bold text-blue-700">{{ $vote->score }}</span>
|
||
</div>
|
||
@endforeach
|
||
</div>
|
||
@endif
|
||
</div>
|
||
@endsection
|