summaryrefslogtreecommitdiffstats
path: root/install/ui/src/freeipa/group.js
diff options
context:
space:
mode:
authorPetr Vobornik <pvoborni@redhat.com>2014-04-24 16:32:07 +0200
committerPetr Vobornik <pvoborni@redhat.com>2014-06-11 10:47:27 +0200
commite3840eef09f4a6b1ac3c0a92f5929353a6c9e6b6 (patch)
tree98a1c2200b8689dc9eb429483c9fc845fcf2f7ac /install/ui/src/freeipa/group.js
parent255cbb49763ff579feed935a5a725fc2b272749c (diff)
downloadfreeipa-e3840eef09f4a6b1ac3c0a92f5929353a6c9e6b6.tar.gz
freeipa-e3840eef09f4a6b1ac3c0a92f5929353a6c9e6b6.tar.xz
freeipa-e3840eef09f4a6b1ac3c0a92f5929353a6c9e6b6.zip
webui: fix regression: enabled gid field on group add
GID field should be enabled by default since the default group is posix. Was caused by option_widget_base not properly reporting value change while selecting the default value. It has to be notified with delay otherwise the event is consumed by FieldBinder. https://fedorahosted.org/freeipa/ticket/4325 Reviewed-By: Endi Sukma Dewata <edewata@redhat.com>
Diffstat (limited to 'install/ui/src/freeipa/group.js')
-rw-r--r--install/ui/src/freeipa/group.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/install/ui/src/freeipa/group.js b/install/ui/src/freeipa/group.js
index f2103f8e8..3961384dc 100644
--- a/install/ui/src/freeipa/group.js
+++ b/install/ui/src/freeipa/group.js
@@ -21,6 +21,7 @@
*/
define([
+ 'dojo/on',
'./ipa',
'./jquery',
'./phases',
@@ -29,7 +30,7 @@ define([
'./search',
'./association',
'./entity'],
- function(IPA, $, phases, reg) {
+ function(on, IPA, $, phases, reg) {
var exp = IPA.group = {};
@@ -197,14 +198,14 @@ IPA.group_adder_dialog = function(spec) {
var init = function() {
var type_field = that.fields.get_field('type');
- type_field.widget.value_changed.attach(that.on_type_change);
+ on(type_field, 'value-change', that.on_type_change);
};
that.on_type_change = function() {
var type_field = that.fields.get_field('type');
var gid_field = that.fields.get_field('gidnumber');
- var posix = type_field.save()[0] === 'posix';
+ var posix = type_field.get_value()[0] === 'posix';
if (!posix) {
gid_field.reset();