mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-15 01:01:09 +02:00
Applied formatting to 1487+ files using pnpm format:write - TypeScript/JavaScript files - Svelte components - Astro pages - JSON configs - Markdown docs 13 files still need manual review (Astro JSX comments)
74 lines
1.7 KiB
Markdown
74 lines
1.7 KiB
Markdown
# 🚨 SOFORTIGE LÖSUNG: Created/Updated Felder hinzufügen
|
|
|
|
## Das Problem
|
|
|
|
Die `links` Collection hat keine `created` und `updated` Felder, deshalb zeigt die UI "N/A" an.
|
|
|
|
## ✅ EINFACHSTE LÖSUNG - Manuelle Schritte in PocketBase Admin:
|
|
|
|
### 1. PocketBase Admin öffnen
|
|
|
|
Gehe zu: **https://pb.ulo.ad/_/**
|
|
|
|
### 2. Links Collection bearbeiten
|
|
|
|
1. Navigiere zu: **Collections → links**
|
|
2. Klicke auf **"Edit collection"**
|
|
|
|
### 3. Diese 2 wichtigsten Felder hinzufügen:
|
|
|
|
#### a) **created** (Type: autodate) - WICHTIGSTE!
|
|
|
|
- **Field name**: `created`
|
|
- **Type**: `autodate`
|
|
- **onCreate**: ✅ **aktiviert**
|
|
- **onUpdate**: ❌ deaktiviert
|
|
|
|
#### b) **updated** (Type: autodate) - WICHTIGSTE!
|
|
|
|
- **Field name**: `updated`
|
|
- **Type**: `autodate`
|
|
- **onCreate**: ✅ **aktiviert**
|
|
- **onUpdate**: ✅ **aktiviert**
|
|
|
|
### 4. Optional - Weitere nützliche Felder:
|
|
|
|
#### c) **use_username** (Type: bool)
|
|
|
|
- **Field name**: `use_username`
|
|
- **Type**: `bool`
|
|
- **Default value**: `false`
|
|
- **Required**: No
|
|
|
|
#### d) **click_count** (Type: number)
|
|
|
|
- **Field name**: `click_count`
|
|
- **Type**: `number`
|
|
- **Default value**: `0`
|
|
- **Only integers**: ✅
|
|
- **Min**: `0`
|
|
- **Required**: No
|
|
|
|
### 5. Speichern
|
|
|
|
Klicke auf **"Save collection"**
|
|
|
|
## ✅ ERGEBNIS
|
|
|
|
Nach dem Hinzufügen der Felder:
|
|
|
|
- **Neue Links** bekommen automatisch Timestamps ✅
|
|
- **UI zeigt Datum korrekt an** statt "N/A" ✅
|
|
- **Alle anderen Features** funktionieren weiterhin ✅
|
|
|
|
## 🧹 Aufräumen (Optional)
|
|
|
|
Nach erfolgreicher Implementierung:
|
|
|
|
- Lösche die `links_improved` Collection (war nur ein Test)
|
|
- Die Anwendung nutzt wieder die ursprüngliche `links` Collection
|
|
|
|
---
|
|
|
|
**⏱️ Zeitaufwand**: 2-3 Minuten
|
|
**🎯 Resultat**: Problem komplett gelöst!
|