diff options
Diffstat (limited to 'web/app')
-rw-r--r-- | web/app/store/CommonUserAttributes.js | 4 | ||||
-rw-r--r-- | web/app/view/Main.js | 1 | ||||
-rw-r--r-- | web/app/view/MainController.js | 1 | ||||
-rw-r--r-- | web/app/view/map/MapController.js | 3 |
4 files changed, 8 insertions, 1 deletions
diff --git a/web/app/store/CommonUserAttributes.js b/web/app/store/CommonUserAttributes.js index eadb1c59..c2c29429 100644 --- a/web/app/store/CommonUserAttributes.js +++ b/web/app/store/CommonUserAttributes.js @@ -43,6 +43,10 @@ Ext.define('Traccar.store.CommonUserAttributes', { name: Strings.attributeUiDisableReport, valueType: 'boolean' }, { + key: 'ui.disableEvents', + name: Strings.attributeUiDisableEvents, + valueType: 'boolean' + }, { key: 'ui.disableVehicleFetures', name: Strings.attributeUiDisableVehicleFetures, valueType: 'boolean' diff --git a/web/app/view/Main.js b/web/app/view/Main.js index 2d251a5b..0504245e 100644 --- a/web/app/view/Main.js +++ b/web/app/view/Main.js @@ -75,6 +75,7 @@ Ext.define('Traccar.view.Main', { }, { region: 'east', xtype: 'eventsView', + reference: 'eventsView', width: Traccar.Style.deviceWidth, collapsed: true, titleCollapse: true, diff --git a/web/app/view/MainController.js b/web/app/view/MainController.js index 126d9af5..7cd03050 100644 --- a/web/app/view/MainController.js +++ b/web/app/view/MainController.js @@ -21,5 +21,6 @@ Ext.define('Traccar.view.MainController', { init: function () { this.lookupReference('reportView').setHidden(Traccar.app.getBooleanAttributePreference('ui.disableReport')); + this.lookupReference('eventsView').setHidden(Traccar.app.getBooleanAttributePreference('ui.disableEvents')); } }); diff --git a/web/app/view/map/MapController.js b/web/app/view/map/MapController.js index 75796f9b..38b2340c 100644 --- a/web/app/view/map/MapController.js +++ b/web/app/view/map/MapController.js @@ -46,7 +46,8 @@ Ext.define('Traccar.view.map.MapController', { this.callParent(); this.lookupReference('showReportsButton').setVisible( Traccar.app.isMobile() && !Traccar.app.getBooleanAttributePreference('ui.disableReport')); - this.lookupReference('showEventsButton').setVisible(Traccar.app.isMobile()); + this.lookupReference('showEventsButton').setVisible( + Traccar.app.isMobile() && !Traccar.app.getBooleanAttributePreference('ui.disableEvents')); }, showReports: function () { |