Index: openacs-4/packages/dotlrn-calendar/tcl/dotlrn-calendar-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn-calendar/tcl/dotlrn-calendar-procs.tcl,v diff -u -r1.27 -r1.28 --- openacs-4/packages/dotlrn-calendar/tcl/dotlrn-calendar-procs.tcl 18 Feb 2002 16:10:28 -0000 1.27 +++ openacs-4/packages/dotlrn-calendar/tcl/dotlrn-calendar-procs.tcl 20 Feb 2002 20:20:09 -0000 1.28 @@ -269,5 +269,29 @@ calendar_full_portlet::remove_self_from_page $workspace_portal_id $package_id } } - + + # + # Some dotlrn_calendar specific procs + # + + ad_proc -public get_group_calendar_id { + {-community_id:required} + } { + Find the group_calendar_id for the given community + } { + + # get the portal_template_id for this comm + set portal_template_id [dotlrn_community::get_portal_template_id $community_id] + + # get the calendar element for this community + set element_id [portal::get_element_ids_by_ds \ + $portal_template_id \ + [calendar_portlet::my_name]] + + # [lindex element_ids 0] + return [portal::get_element_param $element_id "group_calendar_id"] + } + + + }