项目作者: allangomessl

项目描述 :
Spring Boot | Mongo DB | Kotlin | Angular JS | Leaflet | Gradle | Custom JS Plugin
高级语言: JavaScript
项目地址: git://github.com/allangomessl/GeoLocation.git
创建时间: 2016-12-12T18:33:35Z
项目社区:https://github.com/allangomessl/GeoLocation

开源协议:

下载


GeoLocation

Spring Boot | Mongo DB | Kotlin | Angular JS | Leaflet | Custom JS Plugin

REST SERVER

Routes

Create New Route

  1. POST http://localhost:8080/routes/
  2. {
  3. "name": "Rota Principal",
  4. "vehicleId": 4,
  5. "routeDate": "2016-12-13",
  6. "stops": [
  7. { "name": "Inicio", "coordinate": { "lat": -3.784426, "lng": -38.583058 } },
  8. { "name": "Parada", "coordinate": { "lat": -3.742261, "lng": -38.499705 } },
  9. { "name": "Final", "coordinate": { "lat": -3.737121, "lng": -38.575313 } }
  10. ]
  11. }

Get All Routes

  1. GET http://localhost:8080/routes/

Get Route Path/Polyline

  1. GET http://localhost:8080/routes/{routeId}/path

Check run away and nearby point

  1. POST http://localhost:8080/routes/vehicle/{vehicleId}/checkpoint?lat=-3.726636&lng=-38.508690

Front

start

  1. $ npm start
  2. http://localhost:8001/

Plugin

customize polyline | below example: Customized Profiles default and runned

  1. angular.module('trix.routes').config(['polylineProvider', function (polylineConfig) {
  2. polylineConfig
  3. .options('default', {
  4. color: 'blue',
  5. weight: 10
  6. })
  7. .options('runned', {
  8. color: 'red',
  9. weight: 3
  10. })
  11. }])

ARQUITETURA

Baseada na arquitetura do Leaflet, Extremamente fácil de mapear com a biblioteca