Skip to content

Latest commit

 

History

History
143 lines (84 loc) · 4.69 KB

README.md

File metadata and controls

143 lines (84 loc) · 4.69 KB

Library Management System

An online management system for book borrowings that optimizes the work of library administrators and makes the service more user-friendly.

Features

Authentication and Authorization:

  • Users need to be authenticated before they can access the features of the system.
  • Admin users have additional privileges to manage information within the system.

Books Inventory Management:

  • The system manages the inventory of books, allowing CRUD operations for books.

Borrowing Management:

  • Users can borrow books and create borrowing records.
  • Users can return books, updating the inventory accordingly.
  • Filtering for active borrowings and specific users' borrowings is available.

Users Management:

  • The system manages user authentication and user registration.
  • Users can update their profile information.

Notifications:

  • The system sends notifications about new borrowings created, overdue borrowings, and successful payments.
  • Notifications are sent through a Telegram chat.

Payments Handling:

  • The system supports payments for book borrowings through the Stripe platform.

Swagger Documentation

Docker Containerization

  • The application is containerized using Docker for simplified deployment and management.

Demo

This section contains a screenshot showcasing links to the main functional capabilities of the project.

Technologies

Django - A high-level Python web framework that encourages rapid development and clean, pragmatic design.

Django Rest Framework (DRF) - A powerful and flexible toolkit for building Web APIs.

PostgreSQL - A powerful, open-source object-relational database system.

Redis - An open-source, in-memory data structure store used as a database, cache, and message broker.

Celery - An asynchronous task queue/job queue based on distributed message passing.

Stripe - A platform for processing online payments, commonly used in Django Rest Framework projects to manage financial transactions in web applications.

Python-dotenv - A Python module that reads key-value pairs from a .env file and can set them as environment variables.

Flower - A web-based tool for monitoring and administrating Celery clusters.

Telegram API - An API that enables the integration of Telegram functionality into applications, allowing for the sending of notifications through Telegram chats.

Docker - A platform for developing, shipping, and running applications using containerization.

Swagger - An open-source software framework backed by a large ecosystem of tools that helps developers design, build, document, and consume RESTful web services.

JWT - JSON Web Tokens are used for securely transmitting information between parties as a JSON object.

Architecture

The database structure is as follows:

demo/library_db.jpg

Demo

This section contains a screenshot showcasing links to the main functional capabilities of the project.

library_api

Installation

Using GitHub

  1. Clone the repository:
git clone https://github.com/OlegatorLE/library-team-project
cd library-team-project
  1. Set up the virtual environment and install the required dependencies:
python -m venv venv
source venv/Scripts/activate (on Windows)
source venv/bin/activate (on macOS)
pip install -r requirements.txt
  1. Generate a .env file from .env.sample.

  2. Run the database migrations and load initial data:

python manage.py migrate
python manage.py loaddata library_db_data.json
  1. Run the development server:
python manage.py runserver

Run with Docker

  • Ensure Docker is installed and set up.

  • Execute the following command to build and start the Docker containers:

docker-compose up --build

Getting Access through JWT

  • Create a user using the /api/users/ endpoint.
  • Retrieve an access token using the /api/users/token endpoint.

Swagger Documentation

Access the API documentation at

/api/doc/swagger

Acknowledgments

We would like to extend our gratitude to our mentors, Ivan Ramyk and Serhii Leonenko, for their valuable guidance and thorough review throughout the development and consultation process. Thank you for your support and insights.