A full-stack car dealership application built with React, Node.js, Express, and MongoDB.
- Modern UI/UX: Beautiful, responsive design with Tailwind CSS and Framer Motion animations
- Car Catalog: Browse cars with advanced search and filtering
- User Authentication: Login, register, and profile management
- Order Management: Place orders and track order status
- Admin Dashboard: Complete admin panel for managing cars and orders
- Real-time Notifications: Notification system for users and admins
- Responsive Design: Works on desktop, tablet, and mobile devices
- RESTful API: Complete API with authentication and authorization
- User Management: User registration, login, and profile management
- Car Management: CRUD operations for car inventory
- Order System: Order creation, status tracking, and management
- Notification System: Real-time notifications for users
- File Upload: Image upload for cars with Multer
- Security: JWT authentication and password hashing
- React 19.1.1
- TypeScript
- Tailwind CSS
- Framer Motion
- React Router DOM
- Axios
- React Hot Toast
- React Icons
- Date-fns
- Node.js
- Express.js
- MongoDB with Mongoose
- JWT Authentication
- Multer for file uploads
- Bcrypt for password hashing
- CORS enabled
- Node.js (v16 or higher)
- MongoDB (local or cloud)
- Git
- Navigate to the backend directory:
cd Motary-backend- Install dependencies:
npm install- Create a
.envfile in the backend directory:
MONGO_URI=mongodb://localhost:27017/motary
JWT_SECRET=your-super-secret-jwt-key-here
PORT=5000
NODE_ENV=development- Start the backend server:
npm run devThe backend will run on http://localhost:5000
- Navigate to the frontend directory:
cd Motary- Install dependencies:
npm install- Start the development server:
npm run devThe frontend will run on http://localhost:5173
- Browse Cars: Visit the Cars page to see all available vehicles
- Search & Filter: Use the search bar and filters to find specific cars
- View Details: Click "See More" to view detailed car information
- Place Orders: Click "Buy Now" to place an order for a car
- Track Orders: Visit your Profile to see order history and status
- Manage Account: Update profile information and manage account settings
- Login: Use admin credentials to access the dashboard
- Manage Cars: Add, edit, or delete cars from the inventory
- View Orders: Monitor all customer orders and their status
- Update Order Status: Change order status and add notes
- View Analytics: See dashboard statistics and revenue
POST /api/auth/register- User registrationPOST /api/auth/login- User loginPOST /api/auth/forgot-password- Password reset requestPOST /api/auth/reset-password/:token- Password reset
GET /api/cars- Get all carsGET /api/cars/:id- Get car by IDGET /api/cars/search- Search cars with filtersPOST /api/cars- Create car (Admin only)PUT /api/cars/:id- Update car (Admin only)DELETE /api/cars/:id- Delete car (Admin only)
POST /api/orders- Create orderGET /api/orders- Get all orders (Admin only)GET /api/orders/my-orders- Get user ordersGET /api/orders/:id- Get order by IDPUT /api/orders/:id/status- Update order status (Admin only)DELETE /api/orders/:id- Delete order (Admin only)
GET /api/notifications- Get user notificationsPUT /api/notifications/:id/read- Mark notification as readPUT /api/notifications/read-all- Mark all notifications as readGET /api/notifications/unread-count- Get unread countPOST /api/notifications- Create notification (Admin only)DELETE /api/notifications/:id- Delete notification
- firstName, lastName, phone, email, password
- role (user/admin)
- resetPasswordToken, resetPasswordExpires
- name, description, price
- gearbox, doors, fullOptions, inStock
- condition, type, fuel, year
- images, createdBy
- car (reference), user (reference)
- buyerInfo (firstName, lastName, phone, email)
- totalPrice, status, notes
- timestamps
- user (reference), title, message
- type, read, data, actionUrl
- timestamps
✅ Complete Authentication System
- User registration and login
- Password reset functionality
- JWT token-based authentication
- Role-based access control
✅ Advanced Car Management
- Car CRUD operations
- Image upload and management
- Search and filtering system
- Category-based browsing
✅ Order Management System
- Order creation and tracking
- Status management
- Order history for users
- Admin order management
✅ Notification System
- Real-time notifications
- Notification center UI
- Unread count tracking
- Admin notification creation
✅ Admin Dashboard
- Complete admin panel
- Statistics and analytics
- Car and order management
- User-friendly interface
✅ Responsive Design
- Mobile-first approach
- Beautiful animations
- Consistent UI/UX
- Cross-browser compatibility
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
This project is licensed under the MIT License.
For support or questions, please contact the development team.