Exemple #1
0
 public static function getArticleCount($aid)
 {
     return DzPortalArticle::getArticleCountByAid($aid);
 }
Exemple #2
0
 private function _autoCatidData($catids, $offset, $pageSize, $params)
 {
     $lists = DzPortalArticle::getByCatidData($catids, $offset, $pageSize, $params);
     $rows = array();
     foreach ($lists as $list) {
         // [add]考虑文章是通过帖子来发布的时候的评论数问题 Author:HanPengyu,Data:14.09.28
         if ($list['idtype'] == 'tid') {
             $topicInfo = ForumUtils::getTopicInfo($list['id']);
             $list['commentnum'] = (int) $topicInfo['replies'];
         }
         $articleSummary = PortalUtils::getArticleSummary($list['aid'], true, array('imageList' => $_GET['isImageList'], 'imageListLen' => 9, 'imageListThumb' => 1));
         $rows[] = $this->_getListField($list, $articleSummary, 'news', $list['aid']);
     }
     return $rows;
 }