Skip to content

Rub3cK0r3/users-management

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

11 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Library Management System

A full-stack library management app built with a React + TypeScript frontend and a Django REST API backend.

Not just a school project anymore β€” this started as a Django exam and slowly turned into something closer to a real full-stack app.

🎯 Overview

What started as an educational project ended up evolving into a complete system with:

  • ✨ React + TypeScript SPA with a responsive UI
  • πŸš€ Django REST API with JWT authentication
  • πŸ“š Full library management (books, authors, borrowing system)
  • πŸ‘₯ User profiles + permissions
  • 🎨 Clean UI with a simple, custom design system

πŸ“ Project Structure


users-management/
β”œβ”€β”€ frontend/        β†’ React + TypeScript SPA
β”œβ”€β”€ backend/         β†’ Django REST API
└── README.md        β†’ you are here

Inside each part:

  • frontend β†’ pages, components, hooks, API client, styles
  • backend β†’ Django apps, REST API, auth, models

πŸš€ Quick Start

Backend

cd backend
pip install -r requirements.txt
python manage.py migrate
python manage.py createsuperuser
python manage.py runserver

Runs on: http://localhost:8000

Frontend

cd frontend
npm install
npm run dev

Runs on: http://localhost:5173

✨ Features

πŸ“– Books

  • Browse full catalog
  • View details
  • Create / edit / delete books
  • Track availability

✍️ Authors

  • Manage authors
  • Birth / death dates
  • Linked books

πŸ‘₯ Users

  • Profiles with extra info
  • Permissions system
  • Basic penalty logic

πŸ“š Borrowing system

  • Track borrowed books
  • Due dates
  • Overdue detection

πŸ” Auth

  • JWT login system
  • Protected routes
  • Token refresh handling

πŸ› οΈ Tech Stack

Frontend

  • React 18
  • TypeScript
  • Vite
  • React Router
  • Axios
  • Vanilla CSS

Backend

  • Django 6
  • Django REST Framework
  • SimpleJWT
  • CORS headers
  • SQLite (dev)

πŸ“– API (quick look)

Login

POST /biblioteca/login/
{
  "username": "user",
  "password": "pass"
}

Response:

{
  "access": "jwt_token...",
  "refresh": "jwt_token..."
}

Main endpoints

Books

  • GET /catalog/api/books/
  • POST /catalog/api/books/
  • GET /catalog/api/books/{id}/
  • PUT /catalog/api/books/{id}/
  • DELETE /catalog/api/books/{id}/

Authors

  • GET /catalog/api/authors/
  • POST /catalog/api/authors/

Instances

  • GET /catalog/api/bookinstances/
  • PATCH /catalog/api/bookinstances/{id}/

🎨 UI Notes

Nothing fancy here β€” just a custom CSS setup:

  • mobile-first layout
  • flex + grid
  • simple color system
  • no UI frameworks

πŸ”’ Security

  • JWT authentication
  • role-based permissions
  • CORS enabled for frontend
  • token refresh flow

πŸ“Š Models (core idea)

  • User β†’ authentication base
  • Book β†’ main catalog
  • Author β†’ book creators
  • BookInstance β†’ physical copies
  • Perfil β†’ extended user data
  • PermisoE β†’ permissions layer

πŸ”„ Workflow (how it grew)

When adding features:

  1. backend model
  2. serializer
  3. viewset
  4. frontend page
  5. API call
  6. route added

🧠 Notes

  • SQLite is just for dev
  • Django templates still exist but are legacy now
  • backend and frontend are fully separated

πŸ“± Responsive

Works on mobile + desktop:

  • responsive layout
  • touch-friendly UI
  • adaptive navigation

πŸš€ Performance

  • basic code splitting (React Router)
  • optimized Django queries
  • pagination support in API

πŸ› Limitations

  • not production-ready DB setup (yet)
  • some legacy Django views still there
  • admin still uses default Django UI

πŸŽ“ Context

This started as a Django exam project and slowly turned into a full-stack practice app covering:

  • REST API design
  • React SPA architecture
  • authentication flows
  • frontend/backend separation

🀝 Contributing

If you touch it:

  • keep structure consistent
  • use TypeScript types
  • don’t break backend contracts
  • test both sides
  • don’t leave half features

πŸ“„ License

Educational project β€” not meant for production use.

⚠️ Note This is part of my learning path. More here: https://github.com/RubenMurciaeduca

About

Educational full-stack project evolved from a Django exam into a modern React + Django REST application. Includes JWT authentication, REST API architecture, and a fully responsive SPA frontend for library management.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors