diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2014-05-22 16:20:02 +0200 |
---|---|---|
committer | Petr Vobornik <pvoborni@redhat.com> | 2014-06-26 12:37:39 +0200 |
commit | 870db2f677dff01750aeec104c90fce3ca0e54be (patch) | |
tree | 024f578dd8f3a7c5b26e9c7ecf6b9d82339a272a /install/ui/src/freeipa/dialogs | |
parent | e3de46767683c5050377cc5e683cd6e3d28ea4e9 (diff) | |
download | freeipa-870db2f677dff01750aeec104c90fce3ca0e54be.tar.gz freeipa-870db2f677dff01750aeec104c90fce3ca0e54be.tar.xz freeipa-870db2f677dff01750aeec104c90fce3ca0e54be.zip |
webui: rebase user password dialog on password dialog and add otp support
https://fedorahosted.org/freeipa/ticket/4262
Reviewed-By: Endi Sukma Dewata <edewata@redhat.com>
Diffstat (limited to 'install/ui/src/freeipa/dialogs')
-rw-r--r-- | install/ui/src/freeipa/dialogs/password.js | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/install/ui/src/freeipa/dialogs/password.js b/install/ui/src/freeipa/dialogs/password.js index 35f96e4b7..fa672901d 100644 --- a/install/ui/src/freeipa/dialogs/password.js +++ b/install/ui/src/freeipa/dialogs/password.js @@ -51,6 +51,7 @@ dialogs.password.default_fields_pre_op = function(spec) { spec.width = spec.width || 400; spec.sections = spec.sections || [ { + name: 'general', fields: [ { name: name, @@ -193,7 +194,7 @@ dialogs.password.dialog = function(spec) { for (var j=0; j<fields.length; j++) { var field = fields[j]; var values = field.save(); - if (!values || values.length === 0) continue; + if (!values || values.length === 0 || !field.enabled) continue; if (field.flags.indexOf('no_command') > -1) continue; if (values.length === 1) { @@ -212,10 +213,12 @@ dialogs.password.dialog = function(spec) { that.create_command = function() { var options = that.make_otions(); + var entity = null; + if (that.entity) entity = that.entity.name; var command = rpc.command({ - entity: that.entity.name, + entity: entity, method: that.method, - args: that.pkeys, + args: that.args, options: options, on_success: function(data) { that.on_success(); @@ -301,7 +304,7 @@ dialogs.password.action = function(spec) { ds.$type = 'password'; } var dialog = builder.build('dialog', ds); - dialog.pkeys = facet.get_pkeys(); + dialog.args = facet.get_pkeys(); dialog.succeeded.attach(function() { if (that.refresh) facet.refresh(); }); |