Giter Club home page Giter Club logo

ldn_library's Introduction

ldn_library

Overview

ldn_library is a Django-based web application designed to manage a library system. It provides functionalities for adding books, deleting books, inserting users, and borrowing books.

Features

  • Add Book: Users can add books to the library database by providing the title, author, and other relevant information.
  • Delete Book: Users with appropriate permissions can delete books from the library database based on the book's ID.
  • Insert User: Users can be added to the system by providing their first name, last name, and email address.
  • Borrow Book: Users can borrow books from the library by specifying the book ID and user ID.

Installation

  1. Clone the repository:

    git clone [repository-url](https://github.com/LOUDINISouad/ldn_library)
    cd ldn_library
  2. Activate the virtual environment:

    source venv/bin/activate  # Linux/Mac
    # Or
    .\venv\Scripts\activate  # Windows
  3. Apply migrations:

    python manage.py migrate
  4. Run the development server:

    python manage.py runserver

    Usage

Accessing the Application

Interacting with the API using Postman

  • Alternatively, you can use Postman to interact with the application's API endpoints directly.
  • Postman allows you to send HTTP requests to the API endpoints and view the responses.
  • Here's how you can use Postman to interact with the API endpoints:
    1. Open Postman.
    2. Create a new request.
    3. Set the request type (GET, POST, DELETE, etc.).
    4. Enter the URL for the desired API endpoint (e.g., http://localhost:8000/MyLibrary/books).
    5. Send the request and view the response.

API Endpoints

  • Add Book: POST /MyLibrary/books
  • Delete Book: DELETE /MyLibrary/books/<book_id>
  • Insert User: POST /MyLibrary/users
  • Borrow Book: POST /MyLibrary/borrow_book/<book_id>/<user_id>

ldn_library's People

Contributors

loudinisouad avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.