A full-stack web application that enables citizens to register complaints and administrators to manage them. Includes user authentication, image/location-based complaint registration, and an admin dashboard for tracking status.
- Sign up / Login / Logout / Password reset
- Register complaints with image & location
- Upvote complaints posted by others
- Secure login with password reset
- View and manage all complaints
- Update complaint status (Pending ➝ In Progress ➝ Resolved)
- Vite + React
- Tailwind CSS + DaisyUI
- React Router, Axios, Toast Notifications
- GeoLocation (for maps)
- Node.js + Express.js
- MongoDB + Mongoose
- Cloudinary (image upload)
- JWT Auth
- Nodemailer (email reset)
Smart-Complaint-Management-System/
│
├── client/ # React client
├── server/ # Express server
├── .gitignore
└── README.md
Before running the project, ensure:
- Node.js and npm installed
- MongoDB is running locally or on a cloud service
- Cloudinary account
- Gmail App Password enabled for Nodemailer
# Clone the repository
git clone https://github.com/your-username/smart-complaint-management-system.git
cd smart-complaint-management-system
# Frontend setup
cd client
npm install
# Backend setup
cd ../server
npm install# Run backend
cd client
npm run dev
# Run frontend (in new terminal)
cd server
npm run devThe app will be available at:
➡️ Frontend: http://localhost:5173
➡️ Backend: http://localhost:5000
Before running, create .env files in both client/ and server/ folders:
PORT=5000
MONGODB_URI=your_mongodb_uri
CLOUDINARY_CLOUD_NAME=your_cloud_name
CLOUDINARY_API_KEY=your_api_key
CLOUDINARY_API_SECRET=your_api_secret
JWT_SECRET=your_jwt_secret
EMAIL_USER=your_email@gmail.com
EMAIL_PASS=your_app_password
⚠️ Note: Do not commit real secrets. Create a.env.examplewith the variable names for others to configure.
"scripts": {
"dev": "vite",
"build": "vite build",
"preview": "vite preview",
"lint": "eslint ."
}"scripts": {
"dev": "nodemon index.js"
}Recommended .gitignore for this project:
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
pnpm-debug.log*
# Dependencies
node_modules/
client/node_modules/
server/node_modules/
# Build
dist/
build/
client/dist/
server/dist/
# Env Files
*.env
.env.*.local
# Vite
.vite/
# Editor/OS
.vscode/*
!.vscode/extensions.json
.idea/
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
Thumbs.db
Deployment guides for Render, Vercel, or Railway coming soon. Make sure to set all environment variables correctly on the deployment platform.
Contributions are welcome!
Feel free to fork, improve and send a PR. For major changes, please open an issue first.
This project is licensed under the MIT License.
