public function actionAdmin() { $model = new VendorType('search'); $model->unsetAttributes(); if (isset($_GET['VendorType'])) { $model->setAttributes($_GET['VendorType']); } $this->render('admin', array('model' => $model)); }