diff options
author | Abyss777 <abyss@fox5.ru> | 2017-12-26 09:01:04 +0500 |
---|---|---|
committer | Abyss777 <abyss@fox5.ru> | 2017-12-28 09:13:37 +0500 |
commit | 54210c6f8bcd5d2e467d63aa5ac51389c8853b5f (patch) | |
tree | 603fca42924479dd6aca922e29008d5c1c68e828 /web/app/view/edit/Devices.js | |
parent | 19768f9c88958207a20a81bdfe7ee630bf400973 (diff) | |
download | trackermap-web-54210c6f8bcd5d2e467d63aa5ac51389c8853b5f.tar.gz trackermap-web-54210c6f8bcd5d2e467d63aa5ac51389c8853b5f.tar.bz2 trackermap-web-54210c6f8bcd5d2e467d63aa5ac51389c8853b5f.zip |
Implement disabling devices
Diffstat (limited to 'web/app/view/edit/Devices.js')
-rw-r--r-- | web/app/view/edit/Devices.js | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/web/app/view/edit/Devices.js b/web/app/view/edit/Devices.js index 39550b6c..6e581d4f 100644 --- a/web/app/view/edit/Devices.js +++ b/web/app/view/edit/Devices.js @@ -81,11 +81,14 @@ Ext.define('Traccar.view.edit.Devices', { viewConfig: { enableTextSelection: true, getRowClass: function (record) { - var status = record.get('status'); + var status = record.get('status'), result = ''; + if (record.get('disabled')) { + result = 'view-item-disabled '; + } if (status) { - return Ext.getStore('DeviceStatuses').getById(status).get('color'); + result += Ext.getStore('DeviceStatuses').getById(status).get('color'); } - return null; + return result; } }, @@ -125,6 +128,12 @@ Ext.define('Traccar.view.edit.Devices', { }, renderer: Traccar.AttributeFormatter.getFormatter('groupId') }, { + text: Strings.sharedDisabled, + dataIndex: 'disabled', + renderer: Traccar.AttributeFormatter.getFormatter('disabled'), + hidden: true, + filter: 'boolean' + }, { text: Strings.sharedGeofences, dataIndex: 'geofenceIds', hidden: true, |