src/News/Modules/Frontend/ArticleList.php
private function InitCategoryArticles()
    {
        $sql = Access::SqlBuilder();
        $tblArticle = Article::Schema()->Table();
        $orderBy = $sql->OrderList($sql->OrderDesc($tblArticle->Field('Created')));
        $where = $this->PublishedCondition()->
                And_($sql->Equals($tblArticle->Field('Category'), 
                        $sql->Value($this->category->GetID())));
        $this->articles = Article::Schema()->Fetch(false, $where, $orderBy);
        $this->articlesTotal = Article::Schema()->Count(false, $where);
    }
private function InitCategoryArticles()
    {
        $sql = Access::SqlBuilder();
        $tblArticle = Article::Schema()->Table();
        $orderBy = $sql->OrderList($sql->OrderDesc($tblArticle->Field('Created')));
        $where = $this->PublishedCondition()->
                And_($sql->Equals($tblArticle->Field('Category'), 
                        $sql->Value($this->category->GetID())));
        $this->articles = Article::Schema()->Fetch(false, $where, $orderBy);
        $this->articlesTotal = Article::Schema()->Count(false, $where);
    }
private function InitCategoryArticles ( ) { $ sql = Access :: SqlBuilder ( ) ; $ tblArticle = Article :: Schema ( ) -> Table ( ) ; $ orderBy = $ sql -> OrderList ( $ sql -> OrderDesc ( $ tblArticle -> Field ( 'Created' ) ) ) ; $ where = $ this -> PublishedCondition ( ) -> And_ ( $ sql -> Equals ( $ tblArticle -> Field ( 'Category' ) , $ sql -> Value ( $ this -> category -> GetID ( ) ) ) ) ; $ this -> articles = Article :: Schema ( ) -> Fetch ( false , $ where , $ orderBy ) ; $ this -> articlesTotal = Article :: Schema ( ) -> Count ( false , $ where ) ; }
Initializes article array for a page assigned category
Initializes article array for a page assigned category