Skip to content

Dashboard: Connect to real database and fix duplicate sections

maheshwaram yogesh requested to merge dashboard-analytics-v2 into main

Changes Made

  • Connected dashboard to real SQLite database (was showing hardcoded fake data before)
  • Metric cards now show live counts from database (Total, Verified, Open, Resolved)
  • Reports by Category chart now pulls real data
  • Report Status Overview chart now pulls real data
  • Safety Hotspots now calculated from real submitted reports
  • Recent Reports table now shows actual database records
  • Community Insights now shows real top category and top location
  • Removed duplicate Recent Reports section
  • Removed duplicate Community Insights section
  • Fixed database path issue caused by OneDrive blocking SQLite

Tested

  • Dashboard loads successfully
  • All metrics show correct numbers
  • Charts render with real data
  • Tested with 4 sample reports

Related

  • Fixes Bug #3, #7, #8, #11 from code review

Merge request reports

Loading