<?php

namespace App\Http\Controllers\Settings;

use App\Http\Controllers\Controller;
use App\Models\Permission;
use App\Models\User;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Log;
use Inertia\Inertia;

class PermissionsController extends Controller
{
    public function show(User $user)
    {
        $permissions = $user->permissions()->all();
        Log::info($permissions);
        return Inertia::render('Settings/Permissions', [
            'permissions' => $permissions
        ]);
    }
}
