Car Rental system using nodeJS, Express, MongoDB and Neo4j.

This is a simple car rental system built with node.js using MongoDB and Neo4j as the databases. It uses Neo4j's geolocation function to calculate the distance between two nodes to calculate the distance between the cars and the user and shows the nearby cars.

Installation

  • Install MongoDB compass
  • Install Neo4j Desktop (Or use Neo4j web)
  • Use the following command in cypher to import car locations into Neo4j
LOAD CSV WITH HEADERS FROM "https://raw.githubusercontent.com/abirbanerjee/Misc/main/car_neo4j.csv" AS ROW
CREATE (C:Car {car_id:ROW.car_id, lat:ROW.lat, lon:ROW.long})
  • Create a new database in MongoDB called car_rental
  • Import cars and customers collection into the database.
  • Copy or download this repository and do
npm install
npm test OR node index.js
  • Open your browser and go to (localhost:3000)

Screenshots

Home Screen Cars around the user Description Booking Bookng 2 Booking final Retrieval screen