public function run() { if (($mannschaft = Gateway_Base::factory('mannschaft')->findOne($_REQUEST['Id'])) === false) { $mannschaft = new Mannschaft(); } $GLOBALS['Smarty']->assign('Mannschaft', $mannschaft); }
/** * Deletes a person by id * * @url DELETE /$id */ public function deletePerson($id = null) { // TODO: param check $result = Gateway_Base::factory('people')->delete($id); if ($result === false) { http_response_code(403); } return ["result" => $result]; }
public function Authenticate($username, $password) { // Default: Authentication through DB // implement other methods here return Gateway_Base::factory('user')->authenticate($username, $password); }