aboutsummaryrefslogtreecommitdiff
path: root/web/app/view/dialog/ComputedAttributeController.js
diff options
context:
space:
mode:
Diffstat (limited to 'web/app/view/dialog/ComputedAttributeController.js')
-rw-r--r--web/app/view/dialog/ComputedAttributeController.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/web/app/view/dialog/ComputedAttributeController.js b/web/app/view/dialog/ComputedAttributeController.js
index 807653a6..f680b1b5 100644
--- a/web/app/view/dialog/ComputedAttributeController.js
+++ b/web/app/view/dialog/ComputedAttributeController.js
@@ -20,6 +20,10 @@ Ext.define('Traccar.view.dialog.ComputedAttributeController', {
extend: 'Traccar.view.dialog.BaseEditController',
alias: 'controller.computedAttribute',
+ requires: [
+ 'Traccar.view.dialog.SelectDevice'
+ ],
+
onAttributeChange: function (combobox, newValue) {
var attribute = Ext.getStore('PositionAttributes').getById(newValue);
if (attribute) {
@@ -28,5 +32,14 @@ Ext.define('Traccar.view.dialog.ComputedAttributeController', {
} else {
this.getView().lookupReference('typeComboField').setReadOnly(false);
}
+ },
+
+ onCheckClick: function (button) {
+ var dialog, form;
+ dialog = Ext.create('Traccar.view.dialog.SelectDevice');
+ form = button.up('window').down('form');
+ form.updateRecord();
+ dialog.record = form.getRecord();
+ dialog.show();
}
});