Skip to content

About

A full-featured collaborative SaaS Project Management & Kanban Platform with real-time Socket.IO, RBAC, analytics, and deadline calendar. CodeAlpha Internship Task 3.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Project Management Tool β€” Collaborative SaaS Kanban Platform

CodeAlpha Full Stack Development Internship β€” Task 3
Suggested Repository Name: CodeAlpha_ProjectManagementTool
Live Stack: Node.js β€’ Express.js β€’ MongoDB β€’ Mongoose β€’ HTML5 β€’ CSS3 β€’ JavaScript (ES6+ Vanilla) β€’ Socket.IO β€’ JWT

Node.js Version Database Real-time Security License: MIT


πŸ“Œ 1. Project Overview

ProjectFlow is a modern, high-performance, collaborative Project Management SaaS platform designed for agile teams, engineering squads, and cross-functional organizations. Built for the CodeAlpha Full Stack Development Internship (Task 3), ProjectFlow combines the intuitive card-and-column workflow of Trello, the deadline management of Asana, and the speed of Linear.

The application features an advanced 4-column Kanban board, live Socket.IO WebSockets synchronization, comprehensive task file attachments, recurring task automation, monthly deadline calendar, project CSV export, dynamic team roles (Admin, Lead, Member), audit activity logs, and dark/light theme customization.


✨ 2. Key Features

πŸ” 1. Authentication & Security

  • JWT-Based Authentication: Secure HTTP Bearer token authorization and persistent login sessions.
  • Bcrypt Password Encryption: Industry-standard salt-and-hash encryption via bcryptjs (10 rounds).
  • Protected Express Middleware: Server-side route guards enforcing authentication across all private resources.
  • User Profile Management: Update full name, title, bio, and change account passwords securely.
  • Password Reset Utility: Cryptographic reset token generation and verification (/api/auth/forgot-password & /api/auth/reset-password).
  • Development Demo Accounts: One-click quick login buttons pre-configured for evaluation (mukesh@projectflow.dev, sarah@projectflow.dev, marcus@projectflow.dev).

πŸ“Š 2. Dynamic SaaS Analytics Dashboard

  • MongoDB-Driven Metric Counters: Real-time counts for Total Projects, Active Tasks, In Progress, Review, and Completed items.
  • 7-Day Velocity Chart: Visual SVG task completion trends over the previous 7 days calculated from MongoDB records.
  • Status Distribution Bars: Proportional completion progress across all active projects.
  • Upcoming Deadlines & Overdue Indicators: Proactive highlights for tasks approaching or past due dates.
  • Live Activity Feed: Centralized audit stream recording who created, updated, moved, or commented on tasks.

πŸ“‹ 3. Advanced 4-Column Kanban Board

  • Dedicated Agile Columns:
    • πŸ”˜ To Do
    • 🟑 In Progress
    • 🟠 Review
    • 🟒 Completed
  • HTML5 Drag-and-Drop: Smooth, animated card movement across columns with real-time backend persistence.
  • Mobile / Touch Quick-Move Selector: Seamless dropdown status changer on each card for mobile/touch screens.
  • Colored Category Labels & Priority Badges: Visual tags (Low, Medium, High, Urgent) and colored chips.
  • Overdue Visual Border: Glowing alert border (.task-card-overdue) on past-due task cards.
  • Instant Filters & Search: Filter Kanban cards by title, assignee, and priority in real-time.

πŸ“ 4. Team Collaboration & Project Management

  • Role-Based Access Control (RBAC): Manage workspace projects with owner, admin, lead, member, and viewer roles.
  • Dynamic Role Management: Promotes or reassigns roles (PATCH /api/projects/:id/members/:userId/role).
  • Team Invitations: Invite colleagues by email with pending status tracking (POST /api/projects/:id/invitations).
  • Project Categories & Deadlines: Organize projects by category (Web App, Mobile App, Design, DevOps, Marketing).
  • Ownership Transfer: Secure project transfer with strict permission validation.

πŸ”„ 5. Recurring Tasks Engine

  • Automated task recurrence engine supporting Daily, Weekly, and Monthly schedules.
  • When a recurring task is moved to Completed, the backend automatically schedules and creates the next cycle card in To Do.

πŸ“Ž 6. Task File Attachments

  • Secure multi-file upload engine powered by Multer.
  • Strict file validation: maximum 5MB size limit and safe MIME type filtering (Images, PDFs, Documents, ZIPs).
  • In-modal attachment preview thumbnails, download links, and confirmation-guarded deletion.

