示例#1
0
 public function view()
 {
     $ct = Type::getByDefaultsPage($this->page);
     $template = Template::getByID($this->page->getPageTemplateID());
     $pl = new PageList();
     $pl->filterByPageTypeID($ct->getPageTypeID());
     $pl->filterByPageTemplate($template);
     $pl->ignorePermissions();
     $this->set('total', $pl->getTotalResults());
 }
示例#2
0
 public function testFilterByPath()
 {
     $this->createPage('More Fun', '/test-page-1/foobler');
     $this->list->filterByPath('/test-page-1');
     $totalResults = $this->list->getTotalResults();
     $this->assertEquals(2, $totalResults);
     $nl = new \Concrete\Core\Page\PageList();
     $nl->ignorePermissions();
     $nl->filterbyPath('/test-page-1', false);
     $pagination = $nl->getPagination();
     $this->assertEquals(1, $pagination->getNBResults());
 }
示例#3
0
 public function getTotalResults()
 {
     return parent::getTotalResults();
 }