Skip to content

Sabari-Vasan-SM/Bike-Buddy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

89 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸš΄β€β™‚οΈ Bike Buddy !

A comprehensive bike service management platform that connects customers with service providers, enabling easy booking, tracking, and management of bike services.

🎯 Overview

Bike Buddy is a full-stack web application designed to streamline bike service operations. It provides separate dashboards for customers and service owners, with real-time status updates and email notifications.

Key Highlights

  • Role-based Access: Separate interfaces for customers and service owners
  • Real-time Updates: Live status tracking for service bookings
  • Email Notifications: Automated email alerts for status changes
  • Responsive Design: Mobile-friendly interface with modern UI
  • Secure Authentication: Password hashing and user session management

✨ Features

For Customers

  • πŸ” User Authentication: Secure login and registration
  • πŸ“… Service Booking: Easy booking of bike services with date selection
  • πŸ“Š Dashboard: Comprehensive overview of bookings and statistics
  • πŸ“ˆ Service History: Complete history of past services
  • πŸ”” Status Tracking: Real-time tracking of service status
  • πŸ“§ Email Notifications: Automatic updates on service progress
  • πŸ’° Cost Tracking: Monitor total spending on services

For Service Owners

  • πŸ“‹ Booking Management: View and manage all customer bookings
  • πŸ”„ Status Updates: Update booking statuses (Pending, In Progress, Ready for Delivery, Completed)
  • πŸ‘₯ Customer Management: Access to customer details and service history
  • πŸ“Š Analytics Dashboard: Overview of business metrics and performance
  • πŸ› οΈ Service Management: Add, edit, and manage available services
  • πŸ“§ Automated Communications: Automatic email notifications to customers

General Features

  • 🌐 Cross-platform: Works on desktop, tablet, and mobile devices
  • ⚑ Fast Performance: Optimized loading times and smooth interactions
  • πŸ”’ Data Security: Secure data handling with encrypted passwords
  • 🎨 Modern UI: Clean, intuitive interface with Material-UI components

πŸ› οΈ Tech Stack

Frontend

  • React.js - Component-based UI library
  • React Router - Client-side routing
  • Material-UI - Modern React UI components
  • CSS3 - Custom styling and responsive design
  • Fetch API - HTTP client for API communication

Backend

  • Node.js - JavaScript runtime environment
  • Express.js - Web application framework
  • MongoDB - NoSQL database
  • Mongoose - MongoDB object modeling
  • Nodemailer - Email sending functionality
  • bcrypt - Password hashing (for secure authentication)
  • dotenv - Environment variable management
  • CORS - Cross-origin resource sharing

Additional Tools

  • JWT - JSON Web Tokens for authentication (if implemented)
  • Gmail SMTP - Email service integration

πŸ“ Project Structure

