@extends('admin.layouts.app')

@section('content')
<div class="container-fluid">
    <h2>신고 관리 게시글 - 상세</h2>
    <hr/>
    @include('admin.messages')

    <form name="f_admin_search" id="fAdminSearch" action="{{ route('admin.board.blame.post.update', $blame->id) }}">
        @csrf
        @method('PUT')
        <input type="hidden" name="blame_id" value="{{ $blame->id }}"/>

        <div class="row mb-3">
            <label class="col-sm-2">PK</label>
            <div class="col-sm-10">
                {{ $blame->id }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">게시판</label>
            <div class="col-sm-10">
                {{ $blame->board->name }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">게시글</label>
            <div class="col-sm-10">
                {{ $blame->post->subject }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">회원</label>
            <div class="col-sm-10">
                {{ $blame->user->id }} / {{ $blame->user->name }} / {{ $blame->user->email }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">신고 사유</label>
            <div class="col-sm-10">
                {{ MAP_BLAME_TYPE[$blame->type] }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">신고 내용</label>
            <div class="col-sm-10">
                {{ $blame->reason }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">IP</label>
            <div class="col-sm-10">
                {{ $blame->ip_address }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">Device</label>
            <div class="col-sm-10">
                {{ $blame->device }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">Platform</label>
            <div class="col-sm-10">
                {{ $blame->platform }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">Browser</label>
            <div class="col-sm-10">
                {{ $blame->browser }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">UserAgent</label>
            <div class="col-sm-10">
                {{ $blame->user_agent }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">상태</label>
            <div class="col-sm-10">
                @if($blame->status == '0')
                    <span class="badge text-bg-danger">접수</span>
                @else
                    <span class="badge text-bg-info text-white">완료</span>
                @endif
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">처리 내용</label>
            <div class="col-sm-10">
                {{ $blame->memo ?? '-' }}
            </div>
        </div>
        <div class="row mb-3">
            <label class="col-sm-2">등록일시</label>
            <div class="col-sm-10">
                {{ $blame->created_at }}
            </div>
        </div>
        <hr/>
        <div class="text-end">
            <button type="button" class="btn btn-success btn-write-cancel" value="{{ route('admin.board.blame.post.index') }}">뒤로가기</button>
        </div>
    </form>
</div>
@endsection
