How datanfr/datan works
Datan is a public website for exploring and understanding French MPs’ voting behaviour. A visitor follows pages for MPs, groups and votes; the product also exposes election results, search, rankings and civic information, with authenticated dashboards and API endpoints as supporting capabilities. The file tree identifies the application’s MVC areas, while sampled framework code shows the request bootstrap and routing layers. Most application controller-to-model and controller-to-view calls were not excerpted, so those links are marked unverified rather than asserted as observed.
Main entry points: controllers Page controllers · Groupes.php Group analysis · Votes.php Vote analysis · Auth_Controller.php Authentication
Components 23
Parliament analysis
- Page controllers
application/controllers - MP profiles
application/controllers/Deputes.php - Group analysis
application/controllers/Groupes.php - Vote analysis
application/controllers/Votes.php - Vote data
application/models/Votes_model.php - Rankings
application/views/classements/index.php - Cross-site search
application/controllers/Search.php - Search queries
application/models/Search_model.php - Public pages
application/views
Elections and geography
- Election results
application/controllers/Elections.php - Election records
application/models/Elections_model.php - Place browsing
application/controllers/Departement.php
Accounts and access
- Authentication
application/core/Auth_Controller.php - Account pages
application/controllers/Users.php - Admin dashboard
application/controllers/Admin.php - Votes API
application/controllers/api/Votes.php
CodeIgniter runtime
- HTTP entry
index.php - Runtime bootstrap
system/core/CodeIgniter.php - URI router
system/core/Router.php - Session handling
system/libraries/Session/Session.php - Session database driver
system/libraries/Session/drivers/Session_database_driver.php
Other components
- Website visitor
- Application database
Connections 22
- Website visitor → HTTP entry: requests page
- HTTP entry → Runtime bootstrap: starts runtime
index.php - Runtime bootstrap → URI router: loads router
system/core/CodeIgniter.php - URI router → Page controllers: resolves route
- Page controllers → MP profiles: dispatches MP pages
- Page controllers → Group analysis: dispatches group pages
- Page controllers → Vote analysis: dispatches vote pages
- Group analysis → Vote data: queries votes
- Vote analysis → Vote data: queries votes
- Group analysis → Rankings: renders rankings
- MP profiles → Public pages: renders profiles
- Vote analysis → Public pages: renders vote pages
- Cross-site search → Search queries: runs search
- Search queries → Application database: reads records
- Election results → Election records: loads results
- Place browsing → Election records: loads local results
- Authentication → Session handling: loads session
application/core/Auth_Controller.php - Account pages → Authentication: uses auth base
- Admin dashboard → Authentication: uses auth base
- Votes API → Application database: serves vote data
- Session handling → Session database driver: selects driver
system/libraries/Session/Session.php - Session database driver → Application database: reads and writes
system/libraries/Session/drivers/Session_database_driver.php