A full-stack web application for managing student internship credits with automated approval workflows.
- Register and login
- Add internship applications
- Track internship status (Pending/Approved/Rejected)
- View total credits earned
- Manage profile
- Review and approve/reject internship applications
- View all student records
- Manually adjust student credits with audit trail
- Generate reports (students with low credits, top organizations)
- Export data to CSV/PDF
- Dashboard with statistics
- Node.js & Express.js
- MongoDB & Mongoose
- JWT Authentication
- Nodemailer (Email notifications)
- Express Validator
- CSV & PDF export
- React.js
- React Router
- Tailwind CSS
- Axios
- React Hot Toast
- Lucide React Icons
- Node.js (v14 or higher)
- MongoDB (local or cloud instance)
- npm or yarn
cd InternCredcd Backend
# Install dependencies
npm install
# Create .env file
cp .env.example .env
# Edit .env and add your configuration:
# - MongoDB connection string
# - JWT secret
# - SMTP credentials for email
# - Other environment variables
# Start the backend server
npm run devBackend will run on http://localhost:5000
cd Frontend
# Install dependencies
npm install
# Start the development server
npm run devFrontend will run on http://localhost:5173
You need to create at least one department and one admin user in MongoDB:
// Department
{
deptID: "DEPT001",
name: "Computer Science"
}
// Contact for Admin
{
number: "1234567890",
email: "admin@university.edu"
}
// Admin (password will be hashed automatically)
{
adminID: "ADMIN001",
name: "Admin Name",
password: "admin123", // Will be hashed
department: ObjectId("department_id"),
contact: ObjectId("contact_id")
}For email notifications (rejection/approval), configure SMTP in .env:
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
SMTP_USER=your_email@gmail.com
SMTP_PASS=your_app_passwordNote: For Gmail, you need to use an App Password, not your regular password.
MONGO_URI=mongodb://localhost:27017/interncred
PORT=5000
JWT_SECRET=your_jwt_secret_key_here
MAX_CREDITS=20
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
SMTP_USER=your_email@gmail.com
SMTP_PASS=your_email_password
FRONTEND_URL=http://localhost:5173VITE_API_URL=http://localhost:5000/api- Register with roll number, registration number, and other details
- Login with roll number or registration number
- Add internship (can create new organization or select existing)
- Wait for admin approval
- Check dashboard for credits and status updates
- Login with admin ID
- View pending internship requests
- Approve or reject with reason
- View all students and their records
- Manually adjust credits if needed
- Generate and export reports
- Credits are awarded based on internship duration
- Formula:
(months / 6) ร maxCredits - Maximum credits: 20 (configurable)
- Only approved internships count toward total credits
- 6 months of internship = full credits
- JWT-based authentication
- Password hashing with bcrypt
- Role-based access control (Student/Admin)
- Input validation
- XSS protection
POST /api/auth/student/register- Register studentPOST /api/auth/student/login- Student loginPOST /api/auth/admin/login- Admin loginGET /api/auth/profile- Get user profile
POST /api/internships- Create internshipGET /api/internships/my-internships- Get student's internshipsGET /api/internships/pending- Get pending internships (Admin)PUT /api/internships/:id- Update internship
POST /api/admin/internships/:id/approve- Approve internshipPOST /api/admin/internships/:id/reject- Reject internshipGET /api/admin/students- Get all studentsPOST /api/admin/students/:id/adjust-credits- Adjust credits
GET /api/reports/students-lacking?min=3- Students below thresholdGET /api/reports/top-organizations- Top organizationsGET /api/reports/dashboard-stats- Dashboard statistics
GET /api/export/students.csv- Export students as CSVGET /api/export/internships.csv- Export internships as CSVGET /api/export/student/:id.pdf- Export student report as PDF
- Cards, Badges, Tables
- Forms with validation
- Modal dialogs
- Loading states
- Toast notifications
- Responsive design
- Ensure MongoDB is running
- Check connection string in .env
- Verify FRONTEND_URL in backend .env
- Check API_URL in frontend .env
- Verify SMTP credentials
- For Gmail, use App Password
- Check firewall/antivirus settings
MIT
Om Gholap
Note: This is a development setup. For production, use environment-specific configurations, enable HTTPS, and implement additional security measures.