Esempio n. 1
0
 public function detailAction()
 {
     $doctorProxy = new SxModule_Doctor_Proxy();
     $doctors = $doctorProxy->getById($this->_getParam('id'), $this->_getParam('lng', 'nl'), true);
     $sticky = $doctorProxy->getAll($this->_getParam('lng', 'nl'), true, 'a.rank ASC', null, $this->_getParam('id'));
     $this->_helper->layout->setLayout('full');
     $this->view->items = $doctors;
     $this->view->sticky = $sticky;
 }
Esempio n. 2
0
 public function indexAction()
 {
     //SxCms_Acl::requireAcl('block', 'block.edit');
     $did = $this->_getParam('did');
     $proxy = new SxModule_Doctor_Agenda_Proxy();
     $items = $proxy->getByDoctorId($did, $_SESSION['System']['lng']);
     $paginator = new Zend_Paginator(new Zend_Paginator_Adapter_Array($items));
     $paginator->setCurrentPageNumber($this->_getParam('page'));
     $paginator->setItemCountPerPage(999);
     $proxy = new SxModule_Doctor_Proxy();
     $doctor = $proxy->getById($did);
     $this->view->doctor = $doctor;
     $this->view->paginator = $paginator;
     $this->view->did = $did;
 }
Esempio n. 3
0
 public function deleteAction()
 {
     $id = $this->_getParam('id');
     $proxy = new SxModule_Doctor_Proxy();
     $item = $proxy->getById($id);
     $image1 = APPLICATION_ROOT . '/public_html/images/doctors/100x100/' . $item->getPhoto();
     $image2 = APPLICATION_ROOT . '/public_html/images/doctors/230x230/' . $item->getPhoto();
     $image3 = APPLICATION_ROOT . '/public_html/images/doctors/110x110/' . $item->getPhoto();
     if (file_exists($image1)) {
         unlink($image1);
     }
     if (file_exists($image2)) {
         unlink($image2);
     }
     if (file_exists($image3)) {
         unlink($image3);
     }
     $item->delete();
     $flashMessenger = $this->_helper->getHelper('FlashMessenger');
     $flashMessenger->addMessage('Item werd succesvol verwijderd!');
     $this->_helper->redirector->gotoSimple('index', 'doctor');
 }