| 12345678910111213141516171819202122232425 |
- <?php
- namespace v1\controllers;
- use common\data\Respuesta;
- use common\rest\JsonController;
- use yii\db\Expression;
- class EventoResumenController extends JsonController {
- public $modelClass = "v1\models\EventoResumenParticipante";
- public $modelName = "EventoResumen";
- public function actionIndex() {
- $id = intval($this->req->get("id", ""));
- $q = trim($this->req->get("q", ""));
- $query = $this->queryInicial;
- if($id > 0) {
- $query->andWhere(["id" => $id]);
- }
- return new Respuesta($query, $this->limite, $this->pagina, $this->ordenar);
- }
- }
|