public function actionMy() { $set = CActiveRecordProvider::getDistinctWithCondition(TABLE_EXAMINATION_TICKETS, "person_id = " . CSession::getCurrentPerson()->getId(), "session_id"); $tickets = new CArrayList(); foreach ($set->getPaginated()->getItems() as $item) { $ticket = new CExamTicket($item); $tickets->add($ticket->getId(), $ticket); } $this->setData("tickets", $tickets); $this->setData("paginator", $set->getPaginator()); $this->renderView("_examination/my.tpl"); }