Загрузка данных


<!DOCTYPE html>
<html lang="ru">
<head>
    <meta charset="utf-8">
    <title>Кабинет пользователя</title>
</head>
<body>
    @if(session('successMessage'))
        <p style="color: green;">{{ session('successMessage') }}</p>
    @endif

    <h2>Кабинет пользователя</h2>
    <p>ФИО: <b>{{ auth()->user()->name }}</b></p>
    <p>Роль: <b>{{ auth()->user()->role }}</b></p>

    <form action="{{ route('logout') }}" method="POST">
        @csrf
        <button type="submit">Выйти из системы</button>
    </form>
</body>
</html>