Пример #1
0
 public function deleteAction()
 {
     $id = $this->getRequest()->getParam('id');
     $this->view->title = "Delete Rating ";
     $this->view->headTitle($this->view->title);
     if ($this->getRequest()->isPost()) {
         $del = $this->getRequest()->getPost('del');
         if ($del == 'Yes') {
             $id = $this->getRequest()->getPost('id');
             $tbl = new App_Model_Rating();
             $mapper = new App_Model_RatingMapper();
             $row = $tbl->find($id);
             $mapper->delete($tbl);
         }
         $this->_helper->redirector('index');
     } else {
         $tbl = new App_Model_Rating();
         $this->view->id = $id;
     }
 }
Пример #2
0
 public function find($id)
 {
     $mapper = new App_Model_RatingMapper();
     $mapper->find($id, $this);
 }