]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/index/directions/graphhopper.js
Merge remote-tracking branch 'upstream/pull/4303'
[rails.git] / app / assets / javascripts / index / directions / graphhopper.js
index 6bd430c06021612ccb086a8b58b6c14f97a9d6af..11d600316db8e5ddb978dc6d8011223f947d0c9a 100644 (file)
@@ -14,7 +14,7 @@ function GraphHopperEngine(id, vehicleType) {
 
   return {
     id: id,
-    creditline: "<a href=\"https://www.graphhopper.com/\" target=\"_blank\">Graphhopper</a>",
+    creditline: "<a href=\"https://www.graphhopper.com/\" target=\"_blank\">GraphHopper</a>",
     draggable: false,
 
     getRoute: function (points, callback) {
@@ -23,13 +23,13 @@ function GraphHopperEngine(id, vehicleType) {
       return $.ajax({
         url: OSM.GRAPHHOPPER_URL,
         data: {
-          "vehicle": vehicleType,
-          "locale": I18n.currentLocale(),
-          "key": "LijBPDQGfu7Iiq80w3HzwB4RUDJbMbhs6BU0dEnn",
-          "ch.disable": vehicleType === "car",
-          "elevation": false,
-          "instructions": true,
-          "point": points.map(function (p) { return p.lat + "," + p.lng; })
+          vehicle: vehicleType,
+          locale: I18n.currentLocale(),
+          key: "LijBPDQGfu7Iiq80w3HzwB4RUDJbMbhs6BU0dEnn",
+          elevation: false,
+          instructions: true,
+          turn_costs: vehicleType === "car",
+          point: points.map(function (p) { return p.lat + "," + p.lng; })
         },
         traditional: true,
         dataType: "json",