From 279948e95f21ffed7f890e5253693a307953d255 Mon Sep 17 00:00:00 2001 From: Abyss777 Date: Mon, 30 May 2016 15:04:51 +0500 Subject: Disable command button if device is not online. --- web/app/view/DevicesController.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'web/app/view/DevicesController.js') diff --git a/web/app/view/DevicesController.js b/web/app/view/DevicesController.js index 9dee0ff7c..8c1bba00f 100644 --- a/web/app/view/DevicesController.js +++ b/web/app/view/DevicesController.js @@ -103,7 +103,7 @@ Ext.define('Traccar.view.DevicesController', { var empty = selected.getCount() === 0; this.lookupReference('toolbarEditButton').setDisabled(empty); this.lookupReference('toolbarRemoveButton').setDisabled(empty); - this.lookupReference('deviceCommandButton').setDisabled(empty); + this.lookupReference('deviceCommandButton').setDisabled(empty || (selected.getLastSelected().get('status') !== 'online')); if (!empty) { this.fireEvent('selectDevice', selected.getLastSelected(), true); } -- cgit v1.2.3