Skip to content
This repository was archived by the owner on Nov 20, 2024. It is now read-only.

C-Accel-Project-Old-Version/LEGACY_cript-app-django

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CRIPT app

This repository stores the web application for CRIPT: the Community Resource for Innovation in Polymer Technology.

Setup

  1. Create a new directory to store the project in, navigate to the directory, and create a virtual environment inside it: python3 -m venv venv
  2. Activate the virtual environment: source venv/bin/activate
    • To install packages into the virtual environment: pip install -r requirements.txt
    • To export packages from the virtual environment: pip freeze > requirements.txt
    • To deactivate the virtual environment: deactivate
  3. To run the project, navigate inside the directory with manage.py and use python manage.py runserver. The page will be viewable at http://127.0.0.1:8000
    • To quit the server, use control-c
  4. After making changes to models, the models can be "migrated" to the database using python manage.py makemigrations; python manage.py migrate

Creating a new app inside the project

  1. in the directory with manage.py, create a new app using python manage.py startapp baseapp where baseapp is the name of the app
  2. create a view for the app in baseapp/views.py
  3. map the view to a URL using a URLconf. this should be in baseapp/urls.py
  4. now we need to point the root URLconf at the baseapp.urls module. In dsite/urls.py, add an import for django.urls.include and insert the app in the urlpatterns list

Notes

  • Current cript data model requires user access to theDB password, and potential manual addition of each new user
  • Current cript data model requires user to have access first to create a user node for themself
  • Users should be able to autonomously
    • create accounts (which gives them API access)
    • edit their login password and details
    • create collections and upload data through their credentials

About

Django web application for CRIPT

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published