@php $user = Auth::user(); $laboratory = $user->userslab->map(function($userlab){ return $userlab->labotory; }); $clientPhoto = null; $clientResults = null; if(!empty($laboratory) && isset($laboratory[0])){ $clientResults = DB::select('select photo from clients where lab_id = '. strval($laboratory[0]->id)); if (!empty($clientResults)) { $client = $clientResults[0]; $clientPhoto = $client->photo; } } @endphp @if ($clientPhoto) @php $photoPath = 'storage/' . strval($clientPhoto); $fileExists = file_exists(public_path($photoPath)); @endphp @if ($fileExists) @else @endif @else @endif
{{ __('Laboratorios') }} {{ __('Indicadores') }}
{{ __('Administrar') }}
{{ __('Usuarios') }} {{ __('Clientes') }}
{{ __('Opciones') }}
{{ __('Auditoría') }} {{ __('Resultados') }}
{{ __('Administrar cuenta') }}
{{ __('Perfil') }}
@csrf {{ __('Cerrar sesión') }}
{{ __('Laboratorios') }} {{ __('Usuarios') }} {{ __('Clientes') }} {{ __('Auditoría') }} {{ __('Resultados') }}
{{ Auth::user()->name }}
{{ Auth::user()->email }}
{{ __('Profile') }}
@csrf {{ __('Log Out') }}