πŸ“… 7. Interactive Deadline Calendar View

  • Monthly visual calendar view accessible from My Tasks.
  • Shows deadline chips mapped to specific calendar days with status color coding.
  • Clicking on a deadline card opens the comprehensive task details modal.

πŸ“Š 8. Project CSV Report Export

  • One-click project report generation (GET /api/projects/:id/export-csv).
  • Exports complete task rosters with titles, descriptions, assignees, priorities, column status, due dates, and creation timestamps as standard CSV.

πŸ’¬ 9. Task Comments & Real-Time Discussions

  • Threaded discussions embedded inside every task modal.
  • Author avatars, timestamps, and edit/delete permissions with custom styled modal dialogs (UI.confirm).
  • Real-time comment broadcast via Socket.IO.

πŸŒ— 10. Complete Dark & Light Theme

  • Custom design system with CSS custom properties (--bg-main, --bg-card, --text-main, etc.).
  • Instant theme toggle in the top navigation bar with persistent client preference in localStorage.

πŸ” 11. Multi-Model Global Search (Ctrl + K)

  • Workspace-wide search overlay shortcut (Ctrl + K).
  • Queries Projects, Tasks, and Team Members simultaneously with highlighted result links.

πŸ“œ 12. Comprehensive Audit Activity Logs

  • Audit trails for project and task modifications (GET /api/projects/:id/activities and /api/tasks/:id/activities).
  • Records event types, actor details, previous vs. new values, and relative timestamps.

πŸ”” 13. Real-Time Notification Center (Bonus Feature)

  • In-app notification center and top navbar badge counter.
  • Socket.IO alerts for task assignments, project invites, mentions, and status movements.

πŸ› οΈ 3. Technology Stack

Layer Technologies Used
Frontend HTML5, CSS3 (Custom Design System, CSS Variables, Flexbox/Grid), Vanilla JavaScript (Modular ES6+)
Backend Node.js, Express.js (REST APIs, Controller-Service-Repository pattern)
Database MongoDB, Mongoose ODM
Real-Time Socket.IO (WebSockets with automatic polling fallback)
File Storage Multer file upload middleware with disk storage & validation
Authentication JSON Web Tokens (jsonwebtoken), bcryptjs
Security Helmet.js, CORS, Input validation, Protected Express Middleware
Testing Automated Node.js integration test suites (214 tests across 7 suites)

πŸ“‚ 4. Project Folder Structure

