From 58746226d4b36bc40de91d4d1dd283e9faaff639 Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Fri, 12 Feb 2010 16:34:21 -0500 Subject: Use the Output tuple to determine the order of output The attributes displayed is now dependant upon their definition in a Param. This enhances that, giving some level of control over how the result is displayed to the user. This also fixes displaying group membership, including failures of adding/removing entries. All tests pass now though there is still one problem. We need to return the dn as well. Once that is fixed we just need to comment out all the dn entries in the tests and they should once again pass. --- ipalib/plugins/user.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'ipalib/plugins/user.py') diff --git a/ipalib/plugins/user.py b/ipalib/plugins/user.py index c06a9280..00d64c7e 100644 --- a/ipalib/plugins/user.py +++ b/ipalib/plugins/user.py @@ -38,7 +38,7 @@ class user(LDAPObject): object_class_config = 'ipauserobjectclasses' default_attributes = [ 'uid', 'givenname', 'sn', 'homedirectory', 'loginshell', 'ou', - 'telephonenumber', 'title', + 'telephonenumber', 'title', 'memberof', ] uuid_attribute = 'ipauniqueid' attribute_names = { @@ -53,10 +53,10 @@ class user(LDAPObject): 'krbpasswordexpiration': 'password expiration', 'uidnumber': 'uid number', 'gidnumber': 'gid number', - 'memberof group': 'member of groups', - 'memberof netgroup': 'member of netgroups', - 'memberof rolegroup': 'member of rolegroups', - 'memberof taskgroup': 'member of taskgroups', + 'memberof_group': 'member of groups', + 'memberof_netgroup': 'member of netgroups', + 'memberof_rolegroup': 'member of rolegroups', + 'memberof_taskgroup': 'member of taskgroups', 'ipauniqueid': 'unique identifier' } attribute_order = [ @@ -128,6 +128,10 @@ class user(LDAPObject): cli_name='street', label='Street address', ), + Str('memberof_group?', + label='Groups', + flags=['no_create', 'no_update', 'no_search'], + ), ) api.register(user) -- cgit