• Publicity: Public Only All

group-procs.tcl

Procs to manage groups

Location:
packages/acs-subsite/tcl/group-procs.tcl
Created:
Thu Dec 7 18:13:56 2000
Author:
mbryzek@arsdigita.com
CVS Identification:
$Id: group-procs.tcl,v 1.60.2.18 2024/08/07 15:36:22 mischa Exp $

Procedures in this file

Detailed information

group::add_member (public)

 group::add_member [ -no_perm_check ] [ -no_automatic_membership_rel ] \
    -group_id group_id -user_id user_id [ -rel_type rel_type ] \
    [ -member_state member_state ]

Adds a user to a group, checking that the rel_type is permissible given the user's privileges, Can default both the rel_type and the member_state to their relevant values.

Switches:
-no_perm_check (optional, boolean)
avoid permission check
-no_automatic_membership_rel (optional, boolean)
Use this flag, when we do not want to add automatically a membership_rel (e.g. in DotLRN)
-group_id (required)
group, to which a member should be added
-user_id (required)
user, which should be added to a group
-rel_type (optional)
relationship type to be used (defaults to membership_rel)
-member_state (optional)
state, in which member should be added (gets default via group::default_member_state)

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_check_composite_group acs_subsite_check_composite_group (test acs-subsite) group::add_member group::add_member test_acs_subsite_check_composite_group->group::add_member test_acs_subsite_expose_bug_1144 acs_subsite_expose_bug_1144 (test acs-subsite) test_acs_subsite_expose_bug_1144->group::add_member test_subsite_api subsite_api (test acs-subsite) test_subsite_api->group::add_member test_test_inheritance_and_custom_permissions test_inheritance_and_custom_permissions (test acs-tcl) test_test_inheritance_and_custom_permissions->group::add_member group::default_member_state group::default_member_state (public) group::add_member->group::default_member_state group::flush_members_cache group::flush_members_cache (private) group::add_member->group::flush_members_cache group::get group::get (public) group::add_member->group::get permission::cache_flush permission::cache_flush (public) group::add_member->permission::cache_flush permission::permission_p permission::permission_p (public) group::add_member->permission::permission_p install::xml::action::add-subsite-admin install::xml::action::add-subsite-admin (public) install::xml::action::add-subsite-admin->group::add_member install::xml::action::add-subsite-member install::xml::action::add-subsite-member (public) install::xml::action::add-subsite-member->group::add_member membership_rel::change_state membership_rel::change_state (public) membership_rel::change_state->group::add_member packages/acs-subsite/lib/user-new.tcl packages/acs-subsite/ lib/user-new.tcl packages/acs-subsite/lib/user-new.tcl->group::add_member packages/acs-subsite/www/admin/relations/add.tcl packages/acs-subsite/ www/admin/relations/add.tcl packages/acs-subsite/www/admin/relations/add.tcl->group::add_member

Testcases:
acs_subsite_expose_bug_1144, acs_subsite_check_composite_group, subsite_api, test_inheritance_and_custom_permissions

group::admin_p (public)

 group::admin_p -group_id group_id -user_id user_id
Switches:
-group_id (required)
-user_id (required)
Returns:
1 if user_id is in the admin_rel for group_id

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_check_composite_group acs_subsite_check_composite_group (test acs-subsite) group::admin_p group::admin_p test_acs_subsite_check_composite_group->group::admin_p relation::get_id relation::get_id (public) group::admin_p->relation::get_id packages/acs-subsite/www/index.tcl packages/acs-subsite/ www/index.tcl packages/acs-subsite/www/index.tcl->group::admin_p

Testcases:
acs_subsite_check_composite_group

group::default_member_state (public)

 group::default_member_state [ -join_policy join_policy ] \
    [ -create_p create_p ] [ -no_complain ]

If user has 'create' privilege on group_id OR the group's join policy is 'open', then default_member_state will return "approved". If the group's join policy is 'needs approval' then default_member_state will return 'needs approval'. If the group's join policy is closed then an error will be thrown, unless the no_complain flag is set, in which case empty string is returned.

Switches:
-join_policy (optional)
- the group's join policy (one of 'open', 'closed', or 'needs approval')
-create_p (optional, defaults to "false")
- 1 if the user has 'create' privilege on the group, 0 otherwise.
-no_complain (optional, boolean)
Author:
Oumi Mehrotra <oumi@arsdigita.com>
Created:
10/2000

Partial Call Graph (max 5 caller/called nodes):
%3 group::add_member group::add_member (public) group::default_member_state group::default_member_state group::add_member->group::default_member_state packages/acs-subsite/www/admin/groups/new.tcl packages/acs-subsite/ www/admin/groups/new.tcl packages/acs-subsite/www/admin/groups/new.tcl->group::default_member_state packages/acs-subsite/www/admin/parties/new.tcl packages/acs-subsite/ www/admin/parties/new.tcl packages/acs-subsite/www/admin/parties/new.tcl->group::default_member_state packages/acs-subsite/www/admin/users/new.tcl packages/acs-subsite/ www/admin/users/new.tcl packages/acs-subsite/www/admin/users/new.tcl->group::default_member_state packages/acs-subsite/www/group-join.tcl packages/acs-subsite/ www/group-join.tcl packages/acs-subsite/www/group-join.tcl->group::default_member_state

Testcases:
No testcase defined.

group::delete (public)

 group::delete group_id

Deletes the group specified by group_id, including all relational segments specified for the group and any relational constraint that depends on this group in any way.

Parameters:
group_id (required)
The group to delete
Returns:
object_type of the deleted group, if it was actually deleted. Returns the empty string if the object didn't exist to begin with
Author:
Michael Bryzek <mbryzek@arsdigita.com>
Created:
10/2000

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_expose_bug_775 acs_subsite_expose_bug_775 (test acs-subsite) group::delete group::delete test_acs_subsite_expose_bug_775->group::delete test_group_localization group_localization (test acs-subsite) test_group_localization->group::delete db_0or1row db_0or1row (public) group::delete->db_0or1row db_exec_plsql db_exec_plsql (public) group::delete->db_exec_plsql lang::message::unregister lang::message::unregister (public) group::delete->lang::message::unregister group_type::delete group_type::delete (public) group_type::delete->group::delete packages/acs-subsite/www/admin/groups/delete-2.tcl packages/acs-subsite/ www/admin/groups/delete-2.tcl packages/acs-subsite/www/admin/groups/delete-2.tcl->group::delete

Testcases:
group_localization, acs_subsite_expose_bug_775

group::description (public)

 group::description -group_id group_id

Returns a group's description

Switches:
-group_id (required)
Created:
09/2008

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_group_type acs_subsite_group_type (test acs-subsite) group::description group::description test_acs_subsite_group_type->group::description group::get group::get (public) group::description->group::get packages/acs-subsite/www/admin/configure.tcl packages/acs-subsite/ www/admin/configure.tcl packages/acs-subsite/www/admin/configure.tcl->group::description

Testcases:
acs_subsite_group_type

group::get (public)

 group::get -group_id group_id [ -array array ]

Get basic info about a group: group_name, join_policy.

Switches:
-group_id (required)
-array (optional)
The name of an array in the caller's namespace where the info gets delivered.
Returns:
dict containing group_name, title, join_policy, and description
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_group_type acs_subsite_group_type (test acs-subsite) group::get group::get test_acs_subsite_group_type->group::get group::get_not_cached group::get_not_cached (private) group::get->group::get_not_cached group::add_member group::add_member (public) group::add_member->group::get group::description group::description (public) group::description->group::get group::get_element group::get_element (public) group::get_element->group::get group::join_policy group::join_policy (public) group::join_policy->group::get packages/acs-subsite/www/admin/relations/add.tcl packages/acs-subsite/ www/admin/relations/add.tcl packages/acs-subsite/www/admin/relations/add.tcl->group::get

Testcases:
acs_subsite_group_type

group::get_element (public)

 group::get_element -group_id group_id -element element

Get an element from the basic info about a group: group_name, join_policy.

Switches:
-group_id (required)
-element (required)
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) group::get_element group::get_element test_subsite_api->group::get_element group::get group::get (public) group::get_element->group::get group::title group::title (public) group::title->group::get_element packages/acs-authentication/lib/local-search.tcl packages/acs-authentication/ lib/local-search.tcl packages/acs-authentication/lib/local-search.tcl->group::get_element packages/acs-subsite/www/admin/groups/delete.tcl packages/acs-subsite/ www/admin/groups/delete.tcl packages/acs-subsite/www/admin/groups/delete.tcl->group::get_element packages/acs-subsite/www/admin/rel-segments/new-2.tcl packages/acs-subsite/ www/admin/rel-segments/new-2.tcl packages/acs-subsite/www/admin/rel-segments/new-2.tcl->group::get_element

Testcases:
subsite_api

group::get_id (public)

 group::get_id -group_name group_name [ -subsite_id subsite_id ] \
    [ -application_group_id application_group_id ]

Retrieve the group_id to a given group-name. If you have more than one group with this name, it will return the first one it finds. Keep that in mind when using this procedure.

Switches:
-group_name (required)
the name of the group to look for
-subsite_id (optional)
the ID of the subsite to search for the group name
-application_group_id (optional)
the ID of the application group to search for the group name
Returns:
the first group_id of the groups found for that group_name.
Authors:
Christian Langmann <C_Langmann@gmx.de>
Malte Sussdorff <openacs@sussdorff.de>
Created:
2005-06-09

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_group_type acs_subsite_group_type (test acs-subsite) group::get_id group::get_id test_acs_subsite_group_type->group::get_id group::get_id_not_cached group::get_id_not_cached (private) group::get_id->group::get_id_not_cached util_memoize util_memoize (public) group::get_id->util_memoize group::member_p group::member_p (public) group::member_p->group::get_id group::party_member_p group::party_member_p (public) group::party_member_p->group::get_id group::title group::title (public) group::title->group::get_id

Testcases:
acs_subsite_group_type

group::get_join_policy_options (public)

 group::get_join_policy_options

Returns a list of valid join policies in a format suitable for a form builder drop-down.

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) group::get_join_policy_options group::get_join_policy_options test_subsite_api->group::get_join_policy_options _ _ (public) group::get_join_policy_options->_ packages/acs-subsite/www/admin/configure.tcl packages/acs-subsite/ www/admin/configure.tcl packages/acs-subsite/www/admin/configure.tcl->group::get_join_policy_options packages/acs-subsite/www/admin/subsite-add.tcl packages/acs-subsite/ www/admin/subsite-add.tcl packages/acs-subsite/www/admin/subsite-add.tcl->group::get_join_policy_options

Testcases:
subsite_api

group::get_member_state_pretty (public)

 group::get_member_state_pretty -member_state member_state \
    [ -component component ] [ -user_name user_name ] \
    [ -community_name community_name ] [ -site_name site_name ] \
    [ -url url ] [ -locale locale ]

Returns the pretty-name of a member state.

Switches:
-member_state (required)
-component (optional, defaults to "pretty_name")
-user_name (optional)
-community_name (optional)
-site_name (optional)
-url (optional)
-locale (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-admin/www/users/member-state-change.tcl packages/acs-admin/ www/users/member-state-change.tcl group::get_member_state_pretty group::get_member_state_pretty packages/acs-admin/www/users/member-state-change.tcl->group::get_member_state_pretty packages/acs-subsite/lib/user-subsites.tcl packages/acs-subsite/ lib/user-subsites.tcl packages/acs-subsite/lib/user-subsites.tcl->group::get_member_state_pretty packages/acs-subsite/www/members/index.tcl packages/acs-subsite/ www/members/index.tcl packages/acs-subsite/www/members/index.tcl->group::get_member_state_pretty packages/acs-subsite/www/members/member-state-change.tcl packages/acs-subsite/ www/members/member-state-change.tcl packages/acs-subsite/www/members/member-state-change.tcl->group::get_member_state_pretty lang::util::localize lang::util::localize (public) group::get_member_state_pretty->lang::util::localize

Testcases:
No testcase defined.

group::get_members (public)

 group::get_members -group_id group_id [ -type type ] \
    [ -rel_type rel_type ] [ -member_state member_state ]

Get party_ids of all members from cache.

Switches:
-group_id (required)
-type (optional, defaults to "party")
Type of members - party, person, user
-rel_type (optional)
-member_state (optional)
when specified, return only members in this membership state
Author:
Timo Hentschel <timo@timohentschel.de>
Created:
2005-07-26
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) group::get_members group::get_members test_subsite_api->group::get_members group::get_members_not_cached group::get_members_not_cached (private) group::get_members->group::get_members_not_cached packages/forums/www/admin/subscribe-others.tcl packages/forums/ www/admin/subscribe-others.tcl packages/forums/www/admin/subscribe-others.tcl->group::get_members

Testcases:
subsite_api

group::get_rel_segment (public)

 group::get_rel_segment -group_id group_id -type type

Get a segment for a particular relation type for a given group.