ProjectFlow/
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ config/
β”‚   β”‚   β”‚   └── db.js                      # MongoDB connection logic
β”‚   β”‚   β”œβ”€β”€ controllers/
β”‚   β”‚   β”‚   β”œβ”€β”€ authController.js          # Authentication, JWT, profile, password reset
β”‚   β”‚   β”‚   β”œβ”€β”€ dashboardController.js     # MongoDB metrics, velocity, activity feeds
β”‚   β”‚   β”‚   β”œβ”€β”€ projectController.js       # Projects, members, invitations, CSV export
β”‚   β”‚   β”‚   β”œβ”€β”€ taskController.js          # Tasks, Kanban moves, recurrence, attachments
β”‚   β”‚   β”‚   β”œβ”€β”€ commentController.js       # Comments CRUD
β”‚   β”‚   β”‚   β”œβ”€β”€ notificationController.js  # In-app notifications
β”‚   β”‚   β”‚   β”œβ”€β”€ searchController.js        # Global multi-model search
β”‚   β”‚   β”‚   └── userController.js          # User directory & user profile stats
β”‚   β”‚   β”œβ”€β”€ middleware/
β”‚   β”‚   β”‚   β”œβ”€β”€ auth.js                    # JWT Bearer token authentication guard
β”‚   β”‚   β”‚   β”œβ”€β”€ projectAuth.js             # Project membership & ownership checks
β”‚   β”‚   β”‚   └── errorHandler.js            # Centralized API error handling
β”‚   β”‚   β”œβ”€β”€ models/
β”‚   β”‚   β”‚   β”œβ”€β”€ User.js                    # User schema with bcrypt hooks & roles
β”‚   β”‚   β”‚   β”œβ”€β”€ Project.js                 # Project schema with members & invitations
β”‚   β”‚   β”‚   β”œβ”€β”€ Task.js                    # Task schema with recurrence & attachments
β”‚   β”‚   β”‚   β”œβ”€β”€ Comment.js                 # Task comment model
β”‚   β”‚   β”‚   β”œβ”€β”€ Notification.js            # In-app notification model
β”‚   β”‚   β”‚   └── Activity.js                # Workspace audit log model
β”‚   β”‚   β”œβ”€β”€ routes/
β”‚   β”‚   β”‚   β”œβ”€β”€ authRoutes.js              # /api/auth endpoints
β”‚   β”‚   β”‚   β”œβ”€β”€ dashboardRoutes.js         # /api/dashboard endpoints
β”‚   β”‚   β”‚   β”œβ”€β”€ projectRoutes.js           # /api/projects endpoints & CSV export
β”‚   β”‚   β”‚   β”œβ”€β”€ taskRoutes.js              # /api/tasks endpoints & attachments
β”‚   β”‚   β”‚   β”œβ”€β”€ commentRoutes.js           # /api/comments endpoints
β”‚   β”‚   β”‚   β”œβ”€β”€ notificationRoutes.js      # /api/notifications endpoints
β”‚   β”‚   β”‚   β”œβ”€β”€ searchRoutes.js            # /api/search endpoints
β”‚   β”‚   β”‚   └── userRoutes.js              # /api/users endpoints
β”‚   β”‚   β”œβ”€β”€ utils/
β”‚   β”‚   β”‚   β”œβ”€β”€ jwt.js                     # JWT token signing & verification
β”‚   β”‚   β”‚   └── activityLogger.js          # Activity logging & WebSocket event emitter
β”‚   β”‚   β”œβ”€β”€ seed.js                        # Demo database seeder
β”‚   β”‚   β”œβ”€β”€ autoSeed.js                    # Development auto-seeder
β”‚   β”‚   └── server.js                      # Express server & Socket.IO initialization
β”‚   β”œβ”€β”€ uploads/                           # Secure file attachments directory
β”‚   β”œβ”€β”€ final-master-qa-runner.js          # Master QA test runner executing 7 test suites
β”‚   β”œβ”€β”€ saas-platform-verification.js      # SaaS 12-feature integration test suite (34 tests)
β”‚   β”œβ”€β”€ comprehensive-audit-v2.js          # Full API audit test suite (45 tests)
β”‚   β”œβ”€β”€ profile-and-features-audit.js      # Profile, settings & navigation audit (24 tests)
β”‚   β”œβ”€β”€ test-suite.js                      # Core functional test suite (22 tests)
β”‚   β”œβ”€β”€ deep-verification.js               # Edge-case & permission test suite (40 tests)
β”‚   β”œβ”€β”€ advanced-verification.js           # Workflow integration test suite (19 tests)
β”‚   β”œβ”€β”€ qa-master-audit.js                 # API security & performance audit (30 tests)
β”‚   β”œβ”€β”€ .env                               # Local environment configuration
β”‚   └── package.json                       # Backend dependencies & npm scripts
β”œβ”€β”€ frontend/
β”‚   β”œβ”€β”€ index.html                         # Single-Page Application (SPA) shell
β”‚   β”œβ”€β”€ css/
β”‚   β”‚   β”œβ”€β”€ styles.css                     # SaaS design system, cards, modals, skeletons
β”‚   β”‚   β”œβ”€β”€ kanban.css                     # 4-column Kanban board & drag-and-drop
β”‚   β”‚   └── responsive.css                 # Mobile off-canvas drawer, responsive grid
β”‚   β”œβ”€β”€ js/
β”‚   β”‚   β”œβ”€β”€ config.js                      # API base URL & runtime configuration
β”‚   β”‚   β”œβ”€β”€ api.js                         # Fetch wrapper with Bearer token injection
β”‚   β”‚   β”œβ”€β”€ state.js                       # Centralized reactive client store
β”‚   β”‚   β”œβ”€β”€ ui.js                          # Toasts, styled confirmation modals, formatters
β”‚   β”‚   β”œβ”€β”€ auth.js                        # Sign in, registration & demo logins
β”‚   β”‚   β”œβ”€β”€ theme.js                       # Dark/Light theme manager & persistence
β”‚   β”‚   β”œβ”€β”€ socket.js                      # Socket.IO client & real-time event listeners
β”‚   β”‚   β”œβ”€β”€ dashboard.js                   # Metrics dashboard, velocity chart & activity
β”‚   β”‚   β”œβ”€β”€ projects.js                    # Projects CRUD, invitations & role management
β”‚   β”‚   β”œβ”€β”€ board.js                       # Kanban board drag-and-drop & filters
β”‚   β”‚   β”œβ”€β”€ tasks.js                       # Task modals, recurrence & file attachments
β”‚   β”‚   β”œβ”€β”€ calendar.js                    # Monthly task deadline calendar view
β”‚   β”‚   β”œβ”€β”€ comments.js                    # Task discussion threads & dialog confirmations
β”‚   β”‚   β”œβ”€β”€ team.js                        # Workspace member directory & search
β”‚   β”‚   β”œβ”€β”€ notifications.js               # Notification center & read state
β”‚   β”‚   β”œβ”€β”€ profile.js                     # Profile settings, stats & password update
β”‚   β”‚   β”œβ”€β”€ search.js                      # Global search overlay (Ctrl + K)
β”‚   β”‚   └── app.js                         # Application bootstrapper & SPA router
β”‚   └── assets/
β”‚       └── favicon.svg                    # Brand vector icon
β”œβ”€β”€ README.md                              # Complete platform documentation
└── package.json                           # Workspace root scripts

