2023-12-06 08:53:48 +01:00
|
|
|
<?php
|
2024-01-09 09:51:28 +01:00
|
|
|
//Programmiert von: Max Heer, Getestet von: Samuel Wolff
|
2023-12-06 08:53:48 +01:00
|
|
|
|
2023-12-18 08:19:27 +01:00
|
|
|
namespace ppb\Controller;
|
2023-12-06 08:53:48 +01:00
|
|
|
|
2023-12-18 08:19:27 +01:00
|
|
|
use ppb\Libary\Msg;
|
|
|
|
use ppb\Model\EnthaeltModel;
|
2023-12-06 08:53:48 +01:00
|
|
|
|
2023-12-18 08:16:21 +01:00
|
|
|
class EnthaeltController
|
|
|
|
{
|
2023-12-06 08:53:48 +01:00
|
|
|
|
2023-12-18 08:16:21 +01:00
|
|
|
private $db;
|
|
|
|
|
|
|
|
public function __construct()
|
|
|
|
{
|
|
|
|
$this->db = new EnthaeltModel();
|
|
|
|
}
|
|
|
|
|
2024-01-09 09:51:28 +01:00
|
|
|
public function getEnthaelt($gerichtId)
|
2023-12-18 08:16:21 +01:00
|
|
|
{
|
|
|
|
$result = $this->db->getEnthaelt($gerichtId);
|
|
|
|
return json_encode($result);
|
|
|
|
}
|
|
|
|
|
2024-01-09 09:51:28 +01:00
|
|
|
public function writeEnthaelt($data)
|
2023-12-18 08:16:21 +01:00
|
|
|
{
|
|
|
|
$result = $this->db->insertEnthaelt($data);
|
|
|
|
return json_encode($result);
|
2023-12-06 08:53:48 +01:00
|
|
|
}
|
2023-12-18 08:16:21 +01:00
|
|
|
}
|
2023-12-06 08:53:48 +01:00
|
|
|
?>
|