A vaccine tracking app, designed and implemented for our CPSC 471 - Database Management Systems course project. This app was built using the Django framework and an SQLite3 database.
Ensure that you have a Django-compatible version of Python installed on your machine. Django 3.0 currently supports Python 3.6, 3.7, 3.8, and 3.9. For more information on Django-Python compatibility, see Django compatibility
Use pip to install the required dependencies for this project.
pip install -r requirements.txtYou must initialize the database the first time you run the application. To do this, run the following commands:
python manage.py makemigrations
python manage.py migrateDjango's base manage.py utility tool provides some built in command line commands to interact with the project. These commands must be run from the cpsc471-project directory.
To run the development server, run the following command:
python manage.py runserverThis will start the development server running on port 8000. Navigate to http://localhost:8000 or http://127.0.0.1:8000 in a browser of your choice to see the development server in action. All HTTP requests and SQL transactions will be logged in the server console for your convenience.
Since the database is local to each machine, you will need to create an admin user to be able to access to the administration site. To do this, run the following command and follow the prompts to create an admin user:
python manage.py createsuperuserOur project ships with some sample data in a csv file. To load this data, run the following command:
python manage.py populate_db sampledata3.csvTo clear the database of all application data (models excluding admin/authentication data), run the following command:
python manage.py clear_dbOur application has two main features, the administration site (generated by Django) and the user site, developed by our group. The user site has two user types who have unique features available to them. (Nurse and Civilian)
The admin site is available at http://localhost:8000/admin/ or http://127.0.0.1:8000/admin/.
Administrators can:
- View and edit any entities within the database
- Add or remeove entities in the database
- Create additional administrators
Within the user site, we have two user subtypes, civilian users and nurse users. These user types are available from the root index page at http://localhost:8000 or http://127.0.0.1:8000.
Civilian users can:
- Log into the system
- Register as a new civilian user
- View their basic health information, including any health conditions
- View a basic risk assessment score, based on factors such as age, occupation, location, and health conditions
- View their appointments
- Create new appointments
- View their family doctor's information
When Registering a Civilian, the civilian is prompted to enter required information to inject them into the database as a civilian entity object. Such information included: HealthCare Number, Phone Number, Age, Gender, First Name, Last Name, and Doctor Information. Additionally, to gauge a civilians risk factor they are requried to answer whether they work in healthcare, and if they live in a high risk area. They are also able to add pre-existing health conditions, but this is not manditory like the previous information.
When Logging in as a Aivilian the user is prompted to enter their HCC number to access their homepage. Once an existing HCC number in the system is entered, they will be redirected the the Civilian homepage.
When Adding an Appointment a user is prompted to select the vaccination site they wish to be vaccinated at, the vaccine manufacturer to be vaccinated by, and finally to slect a date to book their vaccinatino appointment. The date’s minimum allowable date is determined by the civilians risk factor information, where if they are considered low risk, they may book an appointment 6 months out from today's date, if they are medium risk, they may book an appointment 3 months out from today's date, and if they are high risk, they may book immediately. Following submission of an appointment form, the system will randomly assign an appointment ID to identify the appointment in the system, and assign a nurse who works at the civilians desired vaccination site, and a civilian may view their appointment information on the View Appointment page.
When Editing Civilian Info a user is prompted to change SOME of their information. The form they can fill out has placeholders that contain their original information, where they can change it if they desire. (Note, no section is mandatory to fill out as they already exist in the database) The information they are allowed to change include: First Name, Last Name, Address, Phone Number, and Family Doctor Information.
Nurse users can:
- Log into the system
- Register as a new nurse user
- View their upcoming appointments
- View all available vaccines in the database
- Get a detailed view on a specific vaccine, including where the vaccine is stored and disposed, and if there are specific conditions for either of these actions.
- View their available PPE and their supplier information
When Editing Nurse Info the user is prompted to change SOME of their information. The form they can fill out has placeholders that contain their original information, where they can change it if they desire. (Note, no section is mandatory to fill out as they already exist in the database) The information they are allowed to change include: First Name, Last Name, Address, Phone Number, and vaccination site.
When Viewing Vaccine Info A nurse can view information about each vaccine in the system, which displays information such as DIN no, vaccine to treat, recommended dosage, expiry date, and manufacturer name. Additionally, they can view “more info” which displays side effects of each vaccine, storage information and disposal information.