mirror of
https://github.com/bitbaum/orangecat.git
synced 2026-12-05 10:07:35 +01:00
- Fix currency defaults (SATS → CHF) across forms, configs, and API routes - Remove @ts-nocheck from socialService.ts and improve type safety - Replace console.log statements with proper logger utility in production code - Additional type safety improvements and code quality enhancements - Documentation updates for improved maintainability All changes follow DRY, SSOT, and separation of concerns principles.
2.8 KiB
2.8 KiB
Path Consistency Plan
Created: 2025-01-30
Purpose: Standardize all entity list pages to /dashboard/{entity} pattern for consistency
🎯 Current State Analysis
✅ Already Under /dashboard/
/dashboard- Main dashboard/dashboard/store- Products (special name)/dashboard/services- Services/dashboard/causes- Causes/dashboard/projects- Projects/dashboard/groups- Groups (just fixed)/dashboard/ai-assistants- AI Assistants/dashboard/wallets- Wallets
❌ Need to Move to /dashboard/
/assets→/dashboard/assets/loans→/dashboard/loans/events→/dashboard/events(needs entity list page, marketing stays at/events)
📋 Standardization Rules
Pattern
- Main Dashboard:
/dashboard - Entity List Pages:
/dashboard/{entity} - Entity Create Pages:
/dashboard/{entity}/create - Entity Detail Pages: Can be at root level (e.g.,
/projects/[id],/groups/[slug])
Special Cases
- Products: Uses
/dashboard/store(not/dashboard/products) - keep as is - Events: Marketing page at
/events, entity list at/dashboard/events
🔧 Implementation Steps
1. Update Entity Registry
asset.basePath:/assets→/dashboard/assetsasset.createPath:/assets/create→/dashboard/assets/createloan.basePath:/loans→/dashboard/loansloan.createPath:/loans/create→/dashboard/loans/createevent.basePath:/events→/dashboard/eventsevent.createPath:/events/create→/dashboard/events/createproject.basePath:/projects→/dashboard/projects(if not already)
2. Move Pages
src/app/(authenticated)/assets/page.tsx→src/app/(authenticated)/dashboard/assets/page.tsxsrc/app/(authenticated)/loans/page.tsx→src/app/(authenticated)/dashboard/loans/page.tsx- Create
src/app/(authenticated)/dashboard/events/page.tsx(entity list) - Keep
src/app/events/page.tsx(marketing page)
3. Create Redirects
src/app/assets/page.tsx→ redirect to/dashboard/assetssrc/app/loans/page.tsx→ redirect to/dashboard/loans- Update any create page redirects
4. Update References
- Navigation (auto-generated from registry)
- Internal links
- User menu items
- Any hardcoded paths
5. Standardize Layouts
- Ensure all entity list pages use
EntityListShell - Loans page needs refactoring to use
EntityListShell
✅ Success Criteria
- All entity list pages are at
/dashboard/{entity} - All entity create pages are at
/dashboard/{entity}/create - All pages use
EntityListShellfor consistency - Old paths redirect to new paths
- Navigation is consistent and auto-generated
Last Modified: 2025-01-30
Last Modified Summary: Initial path consistency plan