This program represents a proof of concept of a web application that would allow healthcare providers to securely exchange patient opioid prescription information.
Installation Instruction:
- Ensure Django is installed on your local machine.
- $ pip3 install Django
- $ pip3 install psycopg2
- Install pip if you need to update any python libraries.
- Clone the repository
Database Setup:
- Download and Install Postgresql
- brew install postgres
- brew services start postgres
- Open a postgres command line tool
- psql -U postgres
- Create a new database called Optrak
- CREATE DATABASE optrak;
- Create a new user doctor with password Optrak
- CREATE ROLE doctor WITH LOGIN PASSWORD 'optrak';
- Grant user all privleges on the table
- GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO doctor;
- Exit postgres
- control + Z
Run Webapp
- Update migrations folder
- python3 manage.py makemigrations
- Update database
- python3 manage.py migrate
- Run app server
- python3 manage.py runserver
- Load in web browser
- localhost:8000