Skip to content

Latest commit

 

History

14 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 

Repository files navigation

Library Management System

A web-based Library Management System built using Python's Django, HTML, CSS, and MySQL Database. It provides functionalities for managing books, authors, borrowers, and book loans, including features for searching, checking out, and checking in books, as well as managing fines.

Features

  • Book Management:
    • Add, view, update, and delete book records (ISBN, title).
    • Associate books with authors.
  • Borrower Management:
    • Register new borrowers (name, SSN, address, phone).
    • View a list of registered borrowers.
  • Book Loan Management:
    • Check out available books to registered borrowers.
    • Record the date out and due date for loans.
    • Check in returned books, recording the return date.
  • Search Functionality:
    • Search for books by ISBN, title, or author.
  • Fine Management:
    • Automatically calculate fines for overdue books.
    • Display total fines for each borrower.
    • Option to mark fines as paid.
  • User Interface:
    • Intuitive and user-friendly web interface built with Django templates.

Screenshots

Homepage (/library/)

Homepage Screenshot

Book Search Page (/library/search/)

Book Search Page Screenshot Book List Screenshot

Borrower List Page (/library/borrowers/)

Borrower Page Screenshot

Borrower Registration Page (/library/borrowers/new)

Borrower Registration Page Screenshot

Check In/Out Page (/library/check)

Check In/Out Page Screenshot Check In/Out Results Page Screenshot

Fines Page (/library/fines/)

Fines Page Screenshot

)

How to Run Locally

  1. Prerequisites:

  2. Clone the repository:

    git clone https://github.com/SpitsEric/Library-Management-System.git
    cd Library-Management-System
  3. Set up a virtual environment:

    python3 -m venv venv
    source venv/bin/activate  # On macOS/Linux
    # venv\Scripts\activate   # On Windows
  4. Install dependencies:

    pip install -r requirements.txt
  5. Configure the .env file:

    • This project uses a .env file to store database credentials.

    • In the root of the project, create a file named .env.

    • Add your MySQL connection details to this file in the following format (replace with your actual credentials):

      DATABASE_ENGINE=django.db.backends.mysql
      DATABASE_NAME=library  # Or your database name
      DATABASE_USER=your_mysql_username
      DATABASE_PASSWORD=your_mysql_password
      DATABASE_HOST=localhost  # Or your MySQL host
      DATABASE_PORT=3306       # Or your MySQL port
      
  6. Install python-dotenv: If you haven't already, ensure the python-dotenv library is installed in your virtual environment, as Django will need it to load environment variables from the .env file:

    pip install python-dotenv
  7. Run migrations:

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

    cd LibraryManagementSystem
    python manage.py runserver
  9. Open your web browser and navigate to http://127.0.0.1:8000/ (or http://127.0.0.1:8000/library/ if you have a redirect).

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages