@extends('worldexpansion.layout') @section('title') Fauna @endsection @section('content') {!! breadcrumbs(['World' => 'world', 'Fauna' => 'world/faunas']) !!}

Fauna

{!! Form::open(['method' => 'GET', 'class' => '']) !!}
{!! Form::text('name', Request::get('name'), ['class' => 'form-control', 'placeholder' => 'Name']) !!}
{!! Form::select('type_id', $categories, Request::get('name'), ['class' => 'form-control']) !!}
{!! Form::select( 'sort', [ 'alpha' => 'Sort Alphabetically (A-Z)', 'alpha-reverse' => 'Sort Alphabetically (Z-A)', 'category' => 'Sort by Category', 'newest' => 'Newest First', 'oldest' => 'Oldest First', ], Request::get('sort') ?: 'category', ['class' => 'form-control'], ) !!}
{!! Form::submit('Search', ['class' => 'btn btn-primary']) !!}
{!! Form::close() !!}
{!! $faunas->render() !!}
@foreach ($faunas as $fauna)
@isset($fauna->thumb_extension) @endisset

{!! $fauna->displayName !!}

{!! $fauna->category ? $fauna->category->displayName : '' !!}

@if (count(allAttachments($fauna)))
@foreach (allAttachments($fauna) as $type => $attachments)

Associated with {{ count($attachments) }} {{ strtolower($type) }}{{ count($attachments) == 1 ? '' : 's' }}.

@endforeach
@endif @isset($fauna->summary) @endisset
@endforeach
{!! $faunas->render() !!}
{{ $faunas->total() }} result{{ $faunas->total() == 1 ? '' : 's' }} found.
@endsection