aboutsummaryrefslogtreecommitdiff
path: root/modern/src/reports
diff options
context:
space:
mode:
Diffstat (limited to 'modern/src/reports')
-rw-r--r--modern/src/reports/EventReportPage.js4
-rw-r--r--modern/src/reports/RouteReportPage.js2
-rw-r--r--modern/src/reports/StopReportPage.js6
-rw-r--r--modern/src/reports/SummaryReportPage.js4
-rw-r--r--modern/src/reports/TripReportPage.js2
5 files changed, 9 insertions, 9 deletions
diff --git a/modern/src/reports/EventReportPage.js b/modern/src/reports/EventReportPage.js
index b76ee95..45d13a2 100644
--- a/modern/src/reports/EventReportPage.js
+++ b/modern/src/reports/EventReportPage.js
@@ -5,7 +5,7 @@ import {
} from '@material-ui/core';
import { useTheme } from '@material-ui/core/styles';
import { useSelector } from 'react-redux';
-import { formatDate } from '../common/formatter';
+import { formatDate, formatPosition } from '../common/formatter';
import ReportFilter from './ReportFilter';
import ReportLayout from './ReportLayout';
import { prefixString } from '../common/stringUtils';
@@ -83,7 +83,7 @@ const EventReportPage = () => {
const columns = [{
headerName: t('positionFixTime'),
- field: 'serverTime',
+ field: 'eventTime',
type: 'dateTime',
width: theme.dimensions.columnWidthDate,
valueFormatter: ({ value }) => formatDate(value),
diff --git a/modern/src/reports/RouteReportPage.js b/modern/src/reports/RouteReportPage.js
index 3be2107..a748334 100644
--- a/modern/src/reports/RouteReportPage.js
+++ b/modern/src/reports/RouteReportPage.js
@@ -3,7 +3,7 @@ import { Paper } from '@material-ui/core';
import { DataGrid } from '@material-ui/data-grid';
import { useTheme } from '@material-ui/core/styles';
import {
- formatDistance, formatSpeed, formatBoolean, formatDate, formatCoordinate,
+ formatDistance, formatSpeed, formatBoolean, formatDate, formatCoordinate, formatPosition,
} from '../common/formatter';
import ReportFilter from './ReportFilter';
import ReportLayout from './ReportLayout';
diff --git a/modern/src/reports/StopReportPage.js b/modern/src/reports/StopReportPage.js
index aa668d5..f84b7e6 100644
--- a/modern/src/reports/StopReportPage.js
+++ b/modern/src/reports/StopReportPage.js
@@ -2,7 +2,7 @@ import React, { useState } from 'react';
import { DataGrid } from '@material-ui/data-grid';
import { useTheme } from '@material-ui/core/styles';
import {
- formatDistance, formatHours, formatDate, formatVolume,
+ formatDistance, formatHours, formatDate, formatVolume, formatPosition,
} from '../common/formatter';
import ReportFilter from './ReportFilter';
import ReportLayout from './ReportLayout';
@@ -68,13 +68,13 @@ const StopReportPage = () => {
field: 'duration',
type: 'string',
width: theme.dimensions.columnWidthString,
- valueFormatter: ({ value }) => formatHours(value),
+ valueFormatter: ({ value }) => formatHours(value, t),
}, {
headerName: t('reportEngineHours'),
field: 'engineHours',
type: 'string',
width: theme.dimensions.columnWidthString,
- valueFormatter: ({ value }) => formatHours(value),
+ valueFormatter: ({ value }) => formatHours(value, t),
}, {
headerName: t('reportSpentFuel'),
field: 'spentFuel',
diff --git a/modern/src/reports/SummaryReportPage.js b/modern/src/reports/SummaryReportPage.js
index d993d2e..2199d49 100644
--- a/modern/src/reports/SummaryReportPage.js
+++ b/modern/src/reports/SummaryReportPage.js
@@ -59,7 +59,7 @@ const SummaryReportPage = () => {
field: 'startTime',
type: 'dateTime',
width: theme.dimensions.columnWidthDate,
- valueFormatter: ({ value }) => formatDate(value, 'YYYY-MM-DD'),
+ valueFormatter: ({ value }) => formatDate(value),
}, {
headerName: t('sharedDistance'),
field: 'distance',
@@ -95,7 +95,7 @@ const SummaryReportPage = () => {
field: 'engineHours',
type: 'string',
width: theme.dimensions.columnWidthNumber,
- valueFormatter: ({ value }) => formatHours(value),
+ valueFormatter: ({ value }) => formatHours(value, t),
}, {
headerName: t('reportSpentFuel'),
field: 'spentFuel',
diff --git a/modern/src/reports/TripReportPage.js b/modern/src/reports/TripReportPage.js
index 632da7c..91c165d 100644
--- a/modern/src/reports/TripReportPage.js
+++ b/modern/src/reports/TripReportPage.js
@@ -99,7 +99,7 @@ const TripReportPage = () => {
field: 'duration',
type: 'string',
width: theme.dimensions.columnWidthString,
- valueFormatter: ({ value }) => formatHours(value),
+ valueFormatter: ({ value }) => formatHours(value, t),
}, {
headerName: t('reportSpentFuel'),
field: 'spentFuel',