Skip to content

nagarajpandith/cas

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Canteen Automation System (CAS) - DBMS Project

Logo

The objective of this project is to develop a system that automates the process of ordering and managing food in a canteen. The system is built using the Django web framework and the Tailwind CSS framework for the frontend design. This will provide a convenient and efficient solution for both Admin and Canteen staff, allowing admin to easily place orders and track their status, and allowing canteen staff to manage the orders efficiently.

Live Project Link

Tech used

                                   

Features

  1. Staff registration and login
  2. Menu management
  3. Order management
  4. Bill generation
  5. Summary of Transactions

Schema Diagram

Screenshot 2022-12-14 at 9 41 22 AM

ER Diagram

Screenshot 2022-12-14 at 9 41 38 AM

Local setup

  • Create virtualenv
  python -m venv env
  env\Scripts\activate
  • Install all the requirements
  pip install -r requirements.txt
  • Install django-tailwind
python -m pip install django-tailwind
  • Start a postgres database called 'cas' on default port (5432)
  • Create .env in root folder and add the following (refer Development Notes)
SECRET_KEY=<django_secret_key>
DATABASE_URL=<your_database_url>
API_KEY=<cloudinary_api_key>
API_SECRET=<cloudinary_api_secret>
CLOUD_NAME=<cloudinary_cloud_name>
  • Make migrations
    python manage.py makemigrations
    python manage.py migrate
  • Create a super user.
    python manage.py createsuperuser
  • Running server
python manage.py runserver
python manage.py tailwind start

Development Notes

  • DATABASE_URL in env is in the form of postgres://user:pass@host/dbname
  • SECRET_KEY can be generated using get_random_secret_key() method
from django.core.management.utils import get_random_secret_key
print(get_random_secret_key())
  • Cloudinary related env vars can be accessed by signing up on Cloudinary and opening up the dashboard.

  • Modify npm bin path (only if you're using Windows). Currently it is set to NPM_BIN_PATH = '/usr/local/bin/npm' for Mac & Linux based systems. If you're using Windows, you need to change it to NPM_BIN_PATH = r"C:\Program Files\nodejs\npm.cmd" in settings.py of cas project. Do not stage settings.py while pushing to repo.

  • If you add install any package during development, add it to requirements.txt by

pip freeze > requirements.txt
  • Develop on a different branch (like 'feat/home-page', 'fix/overflow-issue' for different features/bug fixes and make PR to main or a single branch for all development purposes called 'develop' and make PRs to main from there

Screenshots

  1. Login Page image14

  2. Adding Canteen Items image13

  3. Registering Kitchen Staff image12

  4. Order Canteen Items image10

  5. Home Page image9

  6. View, Update, Delete Order items image7

  7. View and Complete orders image6

  8. Generated Bill Invoice image5

  9. Summary image4

  10. Secure Billing workflow image2

Team Members

Nagaraj Pandith Nidheesha T Rudradeep Roy

Attributions