/**
  * Lists all Documento models.
  * @return mixed
  */
 public function actionIndex($mensaje = "")
 {
     $searchModel = new DocumentoSearch();
     $persona = new Persona();
     $personaSearch = new PersonaSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('index', ['searchModel' => $personaSearch, 'dataProvider' => $dataProvider, 'mensaje' => $mensaje]);
 }
 /**
  * Updates an existing Candidato model.
  * If update is successful, the browser will be redirected to the 'view' page.
  * @param integer $id
  * @return mixed
  */
 public function actionUpdate($id)
 {
     $model = $this->findModel($id);
     $searchModel = new DocumentoSearch();
     $searchModel->candidato_idcandidato = $id;
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     if ($model->load(Yii::$app->request->post()) && $model->save()) {
         return $this->redirect(['view', 'id' => $model->idcandidato]);
     } else {
         return $this->render('update', array('model' => $model, 'searchModel' => $searchModel, 'dataProvider' => $dataProvider));
     }
 }
 /**
  * Lists all Documento models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new DocumentoSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }