public function execute() { $config = $this->getConfig(); $id = filter_input(INPUT_GET, 'id'); $turno = new turnoTable($config); $turno->setId($id); $this->objturno = $turno->delete(); header('Location: ' . $config->getUrl() . 'index.php/turno/index'); exit; }
public function execute() { $config = $this->getConfig(); $formturno = filter_input_array(INPUT_POST)['turno']; $turno = new turnoTable($config); $turno->setId($formturno['id']); $turno->setDescripcion($formturno['descripcion']); $turno->setHoraInicio($formturno['horainicio']); $turno->setHoraFin($formturno['horafin']); $turno->setEstado($formturno['estado']); $this->objturno = $turno->update(); header('Location: ' . $config->getUrl() . 'index.php/turno/index'); exit; }