xowiki::Package instproc www-update-references (public)
<instance of xowiki::Package> www-update-references
Defined in /var/www/openacs.org/packages/xowiki/tcl/package-procs.tcl
This web-callable method can be used to update the page references between all items of this package instance. Call with e.g. xowiki/?update-references
- Testcases:
- No testcase defined.
Source code: set id ${:id} set item_ids [::xo::dc list get_pages { select ci.item_id from xowiki_page, cr_revisions r, cr_items ci, acs_objects o where page_id = r.revision_id and ci.item_id = r.item_id and ci.live_revision = page_id and publish_status = 'ready' and page_id = o.object_id and o.package_id = :id }] #:log "--update-references returns <$item_ids>" foreach item_id $item_ids { set o [::xo::db::CrClass get_instance_from_db -item_id $item_id] if {$o ne ""} { ns_log notice "render $o [$o name]" try { $o render -update_references all } on error {errorMsg} { ns_log warning "render $o [$o name] -> error: $errorMsg" } } } :returnredirect .XQL Not present: Generic, PostgreSQL, Oracle