public function actionArtistas() { $this->pageTitle = 'Artistas - ' . $this->pageTitle; $this->pageDescription = 'Ven y disfruta en familia de lo mejor de la salsa, el merengue, el vallenato y mucho más en las ferias de Duitama 2016.'; $this->tagImage = '/images/facebook-artistas.png'; $artists = Artists::model()->findAllByAttributes(array('status_artist' => 1)); $this->render('artistas', array('artists' => $artists)); }
public function loadModel($id) { $model = Artists::model()->findByAttributes(array('id_artist' => $id, 'status_artist' => 1)); if ($model === null) { throw new CHttpException(404, 'The requested page does not exist.'); } return $model; }