mirror of
https://github.com/pacnpal/thrillwiki_django_no_react.git
synced 2025-12-27 14:07:06 -05:00
8.1 KiB
8.1 KiB
ThrillWiki Implementation Plan
User Review Required
Important
Measurement Unit System: The backend will store all values in Metric. The Frontend (
useUnitscomposable) will handle conversion to Imperial based on user preference. Sacred Pipeline Enforcement: All user edits createSubmissionrecords (stored as JSON). No direct database edits are allowed for non-admin users.
Proposed Changes
Backend (Django + DRF)
1. Core & Auth Infrastructure
apps.core: ImplementTrackedModelusingpghistoryfor all core entities to support Edit History and Versioning (Section 15).apps.accounts:User&UserProfilemodels (Bio, Location, Home Park).- Settings Support: Endpoints for changing Email, Password, MFA, and Sessions (Section 9.1-9.2).
- Privacy: Fields for
public_profile,show_location, etc. (Section 9.3). - Data Export: Endpoint to generate JSON dump of all user data (Section 9.6).
- Account Deletion:
UserDeletionRequestmodel with 7-day grace period (Section 9.6).
2. Entity Models & Logic ("Live" Data)
apps.parks:Park(with Operator/Owner FKs, Geolocation).apps.rides:Ride(Status FSM),RideModel,Manufacturer,Designer.apps.rides(Credits):RideCreditThrough-Model withcount,rating,date,notes. Constraint: Unique(user, ride).apps.companies:Companymodel with types (Manufacturer,Designer,Operator,Owner).apps.lists:UserList(Ranking System) andUserListItem.apps.reviews:Reviewmodel (GenericFK) with Aggregation Logic.
3. The Sacred Pipeline (apps.moderation)
- Submission Model: Stores
changes(JSON),status(State Machine),moderator_note. - Submission Serializers: Handle validation of "Proposed Data" vs "Live Data".
- Queue Endpoints:
list_pending,claim,approve,reject,activity_log,stats. - Reports:
Reportmodel and endpoints.
Frontend (Nuxt 4)
1. Initial Setup & Core
- Composables:
useUnits(Metric/Imperial),useAuth(MFA, Session),useApi. - Layouts: Standard Layout (Hero, Tabs), Auth Layout.
2. Discovery & Search (Section 1 & 6)
- Global Search: Hero Search with Autocomplete (Parks, Rides, Companies).
- Discovery Tabs (11 Sections):
- Trending Parks / Rides
- New Parks / Rides
- Top Parks / Rides
- Opening Soon / Recently Opened
- Closing Soon / Recently Closed
- Recent Changes Feed
3. Content Pages (Read-Only Views)
- Park Detail: Tabs (Overview, Rides, Reviews, Photos, History).
- Ride Detail: Tabs (Overview, Specifications, Reviews, Photos, History).
- Company Pages: Manufacturer, Designer, Operator, Property Owner details.
- Maps: Interactive "Parks Nearby" map.
4. The Sacred Submission Pipeline (Write Views)
- Submission Forms (Multi-step Wizards):
- Park Form: Location, Dates, Media, Relations.
- Ride Form: Specs (with Unit Toggle), Relations, Park selection.
- Company Form: Type selection, HQ, details.
- Photo Upload: Bulk upload, captioning, crop.
- Editing: Load existing data into form -> Submit as JSON Diff.
5. Moderation Interface (Section 16)
- Dashboard: Queue stats, Assignments.
- Queues:
- Pending Queue: Filter by Type, Submitter, Date.
- Reports Queue.
- Audit Log.
- Review Workspace:
- Diff Viewer: Visual Old vs New comparison.
- Actions: Claim, Approve, Reject (with reason), Edit.
6. User Experience & Settings
- User Profile: Activity Feed, Credits Tab, Lists Tab, Reviews Tab.
- Ride Credits Management: Add/Edit Credit (Date, Count, Notes).
- Settings Area (6 Tabs):
- Account & Profile (Edit generic info).
- Security (MFA setup, Active Sessions).
- Privacy (Visibility settings).
- Notifications.
- Location & Info (Timezone, Home Park).
- Data & Export (JSON Download, Delete Account).
7. Lists System
- List Management: Create/Edit Lists (Public/Private).
- List Editor: Search items, Add to list, Drag-and-drop reorder, Add notes.
Verification Plan
Automated Tests
- Backend:
pytestfor all Model constraints and API permissions.- Test Submission State Machine:
Pending -> Claimed -> Approved. - Test Versioning: Ensure
pghistorytracks changes on approval.
- Test Submission State Machine:
- Frontend:
vitestfor Unit Tests (Composables).
Manual Verification Flows
-
Sacred Pipeline Flow:
- User: Submit a change to "Top Thrill 2" (add stats).
- Moderator: Go to Queue -> Claim -> Verify Diff -> Approve.
- Public: Verify "Top Thrill 2" page shows new stats and "Last Updated" is now.
- History: Verify "History" tab shows the update event.
-
Ride Credits:
- Go to "Iron Gwazi" page.
- Click "Add to Credits" -> Enter
Count: 5,Rating: 4.5. - Go to Profile -> Ride Credits. Verify Iron Gwazi is listed with correct data.
-
Data Privacy & Export:
- Go to Settings -> Privacy -> Toggle "Private Profile".
- Open Profile URL in Incognito -> Verify 404 or "Private" message.
- Go to Settings -> Data -> "Download Data" -> Verify JSON structure.
Gap Reconciliation Batches (Added 2025-12-26)
Important
These batches were identified during the Full Project Synchronization audit. Refer to
GAP_ANALYSIS_MATRIX.mdfor detailed per-feature status.
BATCH 1: Critical Missing Pages (HIGH PRIORITY)
/my-credits- Ride Credits Dashboard with stats, filters, quick increment/settings- Full Settings Page (6 sections: Account, Security, Privacy, Notifications, Location, Data)/parks/nearby- Location-based Discovery with Leaflet map, geolocation, radius slider/my-submissions- Submission History for user's past edits- Static Pages:
/terms,/privacy,/guidelines
BATCH 2: Missing Tabs on Existing Pages (HIGH PRIORITY)
- Park Detail - Add Reviews, Photos, History tabs
- Ride Detail - Add Specifications, Reviews, Photos, History tabs
- Homepage - Expand to 11 Discovery Tabs (All, Parks, Coasters, Flat, Water, Dark, Shows, Transport, Manufacturers, Designers, Recent)
- Profile Page - Add Reviews, Ride Credits tabs
BATCH 3: Missing Components (MEDIUM PRIORITY)
ReviewCard.vue- User review display with votingCreditCard.vue- Ride credit display with quick actionsStarRating.vue- Star rating visualizationDiffViewer.vue- Side-by-side comparison for moderationImageGallery.vue- Photo gallery with lightboxAppFooter.vue- Site-wide footerBreadcrumbs.vue- Hierarchical navigation- DatePicker and Range Slider components
BATCH 4: Submission Forms (MEDIUM PRIORITY)
/submit/park- Multi-step park submission wizard/submit/ride- Multi-step ride submission wizard/submit/company- Company submission wizard- Edit forms for existing entities with JSON diff
BATCH 5: Company Pages (MEDIUM PRIORITY)
/designers- Designers listing and detail pages/operators- Operators listing and detail pages/owners- Property Owners listing and detail pages/ride-models/[slug]- Ride Model detail with installations
BATCH 6: Enhanced Features (LOW PRIORITY)
- OAuth Authentication (Google, Discord)
- Magic Link Login
- CAPTCHA integration on forms
- MFA Setup UI
- Review voting (thumbs up/down) and replies
- Recent searches history
- Drag-and-drop list reordering
- Glass card effects (dark mode)
- Reduced motion support
Execution Order Recommendation
- Start with BATCH 1 - Critical pages users expect
- Then BATCH 2 - Complete existing pages
- Then BATCH 3 - Components needed by batches 1 & 2
- Then BATCH 4 - Enable user contributions
- Then BATCH 5 - Additional entity types
- Finally BATCH 6 - Polish and enhancements