Train App is a command line based application that allows users to interact with a train ticketing system. Users can check train routes, trips, and available tickets, as well as register, log in, and buy tickets if they are a customer. This application uses a local SQLite database to store data. This application was made in one of our subjects TDT4145 as a semester project to show that we both understand databases but can also make use of them in our applications.
_______ _______ _______ _______ ___
/ \ / \ / \ / \ / |\_
| NORD | | LANDS | | BANEN | | S J | | |____\_
|_________|_|_________|_|_________|_|_________|_|_ |______|
O O O O O O O O O\/_|
- Register as a customer
- Log in as a customer
- View all stations
- View all train routes for a specific station on a specific weekday
- View all train trips for a specific date and start and end station
- View all available tickets between a start station and an end station for a given route
- Buy tickets (for logged in customers only)
- View future tickets (for logged in customers only)
- Visualization of train wagons for choosing placement.
Run the train_app.py
Python file to start the application. Upon starting, you will be greeted with a list of commands. Type a command and press Enter to execute it. To exit the application, type 'exit' and press Enter.
help
- displays a list of commandsexit
- exits the appstations
- lists all stationstrain routes, <weekday>, <station>
- lists all train routes for a specific station on a specific weekdaytrain trips, <DD.MM.YYYY>, <HH:MM>, <start station>, <end station>
- lists all train trips for a specific date and start and end stationregister
- registers as a Customerlogin
- logs in as a Customertickets, <trip ID>, <start station>, <end station>
- lists all available tickets between a start station and an end station for a given routebuy tickets, <trip ID>, <start station>, <end station>, [(<wagon number>,<seat/bed number>)]
- reserve a seat/bed in a specific wagon between a start station and an end station for a given route (logged in customers only)my tickets
- lists all future tickets for the logged in Customer
- Python 3.6 or higher
This project is released under the MIT License.