# Apex Admins — Folder Structure

**Version:** 1.0  
**Date:** 2026-06-27

---

## Project Root

```
/home/ronnie/public_html/apex.ronnieridge.com/
├── Doc/                              # Planning documentation
├── app/
│   ├── Actions/                      # Cross-module single-purpose actions
│   ├── Console/
│   │   └── Commands/
│   │       ├── SeoAuditAllCommand.php
│   │       └── RegenerateSitemapCommand.php
│   ├── DTOs/                         # Shared data transfer objects
│   ├── Http/
│   │   └── Middleware/
│   │       ├── CheckPermission.php
│   │       ├── HandleRedirects.php
│   │       └── InjectThemeSettings.php
│   ├── Modules/                      # Feature modules (see below)
│   ├── Providers/
│   │   ├── AppServiceProvider.php
│   │   └── ModuleServiceProvider.php
│   └── Support/
│       └── ModuleRegistry.php
├── bootstrap/
├── config/
│   ├── apex.php                      # App-specific config
│   ├── filesystems.php               # local + s3 disks
│   └── scout.php
├── database/
│   ├── factories/
│   └── seeders/
│       ├── DatabaseSeeder.php
│       ├── RolePermissionSeeder.php
│       ├── SettingsSeeder.php
│       ├── MenuSeeder.php
│       └── ContentSeeder.php
├── public/
│   ├── build/                        # Vite compiled assets
│   ├── index.php
│   └── storage -> ../storage/app/public
├── resources/
│   ├── css/
│   │   ├── app.css                   # Tailwind entry
│   │   └── admin.css
│   ├── js/
│   │   ├── app.js
│   │   ├── admin.js
│   │   ├── gsap.js
│   │   ├── swiper.js
│   │   └── analytics.js
│   ├── icons.svg
│   └── views/
│       ├── components/               # Public Blade components
│       ├── layouts/
│       ├── pages/
│       ├── admin/
│       └── errors/
├── routes/
│   ├── web.php
│   ├── admin.php
│   └── api.php
├── storage/
├── tests/
│   ├── Feature/
│   └── Unit/
├── .env
├── .env.example
├── composer.json
├── package.json
├── vite.config.js
├── tailwind.config.js
├── phpstan.neon
└── pint.json
```

---

## Module Internal Structure

Each module under `app/Modules/{Name}/`:

```
Blog/
├── Actions/
│   └── PublishPostAction.php
├── Database/
│   └── Migrations/
│       └── 2026_01_01_000001_create_blog_posts_table.php
├── DTOs/
│   └── PostData.php
├── Http/
│   ├── Controllers/
│   │   ├── Admin/
│   │   │   └── PostController.php
│   │   └── Web/
│   │       └── BlogController.php
│   └── Requests/
│       ├── StorePostRequest.php
│       └── UpdatePostRequest.php
├── Models/
│   ├── BlogPost.php
│   ├── BlogCategory.php
│   └── BlogTag.php
├── Policies/
│   └── BlogPostPolicy.php
├── Repositories/
│   └── BlogPostRepository.php
├── Resources/
│   └── views/
│       └── admin/
│           └── posts/
├── Routes/
│   ├── admin.php
│   └── web.php
├── Services/
│   └── BlogService.php
└── BlogServiceProvider.php
```

---

## Module List (Directories)

```
app/Modules/
├── Admin/
├── Analytics/
├── Academy/
├── Blog/
├── Careers/
├── CaseStudies/
├── Contact/
├── CRM/
├── Industries/
├── Leads/
├── Locations/
├── Media/
├── Menus/
├── Pages/
├── Redirects/
├── SEO/
├── Services/
├── Settings/
└── Users/
```

---

## Views Organization

```
resources/views/
├── components/
│   ├── header.blade.php
│   ├── footer.blade.php
│   ├── ui/
│   ├── sections/
│   ├── forms/
│   ├── seo/
│   ├── media/
│   └── animate/
├── layouts/
│   └── app.blade.php
├── pages/
│   ├── home.blade.php
│   ├── show.blade.php
│   ├── services/
│   ├── hire/
│   ├── industries/
│   └── ...
└── admin/
    ├── layouts/
    └── ...
```

---

## Route Files

**routes/web.php** — includes module web routes  
**routes/admin.php** — prefix `admin`, middleware `auth`, `permission`  
**routes/api.php** — webhooks, analytics, AJAX forms

---

## Config: apex.php

```php
return [
    'name' => env('APP_NAME', 'Apex Admins'),
    'admin_prefix' => 'admin',
    'modules' => [
        Admin::class,
        Users::class,
        // ...
    ],
];
```

---

## Naming Conventions

| Item | Convention | Example |
|------|------------|---------|
| Models | Singular PascalCase | `HireRole` |
| Tables | snake_case plural | `hire_roles` |
| Controllers | PascalCase + Controller | `HireRoleController` |
| Services | PascalCase + Service | `HirePageService` |
| Repositories | PascalCase + Repository | `HireRoleRepository` |
| Actions | Verb + Action | `PublishPostAction` |
| Migrations | descriptive snake | `create_hire_roles_table` |
| Routes | dot notation | `hire.show` |
| Blade components | kebab-case | `sections.hero` |
