A full-stack web application for United International University (UIU) canteen food ordering and delivery inside the UIU campus only. It helps students, staff, and faculty order canteen food when they do not want to walk to the canteen, while UIU students can deliver as part-time student delivery partners.
- Service area: UIU campus only
- Food source: UIU canteen shops only
- Users: UIU students, staff, and faculty
- Delivery partners: UIU students working part-time
- Not supported: city-wide or off-campus home delivery
- Student/Staff/Faculty User - Browse canteen shops, place orders, track delivery, confirm OTP, and rate service
- Canteen Owner - Create/manage canteen shop, maintain menu items, and prepare orders
- Student Delivery Partner - UIU student who accepts assignments, picks up orders, and delivers inside campus
- π Authentication - Sign up, sign in, password reset with OTP verification
- πͺ Canteen Shop Management - Create, edit, and manage canteen shops with images
- π Menu Management - Add, edit, and categorize food items
- π¦ Order Lifecycle - Place order, prepare, assign, pickup, on-the-way, delivered
- π§ Campus Delivery Flow - Delivery location is limited to UIU campus areas
- ποΈ Auto Assignment - Assign online student delivery partners when order is ready
- π’ OTP Handover - Delivery is completed after OTP verification
- β Delivery Rating - Users can rate student delivery partners after successful delivery
- πΌοΈ Image Upload - Cloudinary integration for image storage
- π³ Payment Integration - Secure payment flow for order checkout
- π₯ Firebase Integration - Additional authentication support
- Snacks
- Desserts
- Burgers
- Sandwiches
- Drinks
- Fast Food
- Chinese
- Others
- Runtime: Node.js
- Framework: Express.js
- Database: MongoDB with Mongoose ODM
- Authentication: JWT (JSON Web Tokens)
- Password Hashing: bcryptjs
- File Upload: Multer + Cloudinary
- Email Service: Nodemailer
- Framework: React 19
- Build Tool: Vite
- State Management: Redux Toolkit
- Routing: React Router DOM
- Styling: Tailwind CSS
- HTTP Client: Axios
- Icons: React Icons
- Authentication: Firebase
UniCan/
βββ Backend/
β βββ config/ # Database configuration
β βββ controllers/ # Route controllers
β βββ middlewares/ # Auth & file upload middlewares
β βββ models/ # Mongoose schemas
β βββ routes/ # API routes
β βββ utils/ # Cloudinary, mail, token utilities
β βββ index.js # Entry point
β
βββ Frontend/
β βββ public/ # Static assets
β βββ src/
β βββ assets/ # Images and static files
β βββ components/ # Reusable components
β βββ hooks/ # Custom React hooks
β βββ pages/ # Page components
β βββ redux/ # Redux store and slices
β βββ App.jsx # Main app component
β βββ main.jsx # Entry point
β
βββ package.json
- Node.js (v18 or higher)
- MongoDB
- Cloudinary account
- Firebase project (for additional auth)
Create a .env file in the Backend folder with the following variables:
PORT=8000
MONGODB_URI=your_mongodb_connection_string
JWT_SECRET=your_jwt_secret_key
# Cloudinary
CLOUDINARY_CLOUD_NAME=your_cloud_name
CLOUDINARY_API_KEY=your_api_key
CLOUDINARY_API_SECRET=your_api_secret
# Email (Nodemailer)
EMAIL_USER=your_email@gmail.com
EMAIL_PASS=your_email_app_password# Navigate to backend directory
cd Backend
# Install dependencies
npm install
# Start development server
npm run devThe backend server will run on http://localhost:8000
# Navigate to frontend directory
cd Frontend
# Install dependencies
npm install
# Start development server
npm run devThe frontend will run on http://localhost:5173
POST /signup- Register a new userPOST /signin- Login userPOST /forgot-password- Request password resetPOST /verify-otp- Verify OTP for password resetPOST /reset-password- Reset password
GET /current- Get current user profilePOST /toggle-online- Toggle student delivery partner online/offline statusPOST /set-online- Set student delivery partner online status explicitlyGET /delivery-stats- Get student delivery partner stats and performance
POST /create- Create a new shopGET /my-shop- Get owner's shopPUT /update/:id- Update shop detailsDELETE /:id- Delete a shop
POST /add- Add a new itemGET /shop/:shopId- Get items by shopPUT /update/:id- Update an itemDELETE /:id- Delete an item
POST /place-order- Create a new orderGET /user-orders- Get user's order historyGET /owner-orders- Get owner's order listPUT /update-status/:orderId- Update shop-side order statusPUT /cancel-order/:orderId- Cancel order by userGET /available-orders- Get available orders for student delivery partnerGET /delivery-boy-orders- Get assigned delivery orders for student delivery partnerPUT /accept-order/:orderId- Accept order (legacy compatibility route)PUT /confirm-accept/:orderId- Confirm auto-assigned orderPUT /reject-order/:orderId- Reject orderPUT /update-delivery-status/:orderId- Update delivery statusPOST /generate-otp/:orderId- Generate delivery OTPPOST /verify-otp/:orderId- Verify delivery OTP and complete orderGET /today-deliveries- Get today's completed deliveriesGET /shop-earnings- Get shop earnings summaryGET /monthly-shop-earnings- Get monthly shop earningsGET /delivery-boy-monthly-earnings- Get monthly earnings for student delivery partner
POST /init- Initialize payment for an orderPOST /ipn- Payment IPN callbackGET/POST /success- Payment success callbackGET/POST /fail- Payment failure callbackGET/POST /cancel- Payment cancel callback
POST /rate/:orderId- Submit rating for student delivery partnerGET /order/:orderId- Get rating for a specific orderGET /can-rate/:orderId- Check if the user can rate this orderGET /delivery-boy/:deliveryBoyId- Get ratings for a student delivery partner
- UIU user logs in and selects food from canteen menu
- User chooses a delivery spot inside UIU campus
- User confirms payment and order is created
- Canteen prepares food and marks order ready
- System auto-assigns an online student delivery partner
- Partner picks up food and delivers inside UIU only
- User confirms delivery with OTP
- User rates delivery service
- Start MongoDB service
- Start the backend server:
cd Backend && npm run dev - Start the frontend:
cd Frontend && npm run dev - Open
http://localhost:5173in your browser
npm run dev- Start development server with nodemon
npm run dev- Start Vite development servernpm run build- Build for productionnpm run preview- Preview production buildnpm run lint- Run ESLint
Mutasim Fuad Rafi
ISC License
Below are selected screenshots from the UniCan frontend (stored under Frontend/src/assets/) with short annotations explaining each view.
-
Landing Page:
- Description: The public-facing hero section showcasing UniCan's core value proposition, quick search, and call-to-action buttons.
-
Sign Up / Registration:
- Description: User registration form allowing role selection (user, owner, delivery partner) and social sign-in options.
-
User / Student View (Shops & Items):
- Description: Browse shops, categories, and individual food items with add-to-cart controls and ratings.
-
Canteen Owner Dashboard:
- Description: Owner view with shop banner, earnings summary, and a list of menu items for quick management.
-
Student Delivery Partner Dashboard:
- Description: Delivery partner interface showing online/offline toggle, performance stats, and active delivery information.




