@extends('layouts.app') @section('title', 'Inspections') @section('content')

Inspections

View and complete inspections

@forelse($inspections as $inspection)

{{ $inspection->title }}

{{ ucfirst(str_replace('_', ' ', $inspection->status)) }} {{ $inspection->created_at->format('M d, Y') }}
{{ $inspection->site->name }}
@if($inspection->description)

{{ Str::limit($inspection->description, 80) }}

@endif @if($inspection->photos->count() > 0 || $inspection->notes->count() > 0)
@if($inspection->photos->count() > 0)
{{ $inspection->photos->count() }} photo{{ $inspection->photos->count() !== 1 ? 's' : '' }}
@endif @if($inspection->notes->count() > 0)
{{ $inspection->notes->count() }} note{{ $inspection->notes->count() !== 1 ? 's' : '' }}
@endif
@endif
@empty

No inspections found

Inspections will appear here once you clock in at a site

@endforelse @if($inspections->hasPages())
{{ $inspections->links() }}
@endif
@include('app.partials.bottom-nav') @endsection