Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Β 
Β 

Latest commit

Β 

History

117 Commits

Folders and files

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

Repository files navigation

R-Choice Portal

πŸŽ“ R-Choice

Internship & Placement Management Platform
Rathinam College of Arts and Science

Next.js React TypeScript Drizzle PostgreSQL

Status Build License


🌟 Overview

R-Choice is a full-stack internship and placement management platform that unifies students, faculty approvers, administrators, and company partners into a single, role-aware system. It replaces fragmented spreadsheets, email chains, and manual approval workflows with a streamlined digital pipeline.

From profile building to placement certification β€” seamlessly managed.

✨ Key Highlights

  • πŸ—οΈ 8-Role Architecture β€” Student, Tutor, Coordinator, HOD, Dean, PO, Principal, Company
  • πŸ”„ 6-Tier Approval Pipeline β€” Automated routing through institutional hierarchy
  • πŸ“Š Real-Time Dashboards β€” Role-specific analytics with animated visualizations
  • 🏒 Company Portal β€” Self-service registration, job posting, and applicant review
  • πŸ” Enterprise Security β€” Rate limiting, CSRF protection, audit logging, IDOR prevention
  • πŸ“± Responsive Design β€” Glassmorphism UI with dark mode support

🎯 The Problem

Internship and placement operations at educational institutions typically suffer from:

Pain Point Traditional Approach R-Choice Solution
Approval Routing Manual email chains Automated 6-tier pipeline
Application Tracking Spreadsheets Real-time status dashboard
Company Management Ad-hoc coordination Self-service portal
Compliance Paper trails Digital audit logs
Visibility Disconnected data Unified analytics

πŸ›οΈ Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                        FRONTEND                              β”‚
β”‚   Next.js 16 App Router  β€’  React 19  β€’  CSS Modules        β”‚
β”‚   Framer Motion  β€’  Lucide Icons  β€’  Recharts                β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚                     SERVER ACTIONS                            β”‚
β”‚   Auth  β€’  Jobs  β€’  Approvals  β€’  Profile  β€’  Notifications  β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚                      DATA LAYER                              β”‚
β”‚   Drizzle ORM  β€’  Neon PostgreSQL  β€’  NextAuth v5            β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚                    INTEGRATIONS                              β”‚
β”‚   Cloudinary (Media)  β€’  Nodemailer (SMTP)  β€’  Playwright    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸ‘₯ Role Matrix

Role Access Level Dashboard Key Capabilities
πŸŽ“ Student Self-service Student Profile builder, job browser, application tracker, OD requests
πŸ“– Tutor Tier 1 Approver Staff Review & approve student internship requests
πŸ“‹ Placement Coordinator Tier 2 Approver Staff Coordinate placement activities, manage approvals
πŸ›οΈ HOD Tier 3 Approver Staff Department-level oversight and approvals
⭐ Dean Admin Admin Institutional approvals, analytics, user management
πŸ“Š Placement Officer Admin Admin Job approvals, company reviews, placement analytics
πŸ‘‘ Principal Admin Admin Final authority, full system visibility
πŸ’Ό Company External Company Registration, job posting, applicant management

πŸ”„ Approval Pipeline

Student submits OD Request
        β”‚
        β–Ό
   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”    β”Œβ”€β”€β”€β”€β”€β”
   β”‚  Tutor  │───▢│  Coordinator │───▢│ HOD β”‚
   β”‚ Tier 1  β”‚    β”‚    Tier 2     β”‚    β”‚T. 3 β”‚
   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    β””β”€β”€β”¬β”€β”€β”˜
                                         β”‚
        β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
        β–Ό
   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
   β”‚  Dean   │───▢│Placement Officer│───▢│ Principal β”‚
   β”‚ Tier 4  β”‚    β”‚     Tier 5      β”‚    β”‚  Tier 6   β”‚
   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    β””β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”˜
                                               β”‚
                                               β–Ό
                                         βœ… APPROVED

