Skip to content

The Self-Assessment of Organisational Readiness Tool is a self-assessment framework for organisations to evaluate and strengthen their research capabilities in healthcare practices.

Notifications You must be signed in to change notification settings

RSE-Sheffield/SORT

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Run Django checks

SORT

Self-Assessment of Organisational Readiness Tool

The SORT provides a comprehensive self-assessment framework, enabling organisations to evaluate and strengthen their research capabilities within nursing and broader health and care practices. By guiding you through forty-four targeted statements, SORT helps assess your current level of research maturity and the support available for nurses involved in research. Upon completion, your organisation will be equipped to create a tailored improvement plan to better integrate research into nursing practice, ultimately contributing to improved patient care.

Running Locally

Follow these steps to set up and run the app locally:


Prerequisites, ensure the following are already installed on your system:

  • Python 3.12
  • pip
  • Nodejs (20.x)

  1. Clone the project repository to your local machine
git clone <repository-url>

  1. Create and activate a virtual environment
python -m venv .venv
source .venv/Scripts/activate

  1. Install dependencies
# Install python requirements
pip install -r requirements.txt
# Install nodejs requirements
npm install

  1. Configure the database
python manage.py migrate

  1. Create a superuser
python manage.py createsuperuser

  1. Create a .env file in the project root directory and add the following environment variables:
DJANGO_SECRET_KEY=your_secret_key
DJANGO_DEBUG=True
DJANGO_ALLOWED_HOSTS=127.0.0.1 localhost

  1. Finally, start the development server
python manage.py runserver
  1. Start the vite javascript server (in a different terminal)
npm run dev

The app will be available at http://127.0.0.1:8000.


  1. Import test data by following the instructions as data/README.md.

Deployment

Please read docs/deployment.md.

Vite integration

The SORT app uses some javascript components such as the survey configurator and the survey response form. This is implemented using the svelte framework and vite is used as the bundler. Vite also provides a live server for development which includes HMR (hot module reloading).

In order to integrate this into the html template, a tag library is created at /home/templatetags/vite_integration.py.

  • The vite_client template tag is used to include Vite's HMR javascript code.
  • The vite_asset tag is used to include asset files (e.g. typescript files) in the template.
    • In debug mode, this creates a link directly to the vite dev server normally located at http://localhost:5173
    • In production mode, it links to assets within the /static/ url path.

Before deployment

The script files within /ui_components must be built into the static folder before deployment. This can be done by running:

npm run build

This will transpile the typescript files and write them into /static/ui-components/ folder.

Then run django's collectstatic to gather all files into the static folder.

python manage.py collectstatic

About

The Self-Assessment of Organisational Readiness Tool is a self-assessment framework for organisations to evaluate and strengthen their research capabilities in healthcare practices.

Resources

Stars

Watchers

Forks