aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAbyss777 <abyss@fox5.ru>2016-10-23 06:36:44 +0500
committerAbyss777 <abyss@fox5.ru>2016-10-23 06:36:44 +0500
commit75a86394ec26725cf9460d336c03a3f55a82d599 (patch)
tree8d68ea66854c694ed3db1b7da5c1c3b936d60da0 /src
parent9eea2f26f64a3026f61f9deb13d1deac00cddcd6 (diff)
downloadtraccar-server-75a86394ec26725cf9460d336c03a3f55a82d599.tar.gz
traccar-server-75a86394ec26725cf9460d336c03a3f55a82d599.tar.bz2
traccar-server-75a86394ec26725cf9460d336c03a3f55a82d599.zip
Rename API path
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/api/resource/DeviceResource.java2
-rw-r--r--src/org/traccar/database/DeviceManager.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/org/traccar/api/resource/DeviceResource.java b/src/org/traccar/api/resource/DeviceResource.java
index 449083cb1..1f65fa041 100644
--- a/src/org/traccar/api/resource/DeviceResource.java
+++ b/src/org/traccar/api/resource/DeviceResource.java
@@ -93,7 +93,7 @@ public class DeviceResource extends BaseResource {
return Response.noContent().build();
}
- @Path("{id}/totaldistance")
+ @Path("{id}/distance")
@PUT
public Response updateTotalDistance(@PathParam("id") long id, DeviceTotalDistance entity) throws SQLException {
Context.getPermissionsManager().checkAdmin(getUserId());
diff --git a/src/org/traccar/database/DeviceManager.java b/src/org/traccar/database/DeviceManager.java
index 7d16c1c32..f71b9308c 100644
--- a/src/org/traccar/database/DeviceManager.java
+++ b/src/org/traccar/database/DeviceManager.java
@@ -430,7 +430,7 @@ public class DeviceManager implements IdentityManager {
return result;
}
- public void resetTotalDistance(DeviceTotalDistance deviceTotalDistance) throws SQLException {
+ public void resetTotalDistance(DeviceTotalDistance deviceTotalDistance) throws SQLException {
Position last = positions.get(deviceTotalDistance.getDeviceId());
if (last != null) {
last.getAttributes().put(Position.KEY_TOTAL_DISTANCE, deviceTotalDistance.getTotalDistance());