Giter Site home page Giter Site logo

park-it's Introduction

Park-It

Javscript (node.js) based parking application

Parking assistance:

  • 2000m parking places with availability status.
  • Auto direction/navigation to the nearest parking slot based on availability.
  • Indoor parking map, for more parking efficiency.

Proposal

Web based parking assistance.

Mission Statement

Develop a parking assist application purely using web based technologies such as HTML, css, 
Javascript and its open sourced frameworks such as node.js, bootstrap, jQuery, jQuery UI etc.

Summary

  • Parking is a huge problem in most of the places, eventhough there are applications available in assisting, which is not sufficient.
  • Park-It should overcome these issues by providing real time navigation to the closest parking space available.

Outcome

  • Phase 1: Based on the User's current location, Park-It will show the closest available parking space.

Impact to society

Allows user to find a parking lot with empty spaces based on his location instead of running in circles or parking in no parking spaces.

Architecture

Frameworks:
	Components:
		-Client:
			UI: Pure HTMLs, CSSs and JSs
			Structure (Controller and Model): 
				JQUERY:
					-AJAX calls
					-Deferred chaining
				MooTools:
					-OOPS in JS
		-Server:
			Web server:
				Node js server
		-Database:
			MongoDb

Core:
	Google APIs:
		Maps Javascript
		Places Web services
		Direction services
		Distance matrix services
	MooTools classes:
		Park regions
		Markers

Technical Document

Main Page:
	-index.html (park-it\views\index.html)
		<script src="https://maps.googleapis.com/maps/api/js?key=<KEY>&signed_in=true&libraries=places&callback
		=initMap" async defer></script>

		The above script loads the google map on the body and calls the callback "initMap" after loading the map.
		The initMap initializes ParkItPage , which is a utility and base class available throughout the lifecycle
		of one session. This class also holds methods such as openInfoWindow (google's info box for markers), 
		calculateAndDisplayRoute (googles directionsDisplay and directionsService API), displayParking (google 
		getPlaceDetails Ajax request), displayIndoorMap (displays indoor map).

		After initializing ParkItPage, initMap adds listeners such as zoom_changed, place_changed et Cetera then
		starts initializing ParkItRegion class, which fires getRegionData. The callback for getRegionData creates 
		the parking place markers. The place markers are created using a class Marker, which has an important 
		timer functions getAvailability, which gets the availability status of the particular marker. This timer
		function calls itself for every 8 minutes.

		When the autocomplete's address input changes with new location, the ParkItRegion will be re-initialized
		with a new position.

	
Main Javascript:
	-parkit.js (park-it\public\javascripts\parkit.js)
	This js contains the following important classes:
		-ParkItPage class, which is standalone utility class having static methods such as openInfoWindow,
		calculateAndDisplayRoute, et Cetera, is created only once during the entire lifecycle the web page.
		-ParkItRegion class, which is the main holder class created on every zoom changed or new location change,
		holds the API (getRegionData) for fetching parking information using google places nearby search AJAX and
		the API (createMarker) for creating markers on maps.
		-Marker class, which is placeholder class created for every parking slot , holds all the necessary API
		for that specific slot such as getAvailability , setIcon et Cetera

Main Server Page:
	-index.js (park-it\routes\index.js)
	This is the main router for the backend server which processes all the AJAX request from the front-end 
	including google API AJAX calls. Google's Places API AJAX calls are re-directed to this route, then this
	route handles these requests with fail back.

	This js contains the following GET requests:
	-getData
	-getAvailability
	-getAllPlaceIds
	-getAllAvailability
	-removePlace
	-addAvailability
	-insertParkers
	-updateAvailability
	-addPlaceToGoogle
	-deletePlaceToGoogle
	-getPlaceDetails

Demo

Alt text

park-it's People

Contributors

nishoknm avatar gzssince1990 avatar

Watchers

Yan Minagawa avatar James Cloos 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.