Migrate backend to Porto architecture and fix minor bugs

- Fully transitioned the backend to the Porto architectural pattern
- Improved code organization and maintainability
- Fixed minor bugs and inconsistencies
This commit is contained in:
F4ilji
2025-05-12 08:47:43 +05:00
parent 76deaf75f3
commit c01016a154
620 changed files with 16218 additions and 6073 deletions
@@ -2,8 +2,8 @@
namespace App\Http\Middleware;
use App\Http\Resources\ClientNavigationResource;
use App\Models\MainSection;
use App\Containers\AppStructure\Models\MainSection;
use App\Containers\AppStructure\UI\API\Transformers\NavigationResource;
use App\Services\App\Breadcrumb\BreadcrumbService;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Cache;
@@ -23,7 +23,7 @@ class HandleInertiaRequests extends Middleware
{
// Навигация (кешированная)
$navigation = Cache::remember('navigation', now()->addHours(1), function () {
return ClientNavigationResource::collection(
return NavigationResource::collection(
MainSection::with('subSections.pages.section')
->orderBy('sort', 'asc')
->get()