示例#1
0
 public function actionDefault($page = 1)
 {
     $this->data->itemsCount = Story::countAll();
     $this->data->pageSize = self::PAGE_SIZE;
     $this->data->activePage = $page;
     $this->data->items = Story::findAll(['order' => 'published DESC', 'offset' => ($page - 1) * self::PAGE_SIZE, 'limit' => self::PAGE_SIZE]);
 }
示例#2
0
 public function actionContentMessage()
 {
     $this->data->itemsCount = Story::countAll();
     $this->data->pageSize = self::PAGE_SIZE;
     $this->data->activePage = 1;
 }