Teren-app/app/Http/Controllers/SettingController.php
2024-11-13 22:11:07 +01:00

25 lines
599 B
PHP

<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Inertia\Inertia;
class SettingController extends Controller
{
//
public function index(Request $request){
return Inertia::render('Settings/Index', [
'actions' => \App\Models\Action::query()
->with('decisions', fn($q) => $q->get(['decisions.id']))
->get(),
'decisions' => \App\Models\Decision::query()
->with('actions', fn($q) => $q->get(['actions.id']))
->get()
]
);
}
}