aboutsummaryrefslogtreecommitdiff
path: root/web/app/view/UserDialogController.js
diff options
context:
space:
mode:
authorAbyss777 <abyss@fox5.ru>2016-06-28 22:49:08 +0500
committerAbyss777 <abyss@fox5.ru>2016-06-28 22:49:08 +0500
commit647071c9483daa2046d7f75c335b2763672befc6 (patch)
tree01330c1e772a2b19f856b071a3ba2b88564ed2ae /web/app/view/UserDialogController.js
parent8cb9fb298578bc4870a360d258172ef80cffeee3 (diff)
downloadtrackermap-server-647071c9483daa2046d7f75c335b2763672befc6.tar.gz
trackermap-server-647071c9483daa2046d7f75c335b2763672befc6.tar.bz2
trackermap-server-647071c9483daa2046d7f75c335b2763672befc6.zip
Added attributes editor
Diffstat (limited to 'web/app/view/UserDialogController.js')
-rw-r--r--web/app/view/UserDialogController.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/web/app/view/UserDialogController.js b/web/app/view/UserDialogController.js
index 11f8c2f46..b3496fe6a 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();
+ },
+
+ attributesView: 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();
}
});