Added the page.isMyAncestor condition to the Navigation system.

This commit is contained in:
Len Kranendonk 2004-07-27 11:14:40 +00:00
parent dea9d9f487
commit e9e4c46aa1
3 changed files with 8 additions and 0 deletions

View file

@ -305,6 +305,11 @@ sub build {
$pageData->{"page.inCurrentRoot"} =
(($page->{'lft'} > $currentPage->get('lft')) && ($page->{'rgt'} < $currentPage->get('rgt'))) ||
(($page->{'lft'} < $currentPage->get('lft')) && ($page->{'rgt'} > $currentPage->get('rgt')));
# Anchestor info
foreach my $ancestor ($currentPage->ancestors) {
$pageData->{"page.isMyAncestor"} += ($ancestor->{'pageId'} == $page->{'pageId'});
}
# Some information about my mother
my $mother = WebGUI::Page->getPage($page->{parentId});