aboutsummaryrefslogtreecommitdiff
path: root/web/app/AttributeFormatter.js
diff options
context:
space:
mode:
Diffstat (limited to 'web/app/AttributeFormatter.js')
-rw-r--r--web/app/AttributeFormatter.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/web/app/AttributeFormatter.js b/web/app/AttributeFormatter.js
index 1cbc1cfc0..3432ca1e0 100644
--- a/web/app/AttributeFormatter.js
+++ b/web/app/AttributeFormatter.js
@@ -40,7 +40,11 @@ Ext.define('Traccar.AttributeFormatter', {
} else if (typeof value === 'boolean') {
return value ? Ext.Msg.buttonText.yes : Ext.Msg.buttonText.no;
} else if (value instanceof Date) {
- return Ext.Date.format(value, Traccar.Style.dateTimeFormat);
+ if (Traccar.app.getPreference('twelveHourFormat', false)) {
+ return Ext.Date.format(value, Traccar.Style.dateTimeFormat12);
+ } else {
+ return Ext.Date.format(value, Traccar.Style.dateTimeFormat24);
+ }
}
return value;
},