auth::get_registration_elements (public)
auth::get_registration_elements
Defined in packages/acs-authentication/tcl/authentication-procs.tcl
Get the list of required/optional elements for user registration.
- Returns:
- Array-list with two entries
- required: a list of required elements
- optional: a list of optional elements
- See Also:
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- auth_get_registration_elements, auth_use_email_for_login_p
Source code: set authority_id [auth::get_register_authority] array set element_info [auth::registration::GetElements -authority_id $authority_id] if { ![info exists element_info(required)] } { set element_info(required) {} } if { ![info exists element_info(optional)] } { set element_info(optional) {} } set local_required_elms { first_names last_name email } set local_optional_elms {} switch [acs_user::ScreenName] { require { lappend local_required_elms "screen_name" } solicit { lappend local_optional_elms "screen_name" } } # Handle required elements for local account foreach elm $local_required_elms { # Add to required if { $elm ni $element_info(required) } { lappend element_info(required) $elm } # Remove from optional set index [lsearch $element_info(optional) $elm] if { $index != -1 } { set element_info(optional) [lreplace $element_info(optional) $index $index] } } foreach elm $local_optional_elms { # Add to required if { $elm ni $element_info(required) && $elm ni $element_info(optional) } { lappend element_info(optional) $elm } } return [array get element_info]Generic XQL file: packages/acs-authentication/tcl/authentication-procs.xql
PostgreSQL XQL file: packages/acs-authentication/tcl/authentication-procs-postgresql.xql
Oracle XQL file: packages/acs-authentication/tcl/authentication-procs-oracle.xql