πŸš€ 5. Installation & Setup Guide

Step 1: Prerequisites

Ensure you have installed:

  • Node.js (v18.0.0 or higher)
  • npm (v9.0.0 or higher)
  • MongoDB running locally (mongodb://127.0.0.1:27017/projectflow) or a MongoDB Atlas cloud URI.

Step 2: Navigate to Project Directory

cd "c:\Users\acer\OneDrive\Desktop\Project Management Tool\ProjectFlow"

Step 3: Install Dependencies

cd backend
npm install

Step 4: Environment Configuration

Verify that backend/.env exists with the following configuration:

PORT=5000
MONGODB_URI=mongodb://127.0.0.1:27017/projectflow
JWT_SECRET=projectflow_super_secret_jwt_key_2026_dev_alpha
JWT_EXPIRE=7d
CLIENT_URL=http://localhost:5000
NODE_ENV=development

Step 5: Seed Demo Database (Optional)

If you want to re-seed realistic demo projects, team members, tasks, comments, and activities:

cd backend
npm run seed

πŸƒβ€β™‚οΈ 6. How to Run the Application

Start the Express backend and WebSocket server:

cd backend
npm start

The server will initialize:

=======================================================
 ProjectFlow Server running in development mode
 Local URL: http://localhost:5000
 WebSocket Real-Time Server active on port 5000
 Connected to MongoDB: projectflow
=======================================================

Open your browser and navigate to:
πŸ‘‰ http://localhost:5000

Pre-Configured Evaluation Demo Accounts:

Use the one-click demo buttons on the login screen or enter:

  • Mukesh (Project Lead / Admin): mukesh@projectflow.dev / password123
  • Sarah Chen (Frontend Engineer): sarah@projectflow.dev / password123
  • Marcus Miller (Backend Engineer): marcus@projectflow.dev / password123
  • Priya Sharma (UI/UX Designer): priya@projectflow.dev / password123
  • David Kim (Full Stack Engineer): david@projectflow.dev / password123

πŸ§ͺ 7. Automated Testing & Verification

ProjectFlow includes an extensive automated testing harness featuring 7 comprehensive test suites covering 214 automated test assertions across all backend APIs, database operations, security middleware, and frontend assets:

To run the Master QA Test Runner:

cd backend
node final-master-qa-runner.js

Test Suites Included:

  1. saas-platform-verification.js (34 tests): Verifies all 12 SaaS platform features including Drag & Drop, Team Invites, Dynamic Roles, Analytics, Calendar, Attachments, Global Search, Recurring Tasks, CSV Export, and Theme.
  2. comprehensive-audit-v2.js (45 tests): Verifies all REST endpoints, query filters, authorization, and error handling.
  3. profile-and-features-audit.js (24 tests): Verifies Profile & Settings page, bio, job title, password changes, and navigation views.
  4. test-suite.js (22 tests): Verifies core CodeAlpha Task 3 features (Auth, Projects, Tasks, Comments, Notifications).
  5. deep-verification.js (40 tests): Verifies edge-cases, data sanitization, cascade deletions, and boundary permissions.
  6. advanced-verification.js (19 tests): Verifies complex workflows, Kanban state transitions, and real-time socket events.
  7. qa-master-audit.js (30 tests): Verifies security headers, token expiration, injection safety, and performance response times.

Verification Result: 214 Passed / 0 Failed (100% Pass Rate).


πŸ“‘ 8. REST API Reference

Authentication & Profile

  • POST /api/auth/register β€” Register a new workspace user
  • POST /api/auth/login β€” Authenticate user & return JWT token
  • GET /api/auth/me β€” Retrieve current authenticated user (Protected)
  • PUT /api/auth/profile β€” Update user profile details (Protected)
  • PUT /api/auth/password β€” Change password (Protected)
  • POST /api/auth/forgot-password β€” Generate cryptographic password reset token
  • POST /api/auth/reset-password β€” Reset password using token
  • GET /api/users/:id β€” Get public user profile & activity metrics (Protected)
  • GET /api/users β€” List workspace team members (Protected)

Projects & Team Collaboration

  • POST /api/projects β€” Create group project (Protected)
  • GET /api/projects β€” List projects for current user (Protected)
  • GET /api/projects/:id β€” Get project details & team roster (Protected)
  • PUT /api/projects/:id β€” Update project metadata (Owner / Admin)
  • DELETE /api/projects/:id β€” Delete project & cascade data (Owner Only)
  • POST /api/projects/:id/members β€” Add member to project (Owner / Admin)
  • DELETE /api/projects/:id/members/:userId β€” Remove member from project (Owner / Admin)
  • PATCH /api/projects/:id/members/:userId/role β€” Update member role (Owner / Admin)
  • POST /api/projects/:id/invitations β€” Send email invitation to project (Owner / Admin)
  • GET /api/projects/:id/export-csv β€” Export project tasks report as CSV (Protected)
  • GET /api/projects/:id/activities β€” Retrieve project activity audit trail (Protected)

Tasks & Kanban

  • POST /api/projects/:projectId/tasks β€” Create new task in project (Protected)
  • GET /api/projects/:projectId/tasks β€” Get tasks for specific project (Protected)
  • GET /api/tasks/:id β€” Get task details with attachments & comments (Protected)
  • PUT /api/tasks/:id β€” Update task details (Protected)
  • PATCH /api/tasks/:id/status β€” Move task status column (Kanban Drag & Drop) (Protected)
  • DELETE /api/tasks/:id β€” Permanently delete task (Protected)
  • GET /api/tasks/my-tasks β€” Get all tasks assigned to logged-in user (Protected)
  • POST /api/tasks/:id/attachments β€” Upload file attachments to task (Protected)
  • DELETE /api/tasks/:id/attachments/:attachmentId β€” Delete file attachment (Protected)
  • GET /api/tasks/:id/activities β€” Get task-level activity history (Protected)

Comments & Discussions

  • POST /api/tasks/:taskId/comments β€” Add comment to task (Protected)
  • GET /api/tasks/:taskId/comments β€” Get comment thread for task (Protected)
  • PUT /api/comments/:id β€” Edit own comment (Author Only)
  • DELETE /api/comments/:id β€” Delete comment (Author / Project Admin)

Global Search, Notifications & Dashboard

  • GET /api/search?q=:query β€” Multi-model global search across projects, tasks, and users (Protected)
  • GET /api/notifications β€” List in-app notifications (Protected)
  • PATCH /api/notifications/:id/read β€” Mark notification as read (Protected)
  • PATCH /api/notifications/read-all β€” Mark all notifications as read (Protected)
  • GET /api/dashboard/stats β€” Dashboard analytics, 7-day velocity & counts (Protected)

πŸ›‘οΈ 9. Security & Production Standards

  1. Password Hashing: Passwords are never stored in plain text. Salt rounds (10) with bcryptjs are enforced.
  2. Token Security: JWT tokens are signed with expiration periods (7d) and verified using protected middleware.
  3. Data Sanitization: Mongoose schemas use select: false on sensitive password fields.
  4. File Upload Restrictions: Multer middleware limits attachment size to 5MB and enforces strict MIME-type whitelisting.
  5. Role-Based Authorization: Endpoints verify user roles before granting administrative actions.
  6. No Exposed Secrets: All sensitive secrets are kept strictly in .env and omitted from version control.

πŸ‘¨β€πŸ’» 10. Internship Submission Information

  • Internship: CodeAlpha Full Stack Web Development Internship
  • Task: Task 3 β€” Project Management Tool
  • Project Name: ProjectFlow
  • Suggested Repository: CodeAlpha_ProjectManagementTool
  • Application Type: Full Stack Collaborative SaaS Web Application

About

A full-featured collaborative SaaS Project Management & Kanban Platform with real-time Socket.IO, RBAC, analytics, and deadline calendar. CodeAlpha Internship Task 3.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages