relation_add (public)
relation_add [ -form_id form_id ] [ -extra_vars extra_vars ] \ [ -variable_prefix variable_prefix ] \ [ -creation_user creation_user ] [ -creation_ip creation_ip ] \ [ -member_state member_state ] rel_type object_id_one \ object_id_two
Defined in packages/acs-subsite/tcl/relation-procs.tcl
Creates a new relation of the specified type between the two objects. Throws an error if the new relation violates a relational constraint.
- Switches:
- -form_id (optional)
- The form id from templating form system
- -extra_vars (optional)
- An ns_set of extra variables
- -variable_prefix (optional)
- Only form elements that begin with the specified prefix will be processed.
- -creation_user (optional)
- The user who is creating the relation
- -creation_ip (optional)
- -member_state (optional)
- Only used for membership_relations. See column membership_rels.member_state for more info.
- Parameters:
- rel_type (required)
- object_id_one (required)
- object_id_two (required)
- Returns:
- The
rel_id
of the new relation- Authors:
- Michael Bryzek <mbryzek@arsdigita.com>
- Ben Adida <ben@openforce.net>
- Created:
- 1/5/2001
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- acs_subsite_expose_bug_775, acs_subsite_check_composite_group, acs_subsite_relation_procs, acs_subsite_rel_segment_new