Each tier auto-routes to the next authority. Rejections include feedback and return to the student.


πŸ› οΈ Tech Stack

Layer Technology Purpose
Framework Next.js 16 (App Router) Full-stack React framework
UI Library React 19 Component architecture
Language TypeScript 5 Type-safe development
Styling CSS Modules Scoped, maintainable styles
Animation Framer Motion Micro-interactions & transitions
Icons Lucide React Consistent iconography
Charts Recharts Data visualizations
Auth NextAuth v5 (Beta) Credential-based authentication
Database PostgreSQL (Neon) Serverless relational database
ORM Drizzle ORM Type-safe database queries
File Storage Cloudinary Resume & media uploads
Email Nodemailer SMTP-based notifications
PDF jsPDF + html2canvas Certificate & report generation
Testing Playwright End-to-end browser tests

πŸ“ Project Structure

internflow/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ (dashboard)/          # Role-based dashboard pages
β”‚   β”‚   β”‚   β”œβ”€β”€ dashboard/        # Student, Staff, Admin, Company dashboards
β”‚   β”‚   β”‚   β”œβ”€β”€ jobs/             # Job board, posting, management
β”‚   β”‚   β”‚   β”œβ”€β”€ applications/     # OD request forms & tracking
β”‚   β”‚   β”‚   β”œβ”€β”€ approvals/        # Staff approval queues
β”‚   β”‚   β”‚   β”œβ”€β”€ companies/        # Company directory & reviews
β”‚   β”‚   β”‚   β”œβ”€β”€ students/         # Student directory
β”‚   β”‚   β”‚   β”œβ”€β”€ profile/          # Profile builder & vCard
β”‚   β”‚   β”‚   β”œβ”€β”€ reports/          # Work report management
β”‚   β”‚   β”‚   β”œβ”€β”€ settings/         # User & system settings
β”‚   β”‚   β”‚   └── users/            # User management (admin)
β”‚   β”‚   β”œβ”€β”€ actions/              # Server actions
β”‚   β”‚   β”‚   β”œβ”€β”€ auth.ts           # Registration, login
β”‚   β”‚   β”‚   β”œβ”€β”€ jobs.ts           # CRUD, approvals
β”‚   β”‚   β”‚   β”œβ”€β”€ approvals.ts      # OD pipeline
β”‚   β”‚   β”‚   β”œβ”€β”€ profile.ts        # Profile management
β”‚   β”‚   β”‚   β”œβ”€β”€ admin.ts          # User & system admin
β”‚   β”‚   β”‚   └── notifications.ts  # Notification system
β”‚   β”‚   β”œβ”€β”€ api/                  # API routes (uploads)
β”‚   β”‚   └── v/[id]/               # Public vCard pages
β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”œβ”€β”€ dashboard/            # Dashboard-specific components
β”‚   β”‚   β”‚   β”œβ”€β”€ admin/            # Admin widgets (audit log, charts)
β”‚   β”‚   β”‚   β”œβ”€β”€ jobs/             # Job cards, swipe deck
β”‚   β”‚   β”‚   └── DashboardShell.tsx # Main layout shell
β”‚   β”‚   └── ui/                   # Reusable UI primitives
β”‚   └── lib/
β”‚       β”œβ”€β”€ auth.ts               # NextAuth configuration
β”‚       β”œβ”€β”€ db/
β”‚       β”‚   β”œβ”€β”€ schema.ts         # Drizzle schema definitions
β”‚       β”‚   β”œβ”€β”€ queries/          # Reusable query functions
β”‚       β”‚   β”œβ”€β”€ seed.ts           # Dev seed data
β”‚       β”‚   └── seed-students.ts  # Batch student seeding
β”‚       β”œβ”€β”€ cloudinary.ts         # Media upload config
β”‚       β”œβ”€β”€ mail.ts               # SMTP helpers
β”‚       └── validation.ts         # Input sanitization
β”œβ”€β”€ e2e/                          # Playwright E2E tests
β”œβ”€β”€ drizzle/                      # Database migrations
β”œβ”€β”€ public/                       # Static assets
└── docs/                         # Documentation & screenshots

