public function executeSlideshowitem() { $this->module = $this->getModuleName(); $catId = $this->getRequestParameter('id'); $department_id = $this->get_department_id(); $departmentAvailable = $this->tools->departmentAvailable($department_id); $this->criteria->add(WebSlideshowCategoryPeer::ID, $catId, Criteria::EQUAL); $this->slideshowCategory = WebSlideshowCategoryPeer::doSelectOne($this->criteria); if (!$this->slideshowCategory) { echo 'Menu ' . $initial . ' not found'; } $this->criteria->add(WebSlideshowCategoryPeer::DEPARTMENT_ID, $departmentAvailable, Criteria::IN); $this->slideshowCategory = WebSlideshowCategoryPeer::doSelectOne($this->criteria); if (!$this->slideshowCategory) { echo 'Maaf, anda tidak memiliki hak untuk mengakses halaman ini.'; } $this->section = $this->get_section(); }
if (!$imageItem->validate()) { var_dump($imageItem->validate()); } $imageItem->save(); $output = array('success' => 1, 'data' => $param); $this->jsonwrapper->print_json($output); } public function categorydelete($param) { $department_id = $param['department_id']; $departmentAvailable = $this->tools->departmentAvailable($department_id); if (empty($param['id'])) { $this->jsonwrapper->show_json_error('param', 'Parameter id tidak ditemukan.'); } $category = WebSlideshowCategoryPeer::retrieveByPK($param['id']); if (!$category) { $this->jsonwrapper->show_json_error('item', 'Item dengan id ' . $param['id'] . ' tidak ditemukan.'); }