application_group::contains_segment_p (public)
application_group::contains_segment_p [ -package_id package_id ] \ [ -segment_id segment_id ]
Defined in packages/acs-subsite/tcl/application-group-procs.tcl
Determines whether the segment in question (identified by segment_id) "belongs" to the application group identified by package_id. If package_id is not specified, and we have a connection, then the proc will grab the package_id of the current package (i.e., [ad_conn package_id]).
- Switches:
- -package_id (optional)
- -segment_id (optional)
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: if {$package_id eq "" && [ns_conn isconnected]} { set package_id [ad_conn package_id] } if {$package_id eq ""} { error "application_group::contains_segment_p - package_id not specified" } # Check if the party is a member of the application group, OR # the party *is* the application group. This proc considers the # application group to contain itself. set found_p [db_string app_group_contains_segment_p { select case when exists ( select 1 from application_group_segments where package_id = :package_id and segment_id = :segment_id ) then 1 else 0 end from dual }] return $found_pXQL Not present: Generic PostgreSQL XQL file: packages/acs-subsite/tcl/application-group-procs-postgresql.xql
Oracle XQL file: packages/acs-subsite/tcl/application-group-procs-oracle.xql