public function holidayviewAction() { //Acl $id = $this->_request->getParam('id'); //view function $holiday = new Holiday_Model_Holiday(); $this->view->holidaydetails = $holiday->getHoliday($id); }
public function holidaydeleteAction() { //calling the delete form $delform = new Category_Form_Delete(); $this->view->deleteform = $delform; //getting the id $id = $this->_getParam('id'); $this->view->id = $id; //calling holiday model $holiday = new Holiday_Model_Holiday(); $this->view->holidaydetails = $holiday->getHoliday($id); //Delete action if ($this->_request->isPost() && $this->_request->getPost('Delete')) { $formdata = $this->_request->getPost(); if ($delform->isValid($formdata)) { $redirect = $this->view->adm->deleteRecord("ourbank_holiday", $id); //update $this->_redirect('/holiday'); } } }