cms/app/Http/Controllers/Admin/Navigation/NavigationDestroyController.php
Funky Waddle 37ed997989 feat(cms): initialize Laravel project structure and core CMS files
- Added standard Laravel directory structure and configuration.

- Included Svelte and Tailwind configuration for the admin interface.

- Added core PHPUnit and testing scripts.
2026-04-13 12:48:06 -05:00

20 lines
539 B
PHP

<?php
namespace App\Http\Controllers\Admin\Navigation;
use App\Http\Controllers\Controller;
use App\Services\NavigationService;
use App\Models\NavigationItem;
class NavigationDestroyController extends Controller
{
public function __invoke(NavigationItem $navigation, NavigationService $navigationService)
{
if ($navigationService->delete($navigation)) {
return back()->with('success', 'Navigation item removed.');
}
return back()->with('error', 'Failed to remove navigation item.');
}
}