Index: openacs-4/packages/news/tcl/news-apm-callback-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/news/tcl/news-apm-callback-procs.tcl,v diff -u -r1.6 -r1.7 --- openacs-4/packages/news/tcl/news-apm-callback-procs.tcl 15 Aug 2018 16:29:24 -0000 1.6 +++ openacs-4/packages/news/tcl/news-apm-callback-procs.tcl 3 Sep 2024 15:37:39 -0000 1.7 @@ -1,36 +1,36 @@ ad_library { - + APM callbacks for the news package - + @author Dave Bauer (dave@thedesignexperience.org) @creation-date 2005-01-20 @cvs-id $Id$ } namespace eval ::news::install {} -ad_proc -public ::news::install::after_install { +ad_proc -private ::news::install::after_install { } { Setup service contracts - + @author Dave Bauer (dave@thedesignexperience.org) @creation-date 2005-01-20 - - @return - - @error + + @return + + @error } { news::sc::register_news_fts_impl news::install::register_rss news::install::register_notifications } -ad_proc -public ::news::install::register_rss { +ad_proc -private ::news::install::register_rss { } { setup RSS support } { -set spec { + set spec { name "news" aliases { datasource news__rss_datasource @@ -42,36 +42,36 @@ acs_sc::impl::new_from_spec -spec $spec } -ad_proc -public ::news::install::register_notifications { +ad_proc -private ::news::install::register_notifications { } { setup notifications } { db_transaction { - # Create the impl and aliases for a news item - set impl_id [create_news_item_impl] + # Create the impl and aliases for a news item + set impl_id [create_news_item_impl] - # Create the notification type for a news item - set type_id [create_news_item_type $impl_id] + # Create the notification type for a news item + set type_id [create_news_item_type $impl_id] - # Enable the delivery intervals and delivery methods for a news item - enable_intervals_and_methods $type_id - } + # Enable the delivery intervals and delivery methods for a news item + enable_intervals_and_methods $type_id + } } -ad_proc -public ::news::install::after_instantiate { +ad_proc -private ::news::install::after_instantiate { -package_id -node_id } { Setup RSS feed per package instance - + @author Dave Bauer (dave@thedesignexperience.org) @creation-date 2005-01-20 - + @param package_id - @return - - @error + @return + + @error } { set subscr_id [rss_support::add_subscription \ -summary_context_id $package_id \ @@ -101,13 +101,13 @@ 5.2.0d4 5.2.0d5 { # Create the impl and aliases for a news item - set impl_id [create_news_item_impl] + set impl_id [::news::install::create_news_item_impl] # Create the notification type for a news item - set type_id [create_news_item_type $impl_id] + set type_id [::news::install::create_news_item_type $impl_id] # Enable the delivery intervals and delivery methods for a news item - enable_intervals_and_methods $type_id + ::news::install::enable_intervals_and_methods $type_id } } } @@ -120,36 +120,36 @@ @author Stan Kaufman (skaufman@epimetrics.com) @creation-date 2005-08-03 - + @param package_id - @return - - @error + @return + + @error } { news_items_delete [db_list dead_news {}] rss_support::del_subscription -summary_context_id $package_id -owner news -impl_name news } -ad_proc -public create_news_item_impl { +ad_proc -private ::news::install::create_news_item_impl { } { Register the service contract implementation and return the impl_id @return impl_id of the created implementation } { - return [acs_sc::impl::new_from_spec -spec { - name news_item_notif_type - contract_name NotificationType - owner news - aliases { - GetURL news_notification_get_url - ProcessReply news_notification_process_reply - } - }] + return [acs_sc::impl::new_from_spec -spec { + name news_item_notif_type + contract_name NotificationType + owner news + aliases { + GetURL news_notification_get_url + ProcessReply news_notification_process_reply + } + }] } -ad_proc -public create_news_item_type { - impl_id +ad_proc -private ::news::install::create_news_item_type { + impl_id } { Create the notification type for one news item @return the type_id of the created type @@ -161,8 +161,7 @@ -description "Notification of a new news item"] } - -ad_proc -public enable_intervals_and_methods {type_id} { +ad_proc -private ::news::install::enable_intervals_and_methods {type_id} { Enable the intervals and delivery methods of a specific type } { # Enable the various intervals and delivery method