πŸš€ Quick Start

Prerequisites

  • Node.js 18+
  • PostgreSQL database (we recommend Neon)

1. Clone & Install

git clone https://github.com/iamharishrohith/R-Choice.git
cd R-Choice/internflow
npm install

2. Environment Setup

Create .env.local in the project root:

# Database
DATABASE_URL=postgresql://user:pass@host/dbname

# Auth
AUTH_SECRET=your-random-secret-key
AUTH_TRUST_HOST=true

# Cloudinary (for media uploads)
CLOUDINARY_CLOUD_NAME=your-cloud
CLOUDINARY_API_KEY=your-key
CLOUDINARY_API_SECRET=your-secret

# SMTP (for email notifications)
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
SMTP_USER=your-email
SMTP_PASS=your-app-password
EMAIL_FROM=noreply@rathinam.edu.in

3. Database Setup

# Push schema to database
npx drizzle-kit push

# Seed test accounts
npx tsx src/lib/db/seed.ts

# Seed student batch (optional)
npx tsx src/lib/db/seed-students.ts

4. Start Development Server

npm run dev

Open http://localhost:3000 β€” you're ready to go! πŸŽ‰


πŸ”‘ Test Accounts

All seeded accounts use the shared password:

R-Choice@2025
Role Email Dashboard
πŸŽ“ Student student@rathinam.edu.in /dashboard/student
πŸ“– Tutor tutor@rathinam.edu.in /dashboard/staff
πŸ“‹ Coordinator pc@rathinam.edu.in /dashboard/staff
πŸ›οΈ HOD hod@rathinam.edu.in /dashboard/staff
⭐ Dean dean@rathinam.edu.in /dashboard/admin
πŸ“Š PO po@rathinam.edu.in /dashboard/admin
πŸ‘‘ Principal principal@rathinam.edu.in /dashboard/admin
πŸ’Ό Company hr@techcorp.com /dashboard/company

βœ… Validation

# Type checking
npx tsc --noEmit

# Linting
npm run lint

# Production build
npm run build

# E2E Tests
npx playwright test

Test Suites

npx playwright test e2e/auth.spec.ts           # Authentication flows
npx playwright test e2e/applications.spec.ts    # Student application pipeline
npx playwright test e2e/full-pipeline.spec.ts   # End-to-end approval chain

πŸ” Security

Feature Implementation
Authentication NextAuth v5 with credential provider + role validation
Authorization Server-side role checks on every action
Input Sanitization Custom validation library with XSS prevention
CSRF Protection Built-in NextAuth CSRF tokens
Rate Limiting Login attempt tracking with lockout
Audit Logging All admin actions logged with IP, timestamp, user
Security Headers CSP, HSTS, X-Frame-Options via next.config.ts
IDOR Prevention Ownership verification on all mutations

πŸ—ΊοΈ Roadmap

  • Migrate middleware to proxy convention (Next.js 16)
  • Replace remaining any types with strict interfaces
  • Add CI/CD pipeline with GitHub Actions
  • Implement real-time notifications via WebSocket
  • Mobile app build with Capacitor
  • Advanced analytics with cohort tracking
  • PDF certificate generation for completed internships

🀝 Contributing

  1. Validate changes with npx tsc --noEmit and npm run build
  2. Run relevant Playwright tests for affected workflows
  3. Follow existing CSS Module and Server Action patterns
  4. Use Lucide icons β€” no emoji in UI components

πŸ“œ License

This project is proprietary software built for Rathinam College of Arts and Science.
All rights reserved.


Built with ❀️ for Rathinam College
Internship & Placement Cell β€’ Powered by Symbio

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages