subsite::pivot_root (public)

 subsite::pivot_root -node_id node_id

Defined in packages/acs-subsite/tcl/subsite-procs.tcl

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.
Source code:
    array set node [site_node::get -node_id $node_id]
    array set root [site_node::get -url "/"]

    db_transaction {
        site_node::unmount -node_id $node(node_id)
        site_node::unmount -node_id $root(node_id)

        site_node::mount -node_id $root(node_id) -object_id $node(package_id)
        site_node::mount -node_id $node(node_id) -object_id $root(package_id)

        #TODO: swap the application groups for the subsites so that
        #TODO: registered users is always the application group of the root
        #TODO: subsite.
        #
        #TODO: adjust sitenode hierarchy?
        #TODO: permissions on main subsite (has to be always world readable)
        #TODO: memberships on site / subsite
        #TODO: address implications on permission management when hierarchy flips around
        #TODO: test caching implications
        #TODO: probably more
    }
XQL Not present:
Generic
PostgreSQL XQL file:
packages/acs-subsite/tcl/subsite-procs-postgresql.xql

Oracle XQL file:
packages/acs-subsite/tcl/subsite-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: