The Assignment 2 is asked to build a request forum application, which allows users to create accounts, post their own requests and answer other people's requests.
This program is based on the following structure:
app.py
is main application and used for template rendering, content structuring and some data processing get.py
. Some functions (e.g. Requrements, Shop, Community and shop) are rely on the functions in get.py
to get or set the data from the database. loginModels.py
is for user login/registration process. When user is authenticated, the user ID will be stored based on this model and available for read during the session till logout. sqlModels.py
is used for communication between program and SQLite database. It contains data models, and to help to get/set data from/to databaseformModels.py
is for forms on the website. When the webpage loads the form, the forms will be loaded based on this model. database/main.db
) to store data Note: the main database (database/main.db
) contains some test data. You could use them for program testing.
pip install -r requirements.txt
(Use pip install -r requirements.txt --break-system-packages
if you are working on Linux) flask run
(Use flask run --host=0.0.0.0
if debug on productive server) to start the web server python -m unittest tests/<filename> -v
Name | Student ID | Github ID |
---|---|---|
Hanxun Xu | 23885505 | https://github.com/xosadmin |
Jikang Song | 23877962 | https://github.com/jikang1116 |
Phyo Phyo Wut Yee Khine | 23650578 | https://github.com/Phyo09 |
Chunhui Chu | 24074951 | https://github.com/TonyChyu |