From 065045cbe81b7187971f0566ff221597c6f6bc0b Mon Sep 17 00:00:00 2001 From: Lillem4n Date: Wed, 16 Nov 2011 17:39:52 +0100 Subject: [PATCH] Fixed so employees works --- classes/controller/admin/employees.php | 13 ++++++++++++- xsl/admin/employees.xsl | 17 ----------------- 2 files changed, 12 insertions(+), 18 deletions(-) diff --git a/classes/controller/admin/employees.php b/classes/controller/admin/employees.php index 5211c02..06475f4 100644 --- a/classes/controller/admin/employees.php +++ b/classes/controller/admin/employees.php @@ -17,6 +17,18 @@ public function action_index() public function action_employee() { + $statuses = array( + '0option' => array( + '@value' => 'active', + '$content' => 'Active', + ), + '1option' => array( + '@value' => 'inactive', + '$content' => 'Inactive', + ), + ); + xml::to_XML($statuses, $this->xml_content->appendChild($this->dom->createElement('statuses'))); + if (isset($_GET['id'])) { $employee = new Employee($_GET['id']); @@ -56,7 +68,6 @@ public function action_employee() $this->add_message($post->get('firstname').' (ID: '.$employee_id.') was added as employee'); } - else $this->redirect(); } } diff --git a/xsl/admin/employees.xsl b/xsl/admin/employees.xsl index 60a2c87..387501e 100644 --- a/xsl/admin/employees.xsl +++ b/xsl/admin/employees.xsl @@ -102,23 +102,6 @@ employees/employee - - - - - -