@extends('layouts.app') @push('styles') @mapstyles @endpush @section('content') @if (Auth::user()->role_id >= 5)
@include('sidebar')
@else
@endif

Contratos actuales

{!! Form::open(['method'=>'GET','url'=>'currentcontracts','class'=>'navbar-form navbar-left','role'=>'search']) !!}
{!! Form::close() !!}
@php $mapMarkers = []; foreach ($currentcontracts as $currentcontract) { if ($currentcontract->location) { $mapMarkers[] = [ 'title' => $currentcontract->id, 'lat' => $currentcontract->location->getLat(), 'lng' => $currentcontract->location->getLng(), 'popup' => '

' . $currentcontract->id . '

' . $currentcontract->address . '
' . ($currentcontract->suppliers->company_name ?? '') . '
' . ucfirst($currentcontract->categories->name ?? '') . '
' . $currentcontract->appointment . '
$' . $currentcontract->amount . '
' . ucfirst($currentcontract->status->name ?? '') . '
' . $currentcontract->score . ' de 5

', ]; } } @endphp @map([ 'lat' => 20.659698, 'lng' => -103.349609, 'zoom' => 12, 'markers' => $mapMarkers ])
    {{ $currentcontracts->links() }}
@endsection