Cartrabbit/
β”œβ”€β”€ client/                     # React frontend
β”‚   β”œβ”€β”€ public/                 # Static files
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ components/         # React components
β”‚   β”‚   β”‚   β”œβ”€β”€ auth/           # Authentication components
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ Login.js
β”‚   β”‚   β”‚   β”‚   └── Register.js
β”‚   β”‚   β”‚   β”œβ”€β”€ customer/       # Customer-specific components
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ CustomerDashboard.js
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ BookService.js
β”‚   β”‚   β”‚   β”‚   └── ServiceHistory.js
β”‚   β”‚   β”‚   β”œβ”€β”€ owner/          # Owner-specific components
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ OwnerDashboard.js
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ BookingsManagement.js
β”‚   β”‚   β”‚   β”‚   β”œβ”€β”€ OrdersPage.js
β”‚   β”‚   β”‚   β”‚   └── ServicesManagement.js
β”‚   β”‚   β”‚   β”œβ”€β”€ LoadingScreen.js
β”‚   β”‚   β”‚   └── Navbar.js
β”‚   β”‚   β”œβ”€β”€ styles/             # CSS files
β”‚   β”‚   β”œβ”€β”€ App.js              # Main App component
β”‚   β”‚   └── index.js            # React entry point
β”‚   └── package.json            # Frontend dependencies
β”œβ”€β”€ server/                     # Node.js backend
β”‚   β”œβ”€β”€ config/                 # Configuration files
β”‚   β”‚   β”œβ”€β”€ db.js               # Database connection
β”‚   β”‚   └── cors.js             # CORS configuration
β”‚   β”œβ”€β”€ models/                 # Mongoose schemas
β”‚   β”‚   β”œβ”€β”€ User.js
β”‚   β”‚   β”œβ”€β”€ Booking.js
β”‚   β”‚   β”œβ”€β”€ Service.js
β”‚   β”‚   └── Car.js
β”‚   β”œβ”€β”€ routes/                 # API routes
β”‚   β”‚   β”œβ”€β”€ auth.js             # Authentication routes
β”‚   β”‚   β”œβ”€β”€ bookings.js         # Booking management
β”‚   β”‚   └── services.js         # Service management
β”‚   β”œβ”€β”€ app.js                  # Express server setup
β”‚   └── package.json            # Backend dependencies
└── README.md                   # Project documentation

πŸš€ Installation

Prerequisites

  • Node.js (v14 or higher)
  • MongoDB (local installation or MongoDB Atlas)
  • Gmail account (for email notifications)

1. Clone the Repository

git clone https://github.com/Sabari-Vasan-SM/Cartrabbit.git
cd Cartrabbit

2. Backend Setup

cd server
npm install

Create a .env file in the server directory:

MONGO_URI=mongodb://localhost:27017/cartrabbit
SMTP_USER=your-gmail@gmail.com
SMTP_PASS=your-app-password
PORT=5000

3. Frontend Setup

cd ../client
npm install

Create a .env file in the client directory (if needed):

REACT_APP_API_URL=http://localhost:5000/api

4. Start the Application

Start the backend server:

cd server
npm start

Start the frontend development server:

cd ../client
npm start

The application will be available at:

  • Frontend: http://localhost:3000
  • Backend API: http://localhost:5000

πŸ’» Usage

Customer Workflow

  1. Register/Login as a customer
  2. Browse Services available on the platform
  3. Book a Service by providing necessary details
  4. Track Status through the dashboard
  5. Receive Email Updates as service progresses
  6. View History of all past services

Owner Workflow

  1. Login as a service owner
  2. View All Bookings in the management dashboard
  3. Update Status of ongoing services
  4. Manage Services offered to customers
  5. Monitor Analytics and business metrics

πŸ”Œ API Endpoints

Authentication

  • POST /api/auth/login - User login
  • POST /api/auth/register - User registration

Bookings

  • GET /api/bookings - Get all bookings (with optional email filter)
  • POST /api/bookings - Create a new booking
  • PATCH /api/bookings/:id/status - Update booking status
  • DELETE /api/bookings/:id - Delete a booking

Services

  • GET /api/services - Get all available services
  • POST /api/services - Create a new service (owner only)
  • PUT /api/services/:id - Update a service (owner only)
  • DELETE /api/services/:id - Delete a service (owner only)

πŸ” Environment Variables

Server (.env)

MONGO_URI=your-mongodb-connection-string
SMTP_USER=your-gmail-address
SMTP_PASS=your-gmail-app-password
PORT=5000

Client (.env)

REACT_APP_API_URL=http://localhost:5000/api

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ‘¨β€πŸ’» Author

Sabari Vasan SM

πŸ™ Acknowledgments

  • Material-UI for the beautiful UI components
  • Node.js and React.js communities for excellent documentation
  • MongoDB for the flexible database solution
  • Nodemailer for seamless email integration

⭐ If you found this project helpful, please give it a star!

Releases

No releases published

Packages

No packages published