diff options
Diffstat (limited to 'web/app/view/UserDialogController.js')
-rw-r--r-- | web/app/view/UserDialogController.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/web/app/view/UserDialogController.js b/web/app/view/UserDialogController.js index 11f8c2f46..db495b8ff 100644 --- a/web/app/view/UserDialogController.js +++ b/web/app/view/UserDialogController.js @@ -18,6 +18,10 @@ Ext.define('Traccar.view.UserDialogController', { extend: 'Ext.app.ViewController', alias: 'controller.userDialog', + requires: [ + 'Traccar.view.Attributes' + ], + init: function () { if (Traccar.app.getUser().get('admin')) { this.lookupReference('adminField').setDisabled(false); @@ -44,5 +48,19 @@ Ext.define('Traccar.view.UserDialogController', { }); } button.up('window').close(); + }, + + showAttributesView: function (button) { + var dialog, record; + dialog = button.up('window').down('form'); + record = dialog.getRecord(); + Ext.create('Traccar.view.BaseWindow', { + title: Strings.sharedAttributes, + modal: false, + items: { + xtype: 'attributesView', + attributes: record.get('attributes') + } + }).show(); } }); |