Commit Graph

37 Commits

Author SHA1 Message Date
7d88ad036d 🔧 Fix location name: Use real location name from API instead of search term
- Added hidden field 'realLocationName' to store actual location name from Nominatim API
- Updated location saving to use real location name (display_name) instead of search term
- Fallback to search term if real location name not available
- Now saves proper location names like 'Marienplatz, Altstadt-Lehel, München, Bayern, Deutschland' instead of just 'München'
- Improved location data quality in database
2025-09-08 21:41:58 +02:00
2becf784bd 🔧 Fix settings modal: Load current user preferences
- Added show_in_leaderboard to user-player API response
- Improved loadSettings() function with better error handling
- Added console logging for debugging
- Settings modal now shows current user preference instead of always 'off'
- Fixed dependency on currentPlayerId (now uses currentUser.id directly)
2025-09-08 19:18:35 +02:00
fbd8677709 🔧 Fix settings API: Use public endpoint for logged-in users
- Changed from /api/v1/private/update-player-settings to /api/v1/public/update-player-settings
- Removed API key requirement for logged-in users
- Added both public and private endpoints for flexibility
- Fixed 401 Unauthorized error in settings modal
2025-09-08 19:16:57 +02:00
70ceb2da25 🔒 Add privacy settings for leaderboard visibility
 Features:
- Added show_in_leaderboard column to players table (default: false)
- Replaced Quick Actions with Settings section in dashboard
- Added toggle switch for leaderboard visibility
- Created settings modal with privacy controls

🔧 API Changes:
- Added /api/v1/private/update-player-settings endpoint
- Updated best-times queries to filter by show_in_leaderboard
- Updated times-with-details to respect privacy settings
- Added updated_at column to players table

🎨 UI/UX:
- Modern toggle switch design
- Responsive settings modal
- Success/error notifications
- Clear privacy explanation

🔐 Privacy:
- Default: Times are NOT shown in global leaderboard
- Users can opt-in via settings
- Personal dashboard always shows own times
- Global leaderboard only shows opted-in users
2025-09-08 19:14:17 +02:00
ecb6291c74 🔧 Fix API documentation: Correct base URL
- Updated base URL from 'https://ninja.reptilfpv.de' to 'https://ninja.reptilfpv.de/api'
- All API endpoints now correctly prefixed with /api
- Fixes 404 errors when accessing API endpoints
2025-09-08 18:05:43 +02:00
c74bfb4394 🔧 Fix CORS: Allow all origins for development
- Simplified CORS configuration to allow all origins (*)
- Removed origin restrictions for easier development
- Fixed CORS preflight request handling
- Now allows requests from any domain including 192.168.1.96
2025-09-08 18:02:00 +02:00
c347ddb7b4 📚 Add comprehensive API documentation
- Created detailed API.md with all endpoints
- Documented Public, Private, Web, Admin and Achievements APIs
- Added request/response examples for all routes
- Included data models and error handling
- Added authentication methods and status codes
- Comprehensive documentation for 55+ API endpoints
2025-09-08 17:33:23 +02:00
ab4560fbbd Add.pgpass 2025-09-08 14:35:51 +02:00
53db3137ff 🔐 Update project: Add .gitignore and GCP credentials
- Added comprehensive .gitignore for Node.js project
- Excluded MCP server directories (gitea-mcp, gcp-mcp)
- Added GCP service account credentials
- Updated project structure for better organization
2025-09-08 14:33:02 +02:00
70d4db9901 PWA improvements 2025-09-07 17:10:50 +02:00
5bed125cf6 Achivements abends um 19 uhr 2025-09-07 16:54:09 +02:00
8342d95a13 Notifications, div fixes, kekse für last location 2025-09-06 12:37:10 +02:00
61d5ef2e6f Achivement System 2025-09-05 17:56:23 +02:00
a78a8dc3ce edia all routes 2025-09-05 13:15:11 +02:00
3872397082 Mobile desighn Adjustments 2025-09-05 12:37:33 +02:00
00849e6d15 better gitignore 2025-09-05 07:45:02 +02:00
4d00be8127 Keks notice! 2025-09-05 07:42:07 +02:00
b0b5149069 Add Google Login 2025-09-05 06:51:31 +02:00
54353e06f2 .gitignore and server.log added 2025-09-04 17:28:15 +02:00
1f82c98646 Statistik backend and favicon 2025-09-04 17:27:45 +02:00
eb1d713942 Refactor ALL 2025-09-04 14:31:17 +02:00
f6cd5c734f Separieren vom css und js und fixes 2025-09-04 14:14:59 +02:00
0cfac629b5 Add location request 2025-09-04 13:16:42 +02:00
915ed53b42 Push WesocketChanges 2025-09-03 17:33:36 +02:00
1a377517a6 AdminDashboard 2025-09-03 17:13:18 +02:00
e4f6218066 Add linking of RFID with camera 2025-09-03 16:42:18 +02:00
33f3f613e6 Merge branch 'main' of https://github.com/reptil1990/ninjaserver 2025-09-03 14:34:06 +02:00
cd9fbce5f9 Fixed Reset PW! 2025-09-03 14:24:41 +02:00
e832317b8a Update README.md 2025-09-03 14:10:41 +02:00
f20f9b538d Merge pull request #1 from reptil1990/cursor/debug-password-reset-functionality-8b51
Debug password reset functionality
2025-09-03 14:05:26 +02:00
Cursor Agent
c2baf2a9f1 Rotate Supabase API key for reset password page
Co-authored-by: reptil1990 <reptil1990@gmail.com>
2025-09-03 12:04:54 +00:00
96687f2210 Added Email for Supabase 2025-09-03 13:34:10 +02:00
a9ec8562dd Update desighn login.html 2025-09-03 12:32:01 +02:00
5730e0e12f Changed to tabs for time 2025-09-03 12:27:00 +02:00
1d3d076a1d Update Design 2025-09-03 12:10:35 +02:00
3b85aa8cd4 Progress 2025-09-03 11:23:24 +02:00
e6cf08893e Initial local commit 2025-09-03 11:07:29 +02:00