I am new to laravel and trying to make a panel for food delivery I have used Laravel default Registration and Login for User Category--Restaurant and then after user login , the user can Add restaurant details using route (/add_details) once the user has added restaurant details the user should not be able to go to that route (/add_details)
this will depend on a column in restaurant table (is_verified) how do i check that
I was thinking of using a Laravel middleware
but then i was stuck how laravel middleware $request variable works how can i get column value in middleware and verify it
or if any other simple but effective solution as i will be using it in sidebar.blade.php as well
so that i can hide the menu
restaurant_id
in your user table then see edit of your answer. You don't need to first get user record thenrestaurant_id
you can directly get it. And apply the middleware on that specific route.