Ejemplo n.º 1
0
 /**
  * @return Pagination
  */
 public function getPaginator()
 {
     $paginator = new Pagination(['totalCount' => $this->countQuery->count()]);
     $paginator->pageParam = 'page';
     $paginator->pageSizeParam = false;
     $paginator->setPageSize($this->limit);
     return $paginator;
 }
 public function count($q = '*', $db = null)
 {
     $this->joinWith('translation')->andWhere(['languages_id' => Languages::getId()]);
     return parent::count($q, $db);
 }