How tanu048/finance_dashboard works
Finance Dashboard is a role-based web application for managing shared financial records and viewing dashboard insights. A user loads the web interface, authenticates for a JWT, then makes role-guarded API requests: authorized users can browse records and summaries, analysts and admins can view category and monthly trends, and admins can manage records and users. API handlers validate inputs, apply access dependencies, and read or mutate SQLAlchemy-backed state. The README documents recent activity and other endpoints; the graph groups those features under the records router, though their implementation was not sampled.
Main entry points: auth.py Auth endpoints · main.py FastAPI app · users.py User management · records.py Record endpoints
Components 13
Web interface
- FastAPI app
main.py - Page templates
templates - Dashboard client
static/scripts.js
Identity and access
- Auth endpoints
routers/auth.py - User management
routers/users.py - User schemas
schema/users.py - Token schema
schema/auths.py
Finance operations
- Record endpoints
routers/records.py - Record schemas
schema/records.py
Persistence
- Session setup
database/db.py - ORM models
database/models.py - SQLite database
Other components
- User browser
Connections 24
- User browser → FastAPI app: requests pages
- FastAPI app → Page templates: renders
- User browser → Dashboard client: runs client
- Dashboard client → Auth endpoints: calls auth API
- Dashboard client → Record endpoints: calls finance API
- Dashboard client → User management: calls user API
- FastAPI app → Auth endpoints: registers router
- FastAPI app → Record endpoints: registers router
- FastAPI app → User management: registers router
- FastAPI app → Session setup: creates tables
- Auth endpoints → User schemas: validates users
- Auth endpoints → Token schema: shapes token
- Auth endpoints → Session setup: gets sessions
- Auth endpoints → ORM models: queries users
- User management → Auth endpoints: checks admin
- User management → User schemas: validates updates
- User management → Session setup: gets sessions
- User management → ORM models: manages users
- Record endpoints → Auth endpoints: checks roles
- Record endpoints → Record schemas: validates records
- Record endpoints → Session setup: gets sessions
- Record endpoints → ORM models: queries records
- Session setup → ORM models: creates tables
- Session setup → SQLite database: reads and writes