/** * Manages all models. */ public function actionAdmin() { $model=new Purchaseproduct('search'); $model->unsetAttributes(); // clear any default values if(isset($_GET['Purchaseproduct'])) $model->attributes=$_GET['Purchaseproduct']; $this->render('admin',array( 'model'=>$model, )); }