• Publicity: Public Only All

subsite-procs.tcl

Procs to manage application groups

Location:
packages/acs-subsite/tcl/subsite-procs.tcl
Created:
2001-02-01
Author:
oumi@arsdigita.com
CVS Identification:
$Id: subsite-procs.tcl,v 1.68.2.26 2023/02/08 12:35:55 antoniop Exp $

Procedures in this file

Detailed information

subsite::add_section_row (public)

 subsite::add_section_row -array array -base_url base_url \
    -multirow multirow [ -section section ]

Helper proc for adding rows of sections to the page flow of the subsite.

Switches:
-array (required)
-base_url (required)
-multirow (required)
-section (optional)
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 subsite::define_pageflow subsite::define_pageflow (public) subsite::add_section_row subsite::add_section_row subsite::define_pageflow->subsite::add_section_row ad_conn ad_conn (public) subsite::add_section_row->ad_conn ad_file ad_file (public) subsite::add_section_row->ad_file site_node::closest_ancestor_package site_node::closest_ancestor_package (public) subsite::add_section_row->site_node::closest_ancestor_package subsite::package_keys subsite::package_keys (public) subsite::add_section_row->subsite::package_keys template::multirow template::multirow (public) subsite::add_section_row->template::multirow

Testcases:
No testcase defined.

subsite::auto_mount_application (public)

 subsite::auto_mount_application [ -instance_name instance_name ] \
    [ -pretty_name pretty_name ] [ -node_id node_id ] package_key

Mounts a new instance of the application specified by package_key beneath node_id. This proc makes sure that the instance_name (the name of the new node) is unique before invoking site_node::instantiate_and_mount.

Switches:
-instance_name (optional)
The name to use for the url in the site-map. Defaults to the package_key plus a possible digit to serve as a unique identifier (e.g. news-2)
-pretty_name (optional)
The english name to use for the site-map and for things like context bars. Defaults to the name of the object mounted at this node + the package pretty name (e.g. Intranet News)
-node_id (optional)
Defaults to [ad_conn node_id]
Parameters:
package_key (required)
Returns:
The package id of the newly mounted package
Author:
Michael Bryzek <mbryzek@arsdigita.com>
Created:
2001-02-28
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::auto_mount_application subsite::auto_mount_application test_subsite_api->subsite::auto_mount_application acs_object_name acs_object_name (public) subsite::auto_mount_application->acs_object_name ad_conn ad_conn (public) subsite::auto_mount_application->ad_conn db_string db_string (public) subsite::auto_mount_application->db_string site_node::get_from_node_id site_node::get_from_node_id (public) subsite::auto_mount_application->site_node::get_from_node_id site_node::instantiate_and_mount site_node::instantiate_and_mount (public) subsite::auto_mount_application->site_node::instantiate_and_mount packages/acs-subsite/www/admin/site-map/auto-mount.tcl packages/acs-subsite/ www/admin/site-map/auto-mount.tcl packages/acs-subsite/www/admin/site-map/auto-mount.tcl->subsite::auto_mount_application packages/edit-this-page/www/etp-create-extlink.tcl packages/edit-this-page/ www/etp-create-extlink.tcl packages/edit-this-page/www/etp-create-extlink.tcl->subsite::auto_mount_application packages/edit-this-page/www/etp-subtopic-create.tcl packages/edit-this-page/ www/etp-subtopic-create.tcl packages/edit-this-page/www/etp-subtopic-create.tcl->subsite::auto_mount_application

Testcases:
subsite_api

subsite::default::create_app_group (public)

 subsite::default::create_app_group [ -package_id package_id ] \
    [ -name name ]

Create the default application group for a subsite.

  • Create application group
  • Create segment "Subsite Users"
  • Create relational constraint to make subsite registration require supersite registration.

