A feature-rich TODO application built with Django REST Framework and PostgreSQL.
- User authentication (login/signup)
- Create, read, update, and delete tasks
- Reorder tasks (drag and drop)
- Add images to tasks
- Add PDF files to tasks (with compression)
- Customize background color and theme for each task
- Set due dates for tasks
- Mark tasks as completed
- Dark mode toggle
- Calendar view for task deadlines
- Highlight tasks with custom colors
- Backend: Django, Django REST Framework
- Database: PostgreSQL
- Frontend: HTML, CSS, JavaScript, Bootstrap 5
- Authentication: JWT (JSON Web Tokens)
- File Handling: Pillow, PyPDF2
-
Clone the repository:
git clone <repository-url> cd TODOapp -
Install dependencies:
pip install -r requirements.txt -
Configure PostgreSQL:
- Create a database named
todo_db - Update database settings in
todo_drf/todo_project/settings.pyif needed
- Create a database named
-
Run migrations:
cd todo_drf python manage.py migrate -
Create a superuser:
python manage.py createsuperuser -
Run the development server:
python manage.py runserver -
Access the application at http://localhost:8000 (most probably port 8000)
-
Authentication:
POST /api/token/: Obtain JWT tokenPOST /api/token/refresh/: Refresh JWT token
-
Users:
POST /api/users/: Register a new userGET /api/users/: Get user profile
-
Tasks:
GET /api/tasks/: List all tasksPOST /api/tasks/: Create a new taskGET /api/tasks/{id}/: Get a specific taskPUT/PATCH /api/tasks/{id}/: Update a taskDELETE /api/tasks/{id}/: Delete a taskPOST /api/tasks/{id}/reorder/: Reorder a task
-
Task Images:
POST /api/tasks/{id}/images/: Upload an image for a taskDELETE /api/tasks/{id}/images/{image_id}/: Delete an image
-
Task Files:
POST /api/tasks/{id}/files/: Upload a PDF file for a taskDELETE /api/tasks/{id}/files/{file_id}/: Delete a file
todo_drf/
├── manage.py
├── media/
│ └── uploads/
├── static/
│ ├── css/
│ └── js/
├── templates/
│ ├── base.html
│ ├── home.html
│ └── registration/
│ ├── login.html
│ └── register.html
├── todo_app/
│ ├── admin.py
│ ├── apps.py
│ ├── models.py
│ ├── permissions.py
│ ├── serializers.py
│ ├── tests.py
│ ├── urls.py
│ ├── views.py
│ ├── views_auth.py
│ └── views_frontend.py
└── todo_project/
├── asgi.py
├── settings.py
├── urls.py
└── wsgi.py