@extends('global.app') @section('title', trans('policies.title.all') ) @section('page_stylesheets') @endsection @section('action_buttons')
@yield('new_payment_button')
@endsection @section('content') @parent @include('global.status')
@forelse($policies as $key => $policy) @empty @endforelse
{{ trans('policies.table.header.number') }} {{ trans('policies.table.header.ref_no') }} {{ trans('policies.table.header.client') }} {{ trans('policies.table.header.product') }} {{ trans('policies.table.header.insurer') }} {{ trans('policies.table.header.premium') }} {{ trans('policies.table.header.due') }} {{ trans('policies.table.header.status') }} {{ trans('policies.table.header.action') }}
{{ $policies->lastOnPreviousPage + $key + 1 }} {{ $policy->ref_no }} {{ $policy->client->first_name }} {{ $policy->client->last_name }} {{ $policy->product->name }} {{ $policy->product->insurer }} {{ $policies->currency_symbol }}{{ $policy->premium }} {{ $policies->currency_symbol }}{{ $policy->due }} @if ($policy->premium <= $policy->paid && $policy->paid > 0)
{{ trans('clients.table.data.status.paid') }}
@elseif ($policy->premium > $policy->paid && $policy->paid > 0)
{{ trans('clients.table.data.status.partial') }}
@elseif ($policy->premium == $policy->paid && $policy->paid === 0)
{{ trans('clients.table.data.status.free') }}
@else ($policy->premium > 0 && $policy->paid === 0)
{{ trans('clients.table.data.status.unpaid') }}
@endif
{{ trans('policies.table.data.action.view') }}
{{ trans('policies.message.empty') }}
{{ trans('policies.table.data.pagination', array( 'start' => $policies->total() > 0 ? $policies->lastOnPreviousPage + 1 : 0, 'stop' => $policies->lastOnPreviousPage + $policies->count(), 'total' => $policies->total() )) }} {!! $policies->render($presenter) !!}
@endsection @section('page_scripts') @endsection