Switches:
-package_id (optional)
-name (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 subsite::after_mount subsite::after_mount (private) subsite::default::create_app_group subsite::default::create_app_group subsite::after_mount->subsite::default::create_app_group ad_conn ad_conn (public) subsite::default::create_app_group->ad_conn application_group::group_id_from_package_id application_group::group_id_from_package_id (public) subsite::default::create_app_group->application_group::group_id_from_package_id application_group::new application_group::new (public) subsite::default::create_app_group->application_group::new db_exec_plsql db_exec_plsql (public) subsite::default::create_app_group->db_exec_plsql db_transaction db_transaction (public) subsite::default::create_app_group->db_transaction

Testcases:
No testcase defined.

subsite::default::delete_app_group (public)

 subsite::default::delete_app_group [ -package_id package_id ]

Delete the default application group for a subsite.

Switches:
-package_id (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 subsite::before_uninstantiate subsite::before_uninstantiate (private) subsite::default::delete_app_group subsite::default::delete_app_group subsite::before_uninstantiate->subsite::default::delete_app_group application_group::delete application_group::delete (public) subsite::default::delete_app_group->application_group::delete application_group::group_id_from_package_id application_group::group_id_from_package_id (public) subsite::default::delete_app_group->application_group::group_id_from_package_id

Testcases:
No testcase defined.

subsite::define_pageflow (public)

 subsite::define_pageflow [ -sections_multirow sections_multirow ] \
    [ -subsections_multirow subsections_multirow ] \
    [ -section section ] [ -url url ]

Defines the page flow of the subsite TODO: add an image TODO: add link_p/selected_p for subsections

Switches:
-sections_multirow (optional, defaults to "sections")
-subsections_multirow (optional, defaults to "subsections")
-section (optional)
-url (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/group-master.tcl packages/acs-subsite/ www/group-master.tcl subsite::define_pageflow subsite::define_pageflow packages/acs-subsite/www/group-master.tcl->subsite::define_pageflow ad_file ad_file (public) subsite::define_pageflow->ad_file subsite::add_section_row subsite::add_section_row (public) subsite::define_pageflow->subsite::add_section_row subsite::get_element subsite::get_element (public) subsite::define_pageflow->subsite::get_element subsite::get_pageflow_struct subsite::get_pageflow_struct (public) subsite::define_pageflow->subsite::get_pageflow_struct template::multirow template::multirow (public) subsite::define_pageflow->template::multirow

Testcases:
No testcase defined.

subsite::delete_subsite_theme (public)

 subsite::delete_subsite_theme -key key

Delete a subsite theme, making it unavailable to the theme configuration code.

Switches:
-key (required)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::delete_subsite_theme subsite::delete_subsite_theme test_subsite_api->subsite::delete_subsite_theme db_dml db_dml (public) subsite::delete_subsite_theme->db_dml openacs_bootstrap3_theme::apm::before_uninstall openacs_bootstrap3_theme::apm::before_uninstall (private) openacs_bootstrap3_theme::apm::before_uninstall->subsite::delete_subsite_theme openacs_bootstrap5_theme::apm::before_uninstall openacs_bootstrap5_theme::apm::before_uninstall (private) openacs_bootstrap5_theme::apm::before_uninstall->subsite::delete_subsite_theme packages/acs-subsite/www/admin/themes/delete.tcl packages/acs-subsite/ www/admin/themes/delete.tcl packages/acs-subsite/www/admin/themes/delete.tcl->subsite::delete_subsite_theme

Testcases:
subsite_api

subsite::get (public)

 subsite::get [ -subsite_id subsite_id ] [ -array array ]

Get information about a subsite.

Switches:
-subsite_id (optional)
The id of the subsite for which info is requested. If no id is provided, then the id of the closest ancestor subsite will be used.
-array (optional)
The name of an array in which information will be returned.
Returns:
dict with subsite attributed
Author:
Frank Nikolajsen <frank@warpspace.com>
Created:
2003-03-08

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::get subsite::get test_subsite_api->subsite::get ad_conn ad_conn (public) subsite::get->ad_conn site_node::get_from_object_id site_node::get_from_object_id (public) subsite::get->site_node::get_from_object_id packages/acs-subsite/www/members/index.tcl packages/acs-subsite/ www/members/index.tcl packages/acs-subsite/www/members/index.tcl->subsite::get subsite::default::create_app_group subsite::default::create_app_group (public) subsite::default::create_app_group->subsite::get subsite::get_element subsite::get_element (public) subsite::get_element->subsite::get

Testcases:
subsite_api

subsite::get_application_options (public)

 subsite::get_application_options

Gets options list for applications to install

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::get_application_options subsite::get_application_options test_subsite_api->subsite::get_application_options db_list_of_lists db_list_of_lists (public) subsite::get_application_options->db_list_of_lists packages/acs-subsite/www/admin/applications/application-add.tcl packages/acs-subsite/ www/admin/applications/application-add.tcl packages/acs-subsite/www/admin/applications/application-add.tcl->subsite::get_application_options packages/acs-subsite/www/admin/applications/multiple-add.tcl packages/acs-subsite/ www/admin/applications/multiple-add.tcl packages/acs-subsite/www/admin/applications/multiple-add.tcl->subsite::get_application_options

Testcases:
subsite_api

subsite::get_element (public)

 subsite::get_element [ -subsite_id subsite_id ] -element element \
    [ -notrailing ]

Return a single element from the information about a subsite.

Switches:
-subsite_id (optional)
The node id of the subsite for which info is requested. If no id is provided, then the id of the closest ancestor subsite will be used.
-element (required)
The element you want, one of: directory_p object_type package_key package_id name pattern_p instance_name node_id parent_id url object_id
-notrailing (optional, boolean)
If true and the element requested is a URL, then strip any trailing slash ('/'). This means the empty string is returned for the root.
Returns:
The element you asked for
Author:
Frank Nikolajsen <frank@warpspace.com>
Created:
2003-03-08

Partial Call Graph (max 5 caller/called nodes):
%3 test_user_links_api user_links_api (test acs-tcl) subsite::get_element subsite::get_element test_user_links_api->subsite::get_element ad_conn ad_conn (public) subsite::get_element->ad_conn subsite::get subsite::get (public) subsite::get_element->subsite::get Class ::xo::lti::LTI Class ::xo::lti::LTI (public) Class ::xo::lti::LTI->subsite::get_element acs_community_member_page acs_community_member_page (public) acs_community_member_page->subsite::get_element ad_admin_home ad_admin_home (public) ad_admin_home->subsite::get_element ad_pvt_home ad_pvt_home (public) ad_pvt_home->subsite::get_element ad_site_home_link ad_site_home_link (public) ad_site_home_link->subsite::get_element

Testcases:
user_links_api

subsite::get_pageflow_struct (public)

 subsite::get_pageflow_struct [ -url url ]

Defines the page flow structure.

Switches:
-url (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 subsite::define_pageflow subsite::define_pageflow (public) subsite::get_pageflow_struct subsite::get_pageflow_struct subsite::define_pageflow->subsite::get_pageflow_struct ad_conn ad_conn (public) subsite::get_pageflow_struct->ad_conn parameter::get parameter::get (public) subsite::get_pageflow_struct->parameter::get permission::permission_p permission::permission_p (public) subsite::get_pageflow_struct->permission::permission_p site_node::closest_ancestor_package site_node::closest_ancestor_package (public) subsite::get_pageflow_struct->site_node::closest_ancestor_package site_node::get site_node::get (public) subsite::get_pageflow_struct->site_node::get

Testcases:
No testcase defined.

subsite::get_section_info (public)

 subsite::get_section_info [ -array array ] \
    [ -sections_multirow sections_multirow ]

Takes the sections_multirow and sets the passed array name with the elements label and url of the selected section.

Switches:
-array (optional, defaults to "section_info")
-sections_multirow (optional, defaults to "sections")

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/group-master.tcl packages/acs-subsite/ www/group-master.tcl subsite::get_section_info subsite::get_section_info packages/acs-subsite/www/group-master.tcl->subsite::get_section_info template::multirow template::multirow (public) subsite::get_section_info->template::multirow

Testcases:
No testcase defined.

subsite::get_theme (public)

 subsite::get_theme [ -subsite_id subsite_id ]

Get the theme for the given (or current) subsite.

Switches:
-subsite_id (optional)
id of the subsite
Returns:
Name of the theme (theme key)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::get_theme subsite::get_theme test_subsite_api->subsite::get_theme ad_conn ad_conn (public) subsite::get_theme->ad_conn parameter::get parameter::get (public) subsite::get_theme->parameter::get Class ::xowiki::formfield::FormField Class ::xowiki::formfield::FormField (public) Class ::xowiki::formfield::FormField->subsite::get_theme Object ::template::CSS Object ::template::CSS (public) Object ::template::CSS->subsite::get_theme openacs_bootstrap3_theme::apm::before_uninstall openacs_bootstrap3_theme::apm::before_uninstall (private) openacs_bootstrap3_theme::apm::before_uninstall->subsite::get_theme openacs_bootstrap5_theme::apm::before_uninstall openacs_bootstrap5_theme::apm::before_uninstall (private) openacs_bootstrap5_theme::apm::before_uninstall->subsite::get_theme subsite::after_mount subsite::after_mount (private) subsite::after_mount->subsite::get_theme

Testcases:
subsite_api

subsite::get_theme_options (public)

 subsite::get_theme_options

Gets options for subsite themes for use with a form builder select widget.

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::get_theme_options subsite::get_theme_options test_subsite_api->subsite::get_theme_options db_foreach db_foreach (public) subsite::get_theme_options->db_foreach lang::util::localize lang::util::localize (public) subsite::get_theme_options->lang::util::localize packages/acs-subsite/www/admin/configure.tcl packages/acs-subsite/ www/admin/configure.tcl packages/acs-subsite/www/admin/configure.tcl->subsite::get_theme_options packages/acs-subsite/www/admin/subsite-add.tcl packages/acs-subsite/ www/admin/subsite-add.tcl packages/acs-subsite/www/admin/subsite-add.tcl->subsite::get_theme_options

Testcases:
subsite_api

subsite::get_theme_subsites (public)

 subsite::get_theme_subsites -theme theme [ -subsite_id subsite_id ] \
    [ -unmodified ]

Returns a list of all packages implementing subsite that are currently using specified theme. Optionally, returns a list of just those that were not locally modified.

Switches:
-theme (required)
theme key to lookup for.
-subsite_id (optional)
narrow search to this subsite only. Useful to check whether a single subsite is using a theme with or without local modifications.
-unmodified (optional, boolean)
decides whether we include subsites which theme was locally modified.
Returns:
list of subsite_id

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::get_theme_subsites subsite::get_theme_subsites test_subsite_api->subsite::get_theme_subsites db_0or1row db_0or1row (public) subsite::get_theme_subsites->db_0or1row db_list db_list (public) subsite::get_theme_subsites->db_list parameter::get parameter::get (public) subsite::get_theme_subsites->parameter::get subsite::package_keys subsite::package_keys (public) subsite::get_theme_subsites->subsite::package_keys packages/acs-subsite/www/admin/themes/index.tcl packages/acs-subsite/ www/admin/themes/index.tcl packages/acs-subsite/www/admin/themes/index.tcl->subsite::get_theme_subsites subsite::refresh_theme_subsites subsite::refresh_theme_subsites (public) subsite::refresh_theme_subsites->subsite::get_theme_subsites

Testcases:
subsite_api

subsite::get_url (public)

 subsite::get_url [ -node_id node_id ] [ -absolute_p absolute_p ] \
    [ -force_host force_host ] [ -strict_p strict_p ] \
    [ -protocol protocol ] [ -port port ]

Returns the url stub for the specified subsite. If -absolute is supplied then this function will generate absolute URLs. If the site is currently being accessed via a host node mapping then URLs will omit the corresponding subsite url stub. The hostname will be used for any appropriate subsite when absolute URLs are generated.

Switches:
-node_id (optional)
the subsite's node_id (defaults to nearest subsite node).
-absolute_p (optional, defaults to "0")
whether to include the host in the returned url.
-force_host (optional)
Use a certain host. In case "any" is specified, and we have a host-node-mapping (e.g. non-connected cases) behave like a virtual server on the first host-node-mapping entry. In connected cases, "any" means: take whatever is provided via vhost.
-strict_p (optional, defaults to "0")
-protocol (optional)
-port (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::get_url subsite::get_url test_subsite_api->subsite::get_url db_list db_list (public) subsite::get_url->db_list security::configured_driver_info security::configured_driver_info (public) subsite::get_url->security::configured_driver_info site_node::get site_node::get (public) subsite::get_url->site_node::get util::join_location util::join_location (public) subsite::get_url->util::join_location util_driver_info util_driver_info (public) subsite::get_url->util_driver_info ad_conn ad_conn (public) ad_conn->subsite::get_url packages/acs-subsite/lib/login.tcl packages/acs-subsite/ lib/login.tcl packages/acs-subsite/lib/login.tcl->subsite::get_url xowiki::Package instproc www-refresh-login xowiki::Package instproc www-refresh-login (public) xowiki::Package instproc www-refresh-login->subsite::get_url

Testcases:
subsite_api

subsite::main_site_id (public)

 subsite::main_site_id

Get the package_id of the Main Site. The Main Site is the subsite that is always mounted at '/' and that has a number of site-wide parameter settings.

Author:
Peter Marklund

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_subsite_test_email_confirmation acs_subsite_test_email_confirmation (test acs-subsite) subsite::main_site_id subsite::main_site_id test_acs_subsite_test_email_confirmation->subsite::main_site_id test_acs_subsite_trivial_smoke_test acs_subsite_trivial_smoke_test (test acs-subsite) test_acs_subsite_trivial_smoke_test->subsite::main_site_id test_password_recovery_page password_recovery_page (test acs-subsite) test_password_recovery_page->subsite::main_site_id test_site_node_closest_ancestor_package site_node_closest_ancestor_package (test acs-tcl) test_site_node_closest_ancestor_package->subsite::main_site_id site_node::get_from_url site_node::get_from_url (public) subsite::main_site_id->site_node::get_from_url apm::process_install_xml apm::process_install_xml (public) apm::process_install_xml->subsite::main_site_id auth::create_local_account auth::create_local_account (public) auth::create_local_account->subsite::main_site_id packages/acs-subsite/lib/user-new.tcl packages/acs-subsite/ lib/user-new.tcl packages/acs-subsite/lib/user-new.tcl->subsite::main_site_id packages/acs-subsite/www/admin/site-map/allow-for-view.tcl packages/acs-subsite/ www/admin/site-map/allow-for-view.tcl packages/acs-subsite/www/admin/site-map/allow-for-view.tcl->subsite::main_site_id packages/acs-subsite/www/members/member-invite.tcl packages/acs-subsite/ www/members/member-invite.tcl packages/acs-subsite/www/members/member-invite.tcl->subsite::main_site_id

Testcases:
acs_subsite_trivial_smoke_test, acs_subsite_test_email_confirmation, password_recovery_page, site_node_closest_ancestor_package

subsite::new_subsite_theme (public)

 subsite::new_subsite_theme -key key -name name -template template \
    [ -css css ] [ -js js ] [ -form_template form_template ] \
    [ -list_template list_template ] \
    [ -list_filter_template list_filter_template ] \
    [ -dimensional_template dimensional_template ] \
    [ -resource_dir resource_dir ] [ -streaming_head streaming_head ] \
    [ -local_p local_p ] [ -create_or_replace ]

Add a new subsite theme, making it available to the theme configuration code.

Switches:
-key (required)
-name (required)
-template (required)
-css (optional)
-js (optional)
-form_template (optional)
-list_template (optional)
-list_filter_template (optional)
-dimensional_template (optional)
-resource_dir (optional)
-streaming_head (optional)
-local_p (optional, defaults to "true")
-create_or_replace (optional, boolean)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::new_subsite_theme subsite::new_subsite_theme test_subsite_api->subsite::new_subsite_theme db_0or1row db_0or1row (public) subsite::new_subsite_theme->db_0or1row db_dml db_dml (public) subsite::new_subsite_theme->db_dml subsite::update_subsite_theme subsite::update_subsite_theme (public) subsite::new_subsite_theme->subsite::update_subsite_theme openacs_bootstrap3_theme::apm::after_install openacs_bootstrap3_theme::apm::after_install (private) openacs_bootstrap3_theme::apm::after_install->subsite::new_subsite_theme openacs_bootstrap5_theme::apm::after_install openacs_bootstrap5_theme::apm::after_install (private) openacs_bootstrap5_theme::apm::after_install->subsite::new_subsite_theme openacs_default_theme::install::after_install openacs_default_theme::install::after_install (private) openacs_default_theme::install::after_install->subsite::new_subsite_theme subsite::save_theme_parameters_as subsite::save_theme_parameters_as (private) subsite::save_theme_parameters_as->subsite::new_subsite_theme

Testcases:
subsite_api

subsite::package_keys (public)

 subsite::package_keys

Get the list of packages which can be subsites. This is built during the bootstrap process. If you install a new subsite-implementing package and don't accept the installers invitation to reboot openacs, tough luck.

Returns:
the packages keys of all installed packages acting as subsites.

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::package_keys subsite::package_keys test_subsite_api->subsite::package_keys ad_conn ad_conn (public) ad_conn->subsite::package_keys packages/acs-admin/www/index.tcl packages/acs-admin/ www/index.tcl packages/acs-admin/www/index.tcl->subsite::package_keys packages/acs-admin/www/subsites.tcl packages/acs-admin/ www/subsites.tcl packages/acs-admin/www/subsites.tcl->subsite::package_keys packages/acs-subsite/lib/subsites.tcl packages/acs-subsite/ lib/subsites.tcl packages/acs-subsite/lib/subsites.tcl->subsite::package_keys packages/acs-subsite/www/admin/themes/index.tcl packages/acs-subsite/ www/admin/themes/index.tcl packages/acs-subsite/www/admin/themes/index.tcl->subsite::package_keys

Testcases:
subsite_api

subsite::pivot_root (public)

 subsite::pivot_root -node_id node_id

Pivot the package associated with node_id onto the root. Mounting the current root package under node_id.

Switches:
-node_id (required)

Partial Call Graph (max 5 caller/called nodes):
%3 db_transaction db_transaction (public) site_node::get site_node::get (public) site_node::mount site_node::mount (public) site_node::unmount site_node::unmount (public) subsite::pivot_root subsite::pivot_root subsite::pivot_root->db_transaction subsite::pivot_root->site_node::get subsite::pivot_root->site_node::mount subsite::pivot_root->site_node::unmount

Testcases:
No testcase defined.

subsite::refresh_theme_subsites (public)

 subsite::refresh_theme_subsites [ -theme theme ] [ -include_modified ]

Reload theme subsite parameters from defaults on every subsite currently using specified theme. This might be used, for example, in upgrade callbacks for themes if desired behavior is to upgrade all subsites using it without manual intervention. By default this proc will not refresh locally modified templates.

Switches:
-theme (optional)
theme key to lookup for
-include_modified (optional, boolean)
force reload also for locally modified templates

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::refresh_theme_subsites subsite::refresh_theme_subsites test_subsite_api->subsite::refresh_theme_subsites subsite::get_theme_subsites subsite::get_theme_subsites (public) subsite::refresh_theme_subsites->subsite::get_theme_subsites subsite::set_theme subsite::set_theme (public) subsite::refresh_theme_subsites->subsite::set_theme

Testcases:
subsite_api

subsite::set_theme (public)

 subsite::set_theme [ -subsite_id subsite_id ] -theme theme

Set the theme for the given or current subsite. This will change the subsite's ThemeKey, DefaultMaster, and ThemeCSS, DefaultFormStyle, DefaultListStyle, DefaultListFilterStyle, DefaultDimensionalStyle, and ResourceDir parameters.

Switches:
-subsite_id (optional)
Id of the subsite
-theme (required)
Name of the theme (theme key)

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::set_theme subsite::set_theme test_subsite_api->subsite::set_theme ad_conn ad_conn (public) subsite::set_theme->ad_conn db_1row db_1row (public) subsite::set_theme->db_1row parameter::set_value parameter::set_value (public) subsite::set_theme->parameter::set_value subsite::get_theme subsite::get_theme (public) subsite::set_theme->subsite::get_theme install::xml::action::set-theme install::xml::action::set-theme (public) install::xml::action::set-theme->subsite::set_theme openacs_bootstrap3_theme::apm::before_uninstall openacs_bootstrap3_theme::apm::before_uninstall (private) openacs_bootstrap3_theme::apm::before_uninstall->subsite::set_theme openacs_bootstrap5_theme::apm::before_uninstall openacs_bootstrap5_theme::apm::before_uninstall (private) openacs_bootstrap5_theme::apm::before_uninstall->subsite::set_theme packages/acs-subsite/www/admin/configure.tcl packages/acs-subsite/ www/admin/configure.tcl packages/acs-subsite/www/admin/configure.tcl->subsite::set_theme packages/acs-subsite/www/admin/subsite-add.tcl packages/acs-subsite/ www/admin/subsite-add.tcl packages/acs-subsite/www/admin/subsite-add.tcl->subsite::set_theme

Testcases:
subsite_api

subsite::update_subsite_theme (public)

 subsite::update_subsite_theme -key key -name name -template template \
    [ -css css ] [ -js js ] [ -form_template form_template ] \
    [ -list_template list_template ] \
    [ -list_filter_template list_filter_template ] \
    [ -dimensional_template dimensional_template ] \
    [ -resource_dir resource_dir ] [ -streaming_head streaming_head ] \
    [ -local_p local_p ]

Update the default theming parameters in the database

Switches:
-key (required)
-name (required)
-template (required)
-css (optional)
-js (optional)
-form_template (optional)
-list_template (optional)
-list_filter_template (optional)
-dimensional_template (optional)
-resource_dir (optional)
-streaming_head (optional)
-local_p (optional, defaults to "false")
Author:
Gustaf Neumann

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::update_subsite_theme subsite::update_subsite_theme test_subsite_api->subsite::update_subsite_theme db_dml db_dml (public) subsite::update_subsite_theme->db_dml packages/acs-subsite/www/admin/themes/view.tcl packages/acs-subsite/ www/admin/themes/view.tcl packages/acs-subsite/www/admin/themes/view.tcl->subsite::update_subsite_theme subsite::new_subsite_theme subsite::new_subsite_theme (public) subsite::new_subsite_theme->subsite::update_subsite_theme subsite::save_theme_parameters subsite::save_theme_parameters (private) subsite::save_theme_parameters->subsite::update_subsite_theme

Testcases:
subsite_api

subsite::upload_allowed (public)

 subsite::upload_allowed

Verifies SolicitPortraitP parameter to ensure upload portrait security.

Author:
Hector Amado <hr_amado@galileo.edu>
Created:
2004-06-16

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/user/portrait/upload.tcl packages/acs-subsite/ www/user/portrait/upload.tcl subsite::upload_allowed subsite::upload_allowed packages/acs-subsite/www/user/portrait/upload.tcl->subsite::upload_allowed acs_user::site_wide_admin_p acs_user::site_wide_admin_p (public) subsite::upload_allowed->acs_user::site_wide_admin_p ad_conn ad_conn (public) subsite::upload_allowed->ad_conn ad_return_forbidden ad_return_forbidden (public) subsite::upload_allowed->ad_return_forbidden ad_script_abort ad_script_abort (public) subsite::upload_allowed->ad_script_abort parameter::get parameter::get (public) subsite::upload_allowed->parameter::get

Testcases:
No testcase defined.

subsite::util::get_package_options (public)

 subsite::util::get_package_options

Get a list of pretty name, package key pairs for all packages which identify themselves as implementing subsite semantics.

Returns:
a list of pretty name, package key pairs suitable for use in a template select widget.

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::util::get_package_options subsite::util::get_package_options test_subsite_api->subsite::util::get_package_options db_list_of_lists db_list_of_lists (public) subsite::util::get_package_options->db_list_of_lists packages/acs-subsite/www/admin/subsite-add.tcl packages/acs-subsite/ www/admin/subsite-add.tcl packages/acs-subsite/www/admin/subsite-add.tcl->subsite::util::get_package_options

Testcases:
subsite_api

subsite::util::object_type_path_list (public)

 subsite::util::object_type_path_list object_type [ ancestor_type ]
Parameters:
object_type (required)
ancestor_type (optional, defaults to "acs_object")
Returns:
the object type hierarchy for the given object type from ancestor_type to object_type

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/admin/parties/new.tcl packages/acs-subsite/ www/admin/parties/new.tcl subsite::util::object_type_path_list subsite::util::object_type_path_list packages/acs-subsite/www/admin/parties/new.tcl->subsite::util::object_type_path_list packages/acs-subsite/www/admin/parties/one.tcl packages/acs-subsite/ www/admin/parties/one.tcl packages/acs-subsite/www/admin/parties/one.tcl->subsite::util::object_type_path_list db_list db_list (public) subsite::util::object_type_path_list->db_list

Testcases:
No testcase defined.

subsite::util::object_type_pretty_name (public)

 subsite::util::object_type_pretty_name object_type

returns pretty name of object. We need this so often that I thought I'd stick it in a proc so it can possibly be cached later.

Parameters:
object_type (required)
Author:
Oumi Mehrotra <oumi@arsdigita.com>
Created:
2000-02-07

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/admin/parties/new.tcl packages/acs-subsite/ www/admin/parties/new.tcl subsite::util::object_type_pretty_name subsite::util::object_type_pretty_name packages/acs-subsite/www/admin/parties/new.tcl->subsite::util::object_type_pretty_name packages/acs-subsite/www/admin/relations/add.tcl packages/acs-subsite/ www/admin/relations/add.tcl packages/acs-subsite/www/admin/relations/add.tcl->subsite::util::object_type_pretty_name db_string db_string (public) subsite::util::object_type_pretty_name->db_string

Testcases:
No testcase defined.

subsite::util::packages (public)

 subsite::util::packages [ -node_id node_id ]

Return a list of package_id's for the subsite containing node_id This is a memoized function which caches for 20 minutes.

Switches:
-node_id (optional)
Author:
Jeff Davis davis@xarg.net
Created:
2004-05-07
See Also:
  • subsite::util::packages_no_mem

Partial Call Graph (max 5 caller/called nodes):
%3 test_subsite_api subsite_api (test acs-subsite) subsite::util::packages subsite::util::packages test_subsite_api->subsite::util::packages site_node::closest_ancestor_package site_node::closest_ancestor_package (public) subsite::util::packages->site_node::closest_ancestor_package subsite::package_keys subsite::package_keys (public) subsite::util::packages->subsite::package_keys subsite::util::packages_no_cache subsite::util::packages_no_cache (private) subsite::util::packages->subsite::util::packages_no_cache util_memoize util_memoize (public) subsite::util::packages->util_memoize packages/categories/lib/contributions.tcl packages/categories/ lib/contributions.tcl packages/categories/lib/contributions.tcl->subsite::util::packages packages/categories/lib/list-categories.tcl packages/categories/ lib/list-categories.tcl packages/categories/lib/list-categories.tcl->subsite::util::packages packages/search/www/search.tcl packages/search/ www/search.tcl packages/search/www/search.tcl->subsite::util::packages

Testcases:
subsite_api

subsite::util::sub_type_exists_p (public)

 subsite::util::sub_type_exists_p object_type
Parameters:
object_type (required)
Returns:
1 if object_type has sub types, or 0 otherwise
Author:
Oumi Mehrotra <oumi@arsdigita.com>
Created:
2000-02-07

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-subsite/www/admin/groups/new.tcl packages/acs-subsite/ www/admin/groups/new.tcl subsite::util::sub_type_exists_p subsite::util::sub_type_exists_p packages/acs-subsite/www/admin/groups/new.tcl->subsite::util::sub_type_exists_p packages/acs-subsite/www/admin/parties/new.tcl packages/acs-subsite/ www/admin/parties/new.tcl packages/acs-subsite/www/admin/parties/new.tcl->subsite::util::sub_type_exists_p packages/acs-subsite/www/admin/relations/add.tcl packages/acs-subsite/ www/admin/relations/add.tcl packages/acs-subsite/www/admin/relations/add.tcl->subsite::util::sub_type_exists_p packages/acs-subsite/www/admin/users/new.tcl packages/acs-subsite/ www/admin/users/new.tcl packages/acs-subsite/www/admin/users/new.tcl->subsite::util::sub_type_exists_p db_string db_string (public) subsite::util::sub_type_exists_p->db_string

Testcases:
No testcase defined.
[ show source ]