diff --git a/application/controllers/DatalistController.php b/application/controllers/DatalistController.php index f1313158..79d1e6d3 100644 --- a/application/controllers/DatalistController.php +++ b/application/controllers/DatalistController.php @@ -4,11 +4,21 @@ use Icinga\Module\Director\Web\Controller\ActionController; class Director_DatalistController extends ActionController { + public function addAction() + { + $this->forward('index', 'datalist', 'director'); + } + + public function editAction() + { + $this->forward('index', 'datalist', 'director'); + } + public function indexAction() { $this->view->title = $this->translate('Add list'); $this->getTabs()->add('addlist', array( - 'url' => 'director/data/addlist', + 'url' => 'director/datalist/add', 'label' => $this->view->title, ))->activate('addlist'); @@ -19,6 +29,7 @@ class Director_DatalistController extends ActionController if ($id = $this->params->get('id')) { $form->loadObject($id); } + $form->handleRequest(); $this->render('object/form', null, true); diff --git a/application/tables/DatalistTable.php b/application/tables/DatalistTable.php index 59b3ded0..f35fc126 100644 --- a/application/tables/DatalistTable.php +++ b/application/tables/DatalistTable.php @@ -17,7 +17,7 @@ class DatalistTable extends QuickTable protected function getActionUrl($row) { - return $this->url('director/datalist', array('id' => $row->id)); + return $this->url('director/datalist/edit', array('id' => $row->id)); } public function getTitles()