{!! Theme::section('pdfsign.menu') !!}
@php $fmt = function ($v) { $s = is_string($v) ? trim($v) : (empty($v) ? '' : (string) $v); if ($s === '' || $s === '0000-00-00 00:00:00') return '-'; try { return \Carbon\Carbon::parse($s)->format('M j Y, g:ia'); } catch (\Throwable $e) { return $s; } }; $pdfSignSlug = null; if (\Auth::check()) { $pdfSignSlug = (int) (\Auth::user()->visiting_community ?? 0); } if ($pdfSignSlug === null && isset($slug)) { $pdfSignSlug = (int) $slug; } if ($pdfSignSlug <= 0) { $pdfSignSlug = 75; } @endphp
Reset
@forelse($documents as $doc) @php $docSlug = $pdfSignSlug; $showUrl = route('community.pdf-sign.show', ['slug' => $docSlug, 'token' => $doc->token]); $downloadUrl = route('community.pdf-sign.download', ['slug' => $docSlug, 'token' => $doc->token]); $sourceUrl = route('community.pdf-sign.source', ['slug' => $docSlug, 'token' => $doc->token]); $viewUrl = route('community.pdf-sign.view', ['slug' => $docSlug, 'token' => $doc->token]); $inviteManageUrl = route('community.pdf-sign.invite', ['slug' => $docSlug, 'token' => $doc->token]); $recipientsUrl = route('community.pdf-sign.recipients', ['slug' => $docSlug, 'token' => $doc->token]); $isSigned = (string) $doc->status === 'signed'; $allRecipientsSigned = ((string)($doc->signing_status ?? '') === 'completed') || !empty($doc->completed_at); $invStatus = (string) ($doc->signing_status ?? ''); $invSent = in_array($invStatus, ['invited', 'in_progress', 'completed'], true); $isOwner = \Auth::check() && !empty($doc->user_id) && (int) $doc->user_id === (int) \Auth::id(); $myInvite = !empty($myInvites) ? ($myInvites[(int) $doc->id] ?? null) : null; $myInviteUrl = $myInvite && !empty($myInvite->invite_token) ? route('community.pdf-sign.invite.show', ['slug' => $docSlug, 'inviteToken' => $myInvite->invite_token]) : null; $myInviteStatus = strtolower(trim((string)($myInvite->status ?? ''))); $selfSigned = $myInvite && (in_array($myInviteStatus, ['signed', 'completed'], true) || !empty($myInvite->signed_at ?? null)); @endphp @empty @endforelse
Document Uploaded Actions
@if($doc->document_title)
Document Title: {{$doc->document_title}}
@endif
Document Token ID: {{ $doc->token }}
Document prepared by: {{ !empty($doc->prepared_by_name) ? $doc->prepared_by_name : '-' }}
{{ $fmt($doc->created_at ?? null) }} @if($isOwner) View @if($invSent) Invited @else Invite @endif Status @else @if($myInviteUrl && !$selfSigned) Sign @elseif($selfSigned) View @elseif(!$myInviteUrl) View @endif Status @endif
No documents found.
@if(method_exists($documents, 'links'))
{!! $documents->links() !!}
@endif