@extends('layouts.app') @php use Illuminate\Support\Facades\Storage; @endphp @section('title', 'Dispute Details') @section('content')

🚨 Dispute #{{ $dispute->id }}

{{ ucfirst($dispute->status) }}
Opened by: {{ $dispute->openedBy->username }}
Date: {{ $dispute->created_at->format('M d, Y H:i') }} ({{ $dispute->created_at->diffForHumans() }})
Reason: {{ $dispute->reason }}
@if($dispute->description)
Description:

{{ $dispute->description }}

@endif

⚔️ Challenge #{{ $dispute->challenge->id }}

{{ ucfirst($dispute->challenge->status) }}
{{ strtoupper(substr($dispute->challenge->creator->username, 0, 1)) }}

{{ $dispute->challenge->creator->username }}

Challenge Creator

Level {{ $dispute->challenge->creator->level }} {{ number_format($dispute->challenge->creator->xp) }} XP
VS
₦{{ number_format($dispute->challenge->wager_amount, 2) }}
@if($dispute->challenge->accepter)
{{ strtoupper(substr($dispute->challenge->accepter->username, 0, 1)) }}

{{ $dispute->challenge->accepter->username }}

Challenge Accepter

Level {{ $dispute->challenge->accepter->level }} {{ number_format($dispute->challenge->accepter->xp) }} XP
@else
?

No Accepter

Challenge not accepted

@endif
Game: {{ $dispute->challenge->game->name ?? 'Unknown Game' }}
@if($dispute->challenge->game)
Platform: {{ ucfirst($dispute->challenge->game->platform) }}
@endif
Created: {{ $dispute->challenge->created_at->format('M d, Y H:i') }}
@if($dispute->challenge->expires_at)
Expires: {{ $dispute->challenge->expires_at->format('M d, Y H:i') }}
@endif
@if($dispute->challenge->matchProofs->count() > 0 || $dispute->hasCreatorEvidence() || $dispute->hasAccepterEvidence())

📷 Evidence

@if($dispute->challenge->matchProofs->count() > 0)

Match Results Evidence

@foreach($dispute->challenge->matchProofs as $proof)

{{ $proof->type === 'screenshot' ? '📷' : '🎥' }} {{ ucfirst($proof->type) }}

Submitted by {{ $proof->user->username }}

{{ $proof->created_at->format('M d, Y H:i') }}
@if($proof->file_path) View Evidence @endif
@endforeach
@endif @if($dispute->hasCreatorEvidence() || $dispute->hasAccepterEvidence())

Victory Claim Evidence

{{ $dispute->challenge->creator->username }} (Creator)

@if($dispute->hasCreatorEvidence())

Victory claim evidence uploaded

View Creator's Evidence
@else

No evidence uploaded

@endif

{{ $dispute->challenge->accepter->username ?? 'No Accepter' }} (Accepter)

@if($dispute->hasAccepterEvidence())

Victory claim evidence uploaded

View Accepter's Evidence
@else

No evidence uploaded

@endif
@if($dispute->hasBothEvidence())

✅ Both parties have submitted evidence

Review both evidences carefully before making a decision.

@elseif($dispute->hasCreatorEvidence() || $dispute->hasAccepterEvidence())

⏳ Waiting for evidence

Only one party has submitted evidence. Consider waiting for both sides or making a decision based on available evidence.

@endif
@endif
@endif @if($dispute->status === 'open')

⚖️ Resolve Dispute

@csrf

Select Winner

@if($dispute->challenge->accepter) @endif
@else

✅ Dispute Resolved

Resolved by: {{ $dispute->admin ? $dispute->admin->username : 'System' }}
Resolution Date: {{ $dispute->resolved_at ? $dispute->resolved_at->format('M d, Y H:i') : 'N/A' }}
@if($dispute->admin_notes)
Admin Notes:

{{ $dispute->admin_notes }}

@endif
@endif
@endsection