How gspagare/contact_management_system works
Project type and purpose
• This is a full-stack web application (“Contact Management System”) built with Flask.
• Purpose: Allow public users to submit contact details via a form and let administrators log in to view/manage those submissions.
File structure
• Top-level Python modules:
– app.py: application entrypoint, route definitions
– config.py: configuration (DB URI, secret keys)
– extensions.py: Flask extensions instantiation (SQLAlchemy, LoginManager, WTF)
– forms.py: WTForms classes for ContactForm and AdminLoginForm
– models.py: SQLAlchemy models (Contact, AdminUser)
• Templates folder: HTML views, using Jinja2 for base.html, home, contact form, admin login/dashboard, manage admins
• Static folder: CSS (style.css) and JS (script.js) for client-side styling and tiny interactions
• requirements.txt: pinned Python dependencies
• README.md: high-level architecture and install/run instructions
README for additional insights
• SQLite is the persistent store.
• Flask-Login secures the /admin routes.
• Flask-WTF drives form validation and CSRF protection.
• Environment variables control secret keys and Flask’s run mode.