Index: openacs-4/packages/acs-subsite/www/admin/groups/elements-by-group-type.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/www/admin/groups/elements-by-group-type.tcl,v diff -u -N -r1.3 -r1.4 --- openacs-4/packages/acs-subsite/www/admin/groups/elements-by-group-type.tcl 25 Apr 2018 08:40:23 -0000 1.3 +++ openacs-4/packages/acs-subsite/www/admin/groups/elements-by-group-type.tcl 28 Nov 2018 11:36:52 -0000 1.4 @@ -1,32 +1,36 @@ -# /packages/subsite/www/admin/groups/elements-by-rel-type.tcl -# -# Datasource for elements-by-rel-type.adp -# (meant to be included by other templates) -# -# Shows the user a summary of components (NOT members!) of the given -# group, provided that the user has permission to see the component. -# The components are summarized by their relationship to the given -# group. -# -# NOTE: -# There is no scope check done here to ensure that the component "belongs" to -# the subsite. The pages that use this template already check that the -# given group_id is in scope; therefore, all of its components must be in -# scope. And even if a developer screws up and uses this template without -# checking that the give group_id belongs to the current subsite, the user -# would only be able to see components that they have permission to see. -# Thus we take the lazy (and efficient) approach of not checking the -# scope of the components returned by this datasource. -# -# Params: group_id -# -# @author oumi@arsdigita.com -# @creation-date 2001-2-6 -# @cvs-id $Id$ +ad_include_contract { -# Select out group types that have at least one group. Count up the -# number of groups to decide later if we display them all + /packages/subsite/www/admin/groups/elements-by-rel-type.tcl + Datasource for elements-by-rel-type.adp + (meant to be included by other templates) + + Shows the user a summary of components (NOT members!) of the given + group, provided that the user has permission to see the component. + The components are summarized by their relationship to the given + group. + + NOTE: + There is no scope check done here to ensure that the component "belongs" to + the subsite. The pages that use this template already check that the + given group_id is in scope; therefore, all of its components must be in + scope. And even if a developer screws up and uses this template without + checking that the give group_id belongs to the current subsite, the user + would only be able to see components that they have permission to see. + Thus we take the lazy (and efficient) approach of not checking the + scope of the components returned by this datasource. + + @author oumi@arsdigita.com + @creation-date 2001-2-6 + @cvs-id $Id$ + + Select out group types that have at least one group. Count up the + number of groups to decide later if we display them all + +} { + group_id:integer +} + set user_id [ad_conn user_id] set package_id [ad_conn package_id]