aboutsummaryrefslogtreecommitdiff
path: root/web/app/AttributeFormatter.js
diff options
context:
space:
mode:
authorninioe <ninioe@gmail.com>2016-08-01 16:12:47 +0300
committerninioe <ninioe@gmail.com>2016-08-01 16:12:47 +0300
commit94781fa3ba35e494e309aee19a5e15c14d3193c1 (patch)
treea1e4a90e9a2fce3db8bc51981aeb8a23cced5e6d /web/app/AttributeFormatter.js
parentb4841fa0a6293c0b895cf6bb65c6c2d871c78397 (diff)
parente177e7d083a4dd3f64172802661bf658d26d1163 (diff)
downloadtrackermap-server-94781fa3ba35e494e309aee19a5e15c14d3193c1.tar.gz
trackermap-server-94781fa3ba35e494e309aee19a5e15c14d3193c1.tar.bz2
trackermap-server-94781fa3ba35e494e309aee19a5e15c14d3193c1.zip
Merge remote-tracking branch 'refs/remotes/tananaev/master'
Diffstat (limited to 'web/app/AttributeFormatter.js')
-rw-r--r--web/app/AttributeFormatter.js20
1 files changed, 0 insertions, 20 deletions
diff --git a/web/app/AttributeFormatter.js b/web/app/AttributeFormatter.js
index c32849101..3432ca1e0 100644
--- a/web/app/AttributeFormatter.js
+++ b/web/app/AttributeFormatter.js
@@ -34,24 +34,6 @@ Ext.define('Traccar.AttributeFormatter', {
return Ext.getStore('DistanceUnits').formatValue(value, Traccar.app.getPreference('distanceUnit'));
},
- alarmFormatter: function (attributes) {
- var value = '';
- if (attributes instanceof Object) {//for Traccar.view.Attributes
- if (attributes.hasOwnProperty('alarm')) {
- value = attributes.alarm;
- if (typeof value === 'boolean') {
- value = (value ? Ext.Msg.buttonText.yes : Ext.Msg.buttonText.no);
- }
- }
- } else {//for Traccar.view.Report
- value = attributes;
- if (typeof value === 'boolean') {
- value = (value ? Ext.Msg.buttonText.yes : Ext.Msg.buttonText.no);
- }
- }
- return '<span style="color:red;">' + value + '</span>';
- },
-
defaultFormatter: function (value) {
if (typeof value === 'number') {
return Number(value.toFixed(Traccar.Style.numberPrecision));
@@ -76,8 +58,6 @@ Ext.define('Traccar.AttributeFormatter', {
return this.courseFormatter;
} else if (key === 'distance' || key === 'odometer') {
return this.distanceFormatter;
- } else if (key === 'alarm') {
- return this.alarmFormatter;
} else {
return this.defaultFormatter;
}