Giter Site home page Giter Site logo

kiwifu / 2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from husney24/rental-car-services

0.0 0.0 0.0 15.14 MB

Rental Cab Service - Where You Can Book Cars for Schedule, and Also Drivers Can Register with Car and License

JavaScript 91.57% CSS 7.00% HTML 1.43%

2's Introduction

Rental Cab Service

Welcome to the Rental Cab Service project! This repository contains the code for a complete car rental service, featuring a React frontend and a Node.js backend with a MySQL database.

Table of Contents

Overview

Rental Cab Service is a web application that allows users to search for cars near their location, book a ride, and schedule rides. The platform supports user and driver registrations, ensuring a seamless experience for both passengers and drivers.

Features

  • User Registration: Allows users to create an account and manage their bookings.
  • Driver Registration: Enables drivers to register with their license number and car details.
  • Car Search: Users can search for available cars near their location.
  • Booking and Scheduling: Users can book immediate rides or schedule future rides.

Installation

Prerequisites

Ensure you have the following installed:

  • Node.js
  • npm (Node Package Manager)
  • MySQL

Frontend

  1. Navigate to the frontend directory:
    cd frontend
  2. Install dependencies:
    npm install

Backend

  1. Navigate to the backend directory:
    cd backend
  2. Install dependencies:
    npm install

Database Setup

  1. Install MySQL and start the MySQL server.

  2. Create a new database:

    CREATE DATABASE rental_cab_service;
  3. Create a user and grant all privileges on the database (replace username and password with your own):

    CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
    GRANT ALL PRIVILEGES ON rental_cab_service.* TO 'username'@'localhost';
    FLUSH PRIVILEGES;
  4. Import the database schema (if you have a SQL file with the schema):

    mysql -u username -p rental_cab_service < path/to/schema.sql
  5. Update the database configuration in the backend. Create a .env file in the backend directory and add the following:

    DB_HOST=localhost
    DB_USER=username
    DB_PASSWORD=password
    DB_NAME=rental_cab_service

Usage

Starting the Frontend

  1. Navigate to the frontend directory:
    cd frontend
  2. Start the development server:
    npm start
  3. Open your browser and navigate to http://localhost:3000.

Starting the Backend

  1. Navigate to the backend directory:
    cd backend
  2. Start the backend server with Nodemon for automatic restarts:
    nodemon index.js
  3. The backend server should be running on http://localhost:5000.

Contributing

Contributions are welcome! Please follow these steps to contribute:

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

License

This project is licensed under the MIT License. See the LICENSE file for more details.


Thank you for using Rental Cab Service! If you have any questions or suggestions, feel free to open an issue or contact the project maintainers.

2's People

Contributors

husney24 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.