Umbenennung presseportale → pressekonto in Domains, Themes und Dokumentation. Design-Tokens, Portal-Shell, Customer-Dashboard, Auth- und Admin-PM-Views. Artisan-Befehl migrate:legacy-media mit Tests und Hub-Flux-Entwicklungsdocs. Co-authored-by: Cursor <cursoragent@cursor.com>
193 lines
4.9 KiB
Markdown
193 lines
4.9 KiB
Markdown
# Admin Backend - Strukturübersicht
|
|
|
|
## 📁 Ordnerstruktur
|
|
|
|
```
|
|
resources/views/admin/
|
|
├── README.md (diese Datei)
|
|
├── dashboard.blade.php (✅ vorhanden)
|
|
├── press-releases/
|
|
│ └── index.blade.php (✅ erstellt)
|
|
├── companies/
|
|
│ └── index.blade.php (✅ erstellt)
|
|
├── contacts/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
├── invoices/
|
|
│ └── index.blade.php (✅ erstellt)
|
|
├── payments/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
├── coupons/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
├── users/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
├── roles/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
├── categories/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
├── scheduler/
|
|
│ └── index.blade.php (⏳ TODO)
|
|
└── newsletter/
|
|
└── index.blade.php (⏳ TODO)
|
|
```
|
|
|
|
## 🎯 Migrations-Projekt Kontext
|
|
|
|
Diese Backend-Struktur ist Teil der **BusinessPortal24 → Laravel 12 Migration**.
|
|
|
|
**Migrations-Dokumentation:** `/var/www/html/_businessportal24.com/dev/migration/`
|
|
|
|
### Wichtige Dokumente:
|
|
- `CHECKLIST.md` - Alle Aufgaben
|
|
- `PROGRESS.md` - Verlaufsprotokoll
|
|
- `IMPLEMENTATION.md` - Schritt-für-Schritt Anleitung
|
|
- `API-MIGRATION.md` - API-Details
|
|
- `DATA-MIGRATION.md` - Daten-Migration
|
|
|
|
## 📋 Aktueller Stand
|
|
|
|
### ✅ Erstellt (23.01.2026)
|
|
|
|
1. **Navigation (Sidebar)**
|
|
- Datei: `resources/views/components/layouts/app/sidebar.blade.php`
|
|
- Gruppen: Content, CRM, Billing, Administration, System
|
|
- Icons: Hero Icons
|
|
|
|
2. **Admin-Views**
|
|
- Press Releases Index
|
|
- Companies Index
|
|
- Invoices Index
|
|
|
|
3. **Livewire-Komponenten**
|
|
- `livewire/admin/press-releases/index.blade.php`
|
|
- `livewire/admin/companies/index.blade.php`
|
|
- `livewire/admin/invoices/index.blade.php`
|
|
|
|
### ⏳ Nächste Schritte
|
|
|
|
1. **Routes erstellen** (routes/web.php)
|
|
```php
|
|
Route::prefix('admin')->middleware('auth')->group(function () {
|
|
Route::get('/press-releases', ...)->name('admin.press-releases.index');
|
|
Route::get('/companies', ...)->name('admin.companies.index');
|
|
Route::get('/invoices', ...)->name('admin.invoices.index');
|
|
// ... weitere Routes
|
|
});
|
|
```
|
|
|
|
2. **Weitere Index-Views erstellen**
|
|
- Contacts
|
|
- Payments
|
|
- Coupons
|
|
- Categories
|
|
- Users (erweitern)
|
|
- Roles & Permissions
|
|
|
|
3. **CRUD-Views erstellen**
|
|
- create.blade.php
|
|
- edit.blade.php
|
|
- show.blade.php
|
|
|
|
4. **Models & Services implementieren**
|
|
- Nach DATA-MIGRATION.md
|
|
- Domain-Struktur: `app/Domain/{PressRelease,Company,Billing,...}/Models/`
|
|
|
|
## 🎨 Design-System
|
|
|
|
### FluxUI Komponenten
|
|
|
|
Alle Views nutzen **FluxUI** Komponenten:
|
|
|
|
- `<flux:card>` - Container
|
|
- `<flux:table>` - Tabellen
|
|
- `<flux:button>` - Buttons
|
|
- `<flux:badge>` - Status-Badges
|
|
- `<flux:input>` - Eingabefelder
|
|
- `<flux:select>` - Dropdowns
|
|
|
|
### Icons (Hero Icons)
|
|
|
|
Verwendete Icons:
|
|
- `newspaper` - Pressemitteilungen
|
|
- `building-office` - Firmen
|
|
- `document-text` - Rechnungen
|
|
- `user-group` - Kontakte/Users
|
|
- `credit-card` - Zahlungen
|
|
- `folder` - Kategorien
|
|
|
|
## 💾 Dummy-Daten
|
|
|
|
**Wichtig:** Alle aktuellen Komponenten verwenden Dummy-Daten (`collect([...])`).
|
|
|
|
Nach der Migration werden diese ersetzt durch:
|
|
```php
|
|
use App\Domain\PressRelease\Models\PressRelease;
|
|
|
|
$pressReleases = PressRelease::query()
|
|
->with(['company', 'category', 'images'])
|
|
->when($this->search, fn($q) => $q->where('title', 'like', "%{$this->search}%"))
|
|
->paginate(20);
|
|
```
|
|
|
|
## 🔄 Migration-Workflow
|
|
|
|
1. **Phase 1:** Backend-Struktur anlegen ✅ **(AKTUELL)**
|
|
2. Phase 2: Laravel Models erstellen
|
|
3. Phase 3: Services implementieren
|
|
4. Phase 4: Dummy-Daten durch echte Models ersetzen
|
|
5. Phase 5: API-Integration
|
|
6. Phase 6: Daten-Migration durchführen
|
|
7. Phase 7: Testing
|
|
|
|
## 📝 Namenskonventionen
|
|
|
|
### Routes
|
|
```
|
|
admin.{resource}.index - Liste
|
|
admin.{resource}.create - Formular (neu)
|
|
admin.{resource}.store - Speichern (POST)
|
|
admin.{resource}.show - Details
|
|
admin.{resource}.edit - Formular (bearbeiten)
|
|
admin.{resource}.update - Aktualisieren (PUT)
|
|
admin.{resource}.destroy - Löschen (DELETE)
|
|
```
|
|
|
|
### Livewire-Komponenten
|
|
```
|
|
livewire/admin/{resource}/index.blade.php
|
|
livewire/admin/{resource}/create.blade.php
|
|
livewire/admin/{resource}/edit.blade.php
|
|
```
|
|
|
|
### Admin-Views
|
|
```
|
|
admin/{resource}/index.blade.php
|
|
admin/{resource}/create.blade.php
|
|
admin/{resource}/edit.blade.php
|
|
admin/{resource}/show.blade.php
|
|
```
|
|
|
|
## 🚀 Development-Server starten
|
|
|
|
```bash
|
|
# In Terminal 1: Laravel
|
|
php artisan serve
|
|
|
|
# In Terminal 2: Vite
|
|
npm run dev
|
|
|
|
# Backend öffnen:
|
|
http://pressekonto.test/admin/press-releases
|
|
```
|
|
|
|
## 📚 Weitere Ressourcen
|
|
|
|
- **FluxUI Docs:** https://fluxui.dev/docs
|
|
- **Livewire Volt:** https://livewire.laravel.com/docs/volt
|
|
- **Laravel 12:** https://laravel.com/docs/12.x
|
|
- **Hero Icons:** https://heroicons.com
|
|
|
|
---
|
|
|
|
**Stand:** 23. Januar 2026
|
|
**Status:** Backend-Struktur Initial Setup ✅
|
|
**Nächster Schritt:** Routes erstellen und weitere Index-Views implementieren
|