@extends('admin.layouts.app') @section('title', '五子棋对局记录') @section('content') @php require resource_path('views/admin/partials/list-theme.php'); @endphp @php $tableCellClass = 'px-4 py-3'; $badgeClass = $adminListBadgeBaseClass; @endphp

♟️ 五子棋历史记录

查询全站所有的五子棋人机及 PvP 对局。

⚙️ 游戏配置
{{ number_format($summary['total_games']) }}
历史对局数
{{ number_format($summary['completed']) }}
正常完赛
{{ number_format($summary['pvp_count']) }}
PvP 人人对战数
{{ number_format($summary['today_games']) }}
今日新建对局
对局列表
统一表格层次,保留 PvE/PvP、对局状态与胜负视觉语义。
@forelse ($games as $game) @empty @endforelse
赛事ID 创建时间 模式 黑方 (发起) 白方 (迎战) 状态 胜负
#{{ $game->id }} {{ $game->created_at ? $game->created_at->format('m-d H:i') : '—' }} @if ($game->mode === 'pve') 单机 PvE(L{{ $game->ai_level }}) @else 在线 PvP @endif {{ $game->playerBlack?->username ?? '已注销/未知' }} @if ($game->mode === 'pve') AI 机器人 @else {{ $game->playerWhite?->username ?? '已注销/未加入' }} @endif @php $s = match ($game->status) { 'waiting' => ['label' => '等待中', 'bg' => 'bg-amber-100 text-amber-600 border-amber-200'], 'playing' => ['label' => '对弈中', 'bg' => 'bg-blue-100 text-blue-600 border-blue-200'], 'finished' => ['label' => '已结束', 'bg' => 'bg-emerald-100 text-emerald-700 border-emerald-200'], default => ['label' => $game->status, 'bg' => 'bg-gray-100 text-gray-600 border-gray-200'], }; @endphp {{ $s['label'] }} @if ($game->status !== 'finished') - @else @if ($game->winner === 1) ⚫ 黑胜 @elseif ($game->winner === 2) ⚪ 白胜 @else 平局撤销 @endif @endif
暂无记录
@if ($games->hasPages())
{{ $games->links() }}
@endif
@endsection