aboutsummaryrefslogtreecommitdiff
path: root/web/app/model
diff options
context:
space:
mode:
Diffstat (limited to 'web/app/model')
-rw-r--r--web/app/model/Command.js8
-rw-r--r--web/app/model/KnownCommand.js3
2 files changed, 1 insertions, 10 deletions
diff --git a/web/app/model/Command.js b/web/app/model/Command.js
index aa3dad14..f64d2a4b 100644
--- a/web/app/model/Command.js
+++ b/web/app/model/Command.js
@@ -32,14 +32,6 @@ Ext.define('Traccar.model.Command', {
name: 'type',
type: 'string'
}, {
- name: 'name',
- convert: function (v, rec) {
- var name = Strings['command' + rec.get('type').charAt(0).toUpperCase() + rec.get('type').slice(1)];
- return name ? name : rec.get('type');
- },
- depends: ['type'],
- persist: false
- }, {
name: 'textChannel',
type: 'boolean'
}, {
diff --git a/web/app/model/KnownCommand.js b/web/app/model/KnownCommand.js
index 08213020..06610e32 100644
--- a/web/app/model/KnownCommand.js
+++ b/web/app/model/KnownCommand.js
@@ -25,8 +25,7 @@ Ext.define('Traccar.model.KnownCommand', {
}, {
name: 'name',
convert: function (v, rec) {
- var name = Strings['command' + rec.get('type').charAt(0).toUpperCase() + rec.get('type').slice(1)];
- return name ? name : rec.get('type');
+ return Traccar.AttributeFormatter.getFormatter('commandType')(rec.get('type'));
},
depends: ['type']
}, {