Switches:
-group_id (required)
-type (required)

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_rel_segment_new acs_subsite_rel_segment_new (test acs-subsite) group::get_rel_segment group::get_rel_segment test_acs_subsite_rel_segment_new->group::get_rel_segment test_test_inheritance_and_custom_permissions test_inheritance_and_custom_permissions (test acs-tcl) test_test_inheritance_and_custom_permissions->group::get_rel_segment db_string db_string (public) group::get_rel_segment->db_string install::xml::object_id::application-group install::xml::object_id::application-group (public) install::xml::object_id::application-group->group::get_rel_segment install::xml::object_id::group install::xml::object_id::group (public) install::xml::object_id::group->group::get_rel_segment packages/acs-subsite/www/permissions/toggle-inherit.tcl packages/acs-subsite/ www/permissions/toggle-inherit.tcl packages/acs-subsite/www/permissions/toggle-inherit.tcl->group::get_rel_segment

Testcases:
acs_subsite_rel_segment_new, test_inheritance_and_custom_permissions

group::get_rel_types_options (public)

 group::get_rel_types_options -group_id group_id \
    [ -object_type object_type ]

Get the valid relationship-types for this group in a format suitable for a select widget in the form builder. The label used is the name of the role for object two.

Switches:
-group_id (required)
The ID of the group for which to get options.
-object_type (optional, defaults to "person")
The object type which must occupy side two of the relationship. Typically 'person' or 'group'.
Returns:
a list of lists with label (role two pretty name) and ID (rel_type)

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/lib/user-new.tcl packages/acs-subsite/ lib/user-new.tcl group::get_rel_types_options group::get_rel_types_options packages/acs-subsite/lib/user-new.tcl->group::get_rel_types_options packages/acs-subsite/www/members/member-invite.tcl packages/acs-subsite/ www/members/member-invite.tcl packages/acs-subsite/www/members/member-invite.tcl->group::get_rel_types_options db_foreach db_foreach (public) group::get_rel_types_options->db_foreach lang::util::localize lang::util::localize (public) group::get_rel_types_options->lang::util::localize

Testcases:
No testcase defined.

group::join_policy (public)

 group::join_policy -group_id group_id

Returns a group's join policy ('open', 'closed', or 'needs approval')

Switches:
-group_id (required)
Author:
Oumi Mehrotra <oumi@arsdigita.com>
Created:
10/2000

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) group::join_policy group::join_policy test_subsite_api->group::join_policy group::get group::get (public) group::join_policy->group::get packages/acs-subsite/www/admin/configure.tcl packages/acs-subsite/ www/admin/configure.tcl packages/acs-subsite/www/admin/configure.tcl->group::join_policy packages/acs-subsite/www/group-join.tcl packages/acs-subsite/ www/group-join.tcl packages/acs-subsite/www/group-join.tcl->group::join_policy packages/acs-subsite/www/index.tcl packages/acs-subsite/ www/index.tcl packages/acs-subsite/www/index.tcl->group::join_policy

Testcases:
subsite_api

group::member_p (public)

 group::member_p [ -user_id user_id ] [ -group_name group_name ] \
    [ -group_id group_id ] [ -subsite_id subsite_id ] [ -cascade ]

Return 1 if the user is a member of the group specified. You can specify a group name or group id. If there is more than one group with this name, it will use the first one. If cascade is true, check to see if the user is a member of the group by virtue of any other component group. (e.g. if group B is a component of group A then if a user is a member of group B then he is automatically a member of A also.) If cascade is false, then the user must have specifically been granted membership on the group in question.

Switches:
-user_id (optional)
-group_name (optional)
-group_id (optional)
-subsite_id (optional)
Only useful when using group_name. Marks the subsite in which to search for the group_id that belongs to the group_name
-cascade (optional, boolean)
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_check_composite_group acs_subsite_check_composite_group (test acs-subsite) group::member_p group::member_p test_acs_subsite_check_composite_group->group::member_p ad_conn ad_conn (public) group::member_p->ad_conn ad_log ad_log (public) group::member_p->ad_log group::get_id group::get_id (public) group::member_p->group::get_id group::member_p_not_cached group::member_p_not_cached (private) group::member_p->group::member_p_not_cached packages/acs-authentication/lib/local-search.tcl packages/acs-authentication/ lib/local-search.tcl packages/acs-authentication/lib/local-search.tcl->group::member_p packages/acs-subsite/www/group-join.tcl packages/acs-subsite/ www/group-join.tcl packages/acs-subsite/www/group-join.tcl->group::member_p packages/acs-subsite/www/group-leave.tcl packages/acs-subsite/ www/group-leave.tcl packages/acs-subsite/www/group-leave.tcl->group::member_p packages/acs-subsite/www/index.tcl packages/acs-subsite/ www/index.tcl packages/acs-subsite/www/index.tcl->group::member_p packages/acs-subsite/www/members/member-invite.tcl packages/acs-subsite/ www/members/member-invite.tcl packages/acs-subsite/www/members/member-invite.tcl->group::member_p

