@extends('admin.layouts.master') @section('content')

{{ trans('app.merchant') }}

@if(Gate::allows('view', $dispute->shop)) {{ $dispute->shop->name }} @else {{ $dispute->shop->name }} @endif {{ trans('app.logo') }}

{{ trans('app.total_disputes') }}: {{ \App\Helpers\Statistics::dispute_count($dispute->shop_id) }}

{{ trans('app.latest_days', ['days' => 30]) }}: {{ \App\Helpers\Statistics::dispute_count($dispute->shop_id, 30) }}

@if($dispute->shop->owner)

@if($dispute->shop->owner->image) {{ trans('app.avatar') }} @else {{ trans('app.avatar') }} @endif   @if(Gate::allows('view', $dispute->shop->owner)) {{ $dispute->shop->owner->getName() }} @else {{ $dispute->shop->owner->getName() }} @endif

@endif

{{ trans('app.dispute') }}

@can('response', $dispute) {{ trans('app.response') }} @endcan
{!! $dispute->statusName() !!}

{{ $dispute->dispute_type->detail }}

@if(count($dispute->attachments)) {{ trans('app.attachments') . ': ' }} @foreach($dispute->attachments as $attachment) @endforeach @endif @if($dispute->description)
{!! $dispute->description !!}
@endif @if($dispute->replies->count() > 0)
{{ strtoupper(trans('app.conversations')) }}
@foreach($dispute->replies as $reply) @include('admin.partials._reply_conversations') @endforeach @endif
@include('admin.partials._activity_logs', ['logger' => $dispute])
@if($dispute->product_id)

{{ trans('app.product') }}

{{ trans('app.image') }} @if(Gate::allows('view', $dispute->product)) {{ $dispute->product->name }} @else {{ $dispute->product->name }} @endif
@endif

{{ trans('app.customer') }}

@if($dispute->customer->image) {{ trans('app.avatar') }} @else {{ trans('app.avatar') }} @endif @if(Gate::allows('view', $dispute->customer)) {{ $dispute->customer->getName() }} @else {{ $dispute->customer->getName() }} @endif

{{ trans('app.total_disputes') }}: {{ \App\Helpers\Statistics::disputes_by_customer_count($dispute->customer_id) }}

{{ trans('app.latest_days', ['days' => 30]) }}: {{ \App\Helpers\Statistics::disputes_by_customer_count($dispute->customer_id, 30) }}


{{ $dispute->created_at->diffForHumans() }}

{{ $dispute->updated_at->diffForHumans() }}

@endsection