diff options
Diffstat (limited to 'install/ui/dialog.js')
-rw-r--r-- | install/ui/dialog.js | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/install/ui/dialog.js b/install/ui/dialog.js index cba5b1abf..f60db5cab 100644 --- a/install/ui/dialog.js +++ b/install/ui/dialog.js @@ -276,12 +276,23 @@ IPA.dialog = function(spec) { if (field_spec instanceof Object) { var factory = field_spec.factory || IPA.text_widget; field = factory(field_spec); + + /* This is a bit of a hack, and is here to support ACI + permissions. The target section is a group of several + widgets together. It makes more sense to do them as a + section than as a widget. However, since they can be mixed + into the flow with the other widgets, the section needs to + be defined here with the fields to get the order correct.*/ + if (field.section) { + that.add_section(field); + } else { + that.add_field(field); + } + } else { - var field_name = field_spec; - field = IPA.text_widget({ name: field_name, undo: false }); + field = IPA.text_widget({ name: field_spec, undo: false }); + that.add_field(field); } - - that.add_field(field); } return that; |