summaryrefslogtreecommitdiffstats
path: root/install/ui/user.js
diff options
context:
space:
mode:
authorEndi S. Dewata <edewata@redhat.com>2011-04-12 02:13:30 -0500
committerAdam Young <ayoung@redhat.com>2011-04-13 23:27:50 -0400
commit805b94f22d42eddee42ed8772aca89036edb8399 (patch)
tree12c6d80ce465b0541cfb15332177f36fba79bc0b /install/ui/user.js
parent9cac1d88fcffcce65018869827eadcfc0ff157f1 (diff)
downloadfreeipa-805b94f22d42eddee42ed8772aca89036edb8399.tar.gz
freeipa-805b94f22d42eddee42ed8772aca89036edb8399.tar.xz
freeipa-805b94f22d42eddee42ed8772aca89036edb8399.zip
Merged IPA.cmd() into IPA.command().
The IPA.cmd() has been merged into IPA.command(). All invocations and test cases have been converted. Ticket #988
Diffstat (limited to 'install/ui/user.js')
-rw-r--r--install/ui/user.js12
1 files changed, 9 insertions, 3 deletions
diff --git a/install/ui/user.js b/install/ui/user.js
index c88fe78d6..392ac5337 100644
--- a/install/ui/user.js
+++ b/install/ui/user.js
@@ -136,11 +136,17 @@ IPA.user_status_widget = function(spec) {
var jobj = $(this);
var val = jobj.attr('title');
var pkey = $.bbq.getState('user-pkey');
- var command = 'user_enable';
+ var method = 'enable';
if (val == IPA.messages.objects.user.active) {
- command = 'user_disable';
+ method = 'disable';
}
- IPA.cmd(command, [pkey], {}, on_lock_win,on_lock_fail);
+ IPA.command({
+ entity: 'user',
+ method: method,
+ args: [pkey],
+ on_success: on_lock_win,
+ on_error: on_lock_fail
+ }).execute();
return (false);
}