A Metro Ticketing System built using Flask (Python) and MySQL.
Users can issue metro cards, book metro tickets, and track ride history with discounts for students.
β
User Management: Admin & Normal Users
β
Metro Card System: Regular (10% discount) & Student (25% discount)
β
Ticket Booking: Select stations & calculate fare dynamically
β
Transaction Logging: Tracks payments & fare deductions
β
Ride History: View past metro rides
βΉ10 for the next station
βΉ15 for traveling 2 stations ahead
βΉ20 for traveling 3 stations ahead
βΉ25 for traveling 4 stations ahead
βΉ30 for more than 5 stations
Discounts:
MITWPU Students: 25% discount
Regular Card Holders: 10% discount
Non-Card Holders: No discount
- Backend: Flask (Python) π
- Frontend: HTML, CSS, JavaScript π¨
- Database: MySQL π
git clone https://github.com/champst2004/pune-metro.git
cd pune-metroMake sure you have Python installed. Then, install the required libraries:
pip install -r requirements.txtRun tables.sql and stations.sql to create database and tables
python app.pyhttp://127.0.0.1:5000/
| Page | URL | Description |
|---|---|---|
| Home | / |
Landing page |
| Issue Card | /issue_card |
Issue a new metro card |
| View Users | /view_users |
Show all users who have issued a metro card |
| Book Ticket | /book_ticket |
Select stations, calculate fare, and book a ride |
| Ride History | /ride_history |
View past rides of metro card users |