diff options
author | Endi S. Dewata <edewata@redhat.com> | 2011-11-11 22:33:05 -0600 |
---|---|---|
committer | Adam Young <ayoung@redhat.com> | 2011-11-14 16:47:08 -0500 |
commit | d6d24be28953f2ec3cf1f2400619fd61459cf45f (patch) | |
tree | 3a0db972a38a37b417a0aaba3c1b38ecf60e4cb9 /install/ui/widget.js | |
parent | 0f34e0bf82d5e0bf905ac8af7257d2f33d72d9a0 (diff) | |
download | freeipa.git-d6d24be28953f2ec3cf1f2400619fd61459cf45f.tar.gz freeipa.git-d6d24be28953f2ec3cf1f2400619fd61459cf45f.tar.xz freeipa.git-d6d24be28953f2ec3cf1f2400619fd61459cf45f.zip |
Refactored permission target section.
The permission target section has been modified to use widgets
to create the target selection and handle multiple fields.
Ticket #2098
Diffstat (limited to 'install/ui/widget.js')
-rw-r--r-- | install/ui/widget.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/install/ui/widget.js b/install/ui/widget.js index 2a3b952b..e9fffaf1 100644 --- a/install/ui/widget.js +++ b/install/ui/widget.js @@ -66,6 +66,7 @@ IPA.widget = function(spec) { that.valid = true; that.dirty_changed = IPA.observer(); + that.value_changed = IPA.observer(); var init = function() { if (!that.metadata && that.entity) { @@ -820,7 +821,6 @@ IPA.checkbox_widget = function (spec) { // default value that.checked = spec.checked || false; - that.value_changed = IPA.observer(); that.create = function(container) { @@ -1109,6 +1109,7 @@ IPA.select_widget = function(spec) { that.select = $('select[name="'+that.name+'"]', that.container); that.select.change(function() { that.set_dirty(that.test_dirty()); + that.value_changed.notify(that.save(), that); }); that.create_error_link(container); @@ -1141,7 +1142,7 @@ IPA.select_widget = function(spec) { }; that.clear = function() { - that.empty(); + $('option', that.select).attr('selected', ''); }; // methods that should be invoked by subclasses |