diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2016-08-23 17:14:47 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-23 17:14:47 +1000 |
commit | e911fa2c7e4138b1edaa95ab603617660cea0462 (patch) | |
tree | 8b07a5f6c4e272eb3d574ad2398442b07c848fe6 /src/org/traccar/reports | |
parent | 6c6b62351aadd68928b9bd3e39e2bf96d78695e8 (diff) | |
parent | f9065826c7855d1344ba75a4eb46da325eb91cab (diff) | |
download | traccar-server-e911fa2c7e4138b1edaa95ab603617660cea0462.tar.gz traccar-server-e911fa2c7e4138b1edaa95ab603617660cea0462.tar.bz2 traccar-server-e911fa2c7e4138b1edaa95ab603617660cea0462.zip |
Merge pull request #2240 from Abyss777/odometer
Odometer units for first part of protocols
Diffstat (limited to 'src/org/traccar/reports')
-rw-r--r-- | src/org/traccar/reports/ReportUtils.java | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/org/traccar/reports/ReportUtils.java b/src/org/traccar/reports/ReportUtils.java index 34f04ac87..67d577904 100644 --- a/src/org/traccar/reports/ReportUtils.java +++ b/src/org/traccar/reports/ReportUtils.java @@ -48,8 +48,7 @@ public final class ReportUtils { if (useOdometer && firstPosition.getAttributes().containsKey(Position.KEY_ODOMETER) && lastPosition.getAttributes().containsKey(Position.KEY_ODOMETER)) { distance = (((Number) lastPosition.getAttributes().get(Position.KEY_ODOMETER)).doubleValue() - - ((Number) firstPosition.getAttributes().get(Position.KEY_ODOMETER)).doubleValue()) - * 1000; + - ((Number) firstPosition.getAttributes().get(Position.KEY_ODOMETER)).doubleValue()); } else if (firstPosition.getAttributes().containsKey(Position.KEY_TOTAL_DISTANCE) && lastPosition.getAttributes().containsKey(Position.KEY_TOTAL_DISTANCE)) { distance = ((Number) lastPosition.getAttributes().get(Position.KEY_TOTAL_DISTANCE)).doubleValue() |