PHP Classes

How to Create a PHP Task List Application that Allows Users to Share Tasks with Each Other Using the Package Task List: Manage and share a list of tasks

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2024-12-19 (3 months ago) RSS 2.0 feedNot enough user ratingsTotal: 19 This week: 1All time: 11,370 This week: 42Up
Version License PHP version Categories
tasklist 1.0The PHP License7Time and Date, User Management, PHP 7, A...
Description 

Author

This package can manage and share a list of tasks.

It provides an application that can perform several tasks with users, tasks, task lists, and tasks shared between users.

The backend provides an API that can serve the frontend pages that the application users can access.

Currently, the backend can:

- Manage the user registration and login

- Manage the tasks created by the users

- Manage the tasks shared between users

Innovation Award
PHP Programming Innovation award nominee
December 2024
Number 7
Task management is critical for any professional to make good use of their time to do the priority work they need to do to gain good compensation for their work.

Task list management is a useful tool that every professional should to remember the most important tasks they need to do first.

This package implements a task management list application that allows professionals to share tasks with other team members.

Manuel Lemos
Picture of Edward Paul
  Performance   Level  
Innovation award
Innovation award
Nominee: 12x

Winner: 1x

 

Documentation

TaskList Application

Welcome to TaskList, a simple task management application with a multi-container Docker setup.

Setup Instructions

Prerequisites

  1. Docker installed on your system.
  2. Ensure `docker-compose` is available.

Environment Configuration

Create .env files for both the backend and frontend services:

Backend (backend/.env)

APP_NAME=TaskList
APP_ENV=local
APP_KEY=base64:APP_KEY_HERE
APP_DEBUG=true
APP_URL=http://localhost:9001

DB_CONNECTION=mysql
DB_HOST=db
DB_PORT=3306
DB_DATABASE=laravel
DB_USERNAME=root
DB_PASSWORD=root

Frontend (frontend/.env.local)

NEXT_PUBLIC_API_URL=http://localhost:9001/api

Starting the Application

Clone the repository:

git clone https://github.com/infinitypaul/tasklist.git
cd tasklist

Start the Docker containers:

docker-compose up --build

After the containers are running, access the services:

Frontend: http://localhost:3000 Backend: http://localhost:9001

API Endpoints

Authentication

| Method | Endpoint | Description | Payload | |--------|----------------|------------------------|----------------------------------------------------------| | POST | /api/register | Register a new user | { name, username, email, password, password_confirmation } | | POST | /api/login | Login an existing user | { email, password } | | POST | /api/logout | Logout a user | None | | GET | /api/me | Get user profile | None |

Tasks API Endpoints

| Method | Endpoint | Description | Payload | |--------|--------------------------|------------------------------------|------------------------------| | GET | /api/tasks | Get all tasks for the user | None | | POST | /api/tasks | Create a new task | { name, description } | | GET | /api/tasks/{id} | Get details of a specific task | None | | PUT | /api/tasks/{id} | Update a task | { name, description } | | POST | /api/tasks/mark/{id} | Toggle task completion status | None |

Shared Tasks

| Method | Endpoint | Description | Payload | |--------|-----------------------------|--------------------------------------|------------------------------| | GET | /api/tasks/shared | Get tasks shared with the user | None | | POST | /api/tasks/share/{id} | Share a task with another user | { username, permission } | | GET | /api/tasks/{id}/shared | Get users a task is shared with | None |

Permissions

| Method | Endpoint | Description | Payload | |--------|---------------------|----------------------------|---------| | GET | /api/permissions | Get list of permissions | None |

tasklist/
??? backend/              # Laravel Backend
?   ??? app/              # Application code
?   ??? database/         # Migrations and Seeders
?   ??? public/           # Publicly accessible files
?   ??? .env              # Environment file
?   ??? Dockerfile        # Docker configuration
??? frontend/             # Next.js Frontend
?   ??? src/            # Page components
?   ??? components/       # Reusable components
?   ??? .env.local        # Environment file
?   ??? Dockerfile        # Docker configuration
??? docker-compose.yml    # Multi-container setup
??? README.md             # Documentation

Troubleshooting

Ports in Use: Stop other services running on 9001 or 3000 before starting Docker. Environment Variables: Double-check .env files for typos or missing keys.


  Files folder image Files (112)  
File Role Description
Files folder imagebackend (15 files, 8 directories)
Files folder imagefrontend (10 files, 2 directories)
Accessible without login Plain text file .env Data Auxiliary data
Accessible without login Plain text file docker-compose.yml Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:19
This week:1
All time:11,370
This week:42Up