Testcases:
acs_subsite_check_composite_group

group::new (public)

 group::new [ -form_id form_id ] [ -variable_prefix variable_prefix ] \
    [ -creation_user creation_user ] [ -creation_ip creation_ip ] \
    [ -group_id group_id ] [ -context_id context_id ] \
    [ -group_name group_name ] [ -pretty_name pretty_name ] \
    [ group_type ]

Creates a group of this type by calling the .new function for the package associated with the given group_type. This function will fail if there is no package.

There are now several ways to create a group of a given type. You can use this Tcl API with or without a form from the form system, or you can directly use the PL/SQL API for the group type.

Examples:


    # OPTION 1: Create the group using the Tcl Procedure. Useful if the
    # only attribute you need to specify is the group name

    db_transaction {
        set group_id [group::new -group_name "Author" $group_type]
    }


    # OPTION 2: Create the group using the Tcl API with a templating
    # form. Useful when there are multiple attributes to specify for the
    # group

    template::form create add_group
    template::element create add_group group_name -value "Publisher"

    db_transaction {
        set group_id [group::new -form_id add_group $group_type ]
    }

    # OPTION 3: Create the group using the PL/SQL package automatically
    # created for it

    # creating the new group
    set group_id [db_exec_plsql add_group "
      begin
        :1 := ${group_type}.new (group_name => 'Editor');
      end;
    "]

    

Switches:
-form_id (optional)
The form id from templating form system (see example above)
-variable_prefix (optional)
-creation_user (optional)
-creation_ip (optional)
-group_id (optional)
-context_id (optional)
-group_name (optional)
The name of this group. This is a required variable, though it may be specified either explicitly or through form_id
-pretty_name (optional)
Parameters:
group_type (optional, defaults to "group")
The type of group we are creating. Defaults to group which is what you want in most cases.
Returns:
group_id of the newly created group
Author:
Michael Bryzek <mbryzek@arsdigita.com>
Created:
10/2000

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_check_composite_group acs_subsite_check_composite_group (test acs-subsite) group::new group::new test_acs_subsite_check_composite_group->group::new test_acs_subsite_expose_bug_775 acs_subsite_expose_bug_775 (test acs-subsite) test_acs_subsite_expose_bug_775->group::new test_acs_subsite_group_type acs_subsite_group_type (test acs-subsite) test_acs_subsite_group_type->group::new test_acs_subsite_rel_segment_new acs_subsite_rel_segment_new (test acs-subsite) test_acs_subsite_rel_segment_new->group::new test_group_localization group_localization (test acs-subsite) test_group_localization->group::new db_0or1row db_0or1row (public) group::new->db_0or1row db_dml db_dml (public) group::new->db_dml lang::util::convert_to_i18n lang::util::convert_to_i18n (public) group::new->lang::util::convert_to_i18n lang::util::message_key_regexp lang::util::message_key_regexp (public) group::new->lang::util::message_key_regexp package_instantiate_object package_instantiate_object (public) group::new->package_instantiate_object packages/acs-subsite/www/admin/groups/new.tcl packages/acs-subsite/ www/admin/groups/new.tcl packages/acs-subsite/www/admin/groups/new.tcl->group::new

Testcases:
group_localization, acs_subsite_expose_bug_775, acs_subsite_check_composite_group, acs_subsite_group_type, acs_subsite_rel_segment_new

group::party_member_p (public)

 group::party_member_p [ -party_id party_id ] [ -group_id group_id ] \
    [ -group_name group_name ] [ -subsite_id subsite_id ]

Return 1 if the party is an approved member of the group specified. One can specify a group_id (preferred) or a group name. Note: The group name is not unique by definition, and if you call this function with a duplicate group name it will return the first one (arbitrary)!!! Using the group name as a parameter is thus strongly discouraged unless you are really, really sure the name is unique.

The party must have specifically been granted membership on the group in question.

Switches:
-party_id (optional)
-group_id (optional)
-group_name (optional)
-subsite_id (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) group::party_member_p group::party_member_p test_subsite_api->group::party_member_p ad_log ad_log (public) group::party_member_p->ad_log db_0or1row db_0or1row (public) group::party_member_p->db_0or1row group::get_id group::get_id (public) group::party_member_p->group::get_id packages/acs-subsite/www/members/index.tcl packages/acs-subsite/ www/members/index.tcl packages/acs-subsite/www/members/index.tcl->group::party_member_p

Testcases:
subsite_api

group::permission_p (public, deprecated)

 group::permission_p [ -user_id user_id ] [ -privilege privilege ] \
    group_id
Deprecated. Invoking this procedure generates a warning.

THIS PROC SHOULD GO AWAY! All calls to group::permission_p can be replaced with permission::permission_p Wrapper for ad_permission to allow us to bypass having to specify the read privilege

Switches:
-user_id (optional)
-privilege (optional, defaults to "read")
Parameters:
group_id (required)
Author:
Michael Bryzek <mbryzek@arsdigita.com>
Created:
10/2000
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 ad_log_deprecated ad_log_deprecated (public) permission::permission_p permission::permission_p (public) group::permission_p group::permission_p group::permission_p->ad_log_deprecated group::permission_p->permission::permission_p

Testcases:
No testcase defined.

group::possible_member_states (public)

 group::possible_member_states

Returns the list of possible member states: approved, needs approval, banned, merged, rejected, deleted.

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/admin/groups/elements-display-list.tcl packages/acs-subsite/ www/admin/groups/elements-display-list.tcl group::possible_member_states group::possible_member_states packages/acs-subsite/www/admin/groups/elements-display-list.tcl->group::possible_member_states packages/acs-subsite/www/admin/relations/one.tcl packages/acs-subsite/ www/admin/relations/one.tcl packages/acs-subsite/www/admin/relations/one.tcl->group::possible_member_states packages/acs-subsite/www/members/index.tcl packages/acs-subsite/ www/members/index.tcl packages/acs-subsite/www/members/index.tcl->group::possible_member_states

Testcases:
No testcase defined.

group::remove_member (public)

 group::remove_member -group_id group_id -user_id user_id

Removes a user from a group. No permission checking.

Switches:
-group_id (required)
-user_id (required)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) group::remove_member group::remove_member test_subsite_api->group::remove_member db_list db_list (public) group::remove_member->db_list db_transaction db_transaction (public) group::remove_member->db_transaction group::flush_members_cache group::flush_members_cache (private) group::remove_member->group::flush_members_cache relation_remove relation_remove (public) group::remove_member->relation_remove membership_rel::change_state membership_rel::change_state (public) membership_rel::change_state->group::remove_member packages/acs-subsite/www/members/member-remove.tcl packages/acs-subsite/ www/members/member-remove.tcl packages/acs-subsite/www/members/member-remove.tcl->group::remove_member

Testcases:
subsite_api

group::title (public)

 group::title [ -group_name group_name ] [ -group_id group_id ]

Get the title of a group based either on group_name or on the group_id.

Switches:
-group_name (optional)
The name of the group. Note this is not the I18N title we want to retrieve with this procedure
-group_id (optional)
The group_id of the group

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_group_type acs_subsite_group_type (test acs-subsite) group::title group::title test_acs_subsite_group_type->group::title group::get_element group::get_element (public) group::title->group::get_element group::get_id group::get_id (public) group::title->group::get_id

Testcases:
acs_subsite_group_type

group::update (public)

 group::update -group_id group_id [ -array array ] [ dict ]

Updates a group.The updated values can be either specified as dict or as array. Valid columns are group_name, join_policy and description. Valid join_policy values are 'open', 'closed', 'needs approval'.

Switches:
-group_id (required)
The ID of the group to update.
-array (optional)
Name of array containing the columns to update.
Parameters:
dict (optional)
dict for columns to update.

Partial Call Graph (max 5 caller/called nodes):
%3 install::xml::action::set-join-policy install::xml::action::set-join-policy (public) group::update group::update install::xml::action::set-join-policy->group::update packages/acs-subsite/www/admin/configure.tcl packages/acs-subsite/ www/admin/configure.tcl packages/acs-subsite/www/admin/configure.tcl->group::update packages/acs-subsite/www/admin/subsite-add.tcl packages/acs-subsite/ www/admin/subsite-add.tcl packages/acs-subsite/www/admin/subsite-add.tcl->group::update db_dml db_dml (public) group::update->db_dml lang::util::convert_to_i18n lang::util::convert_to_i18n (public) group::update->lang::util::convert_to_i18n

Testcases:
No testcase defined.
[ show source ]