37 lines
698 B
PHP
37 lines
698 B
PHP
<?php
|
|
//Programmiert von: Max Heer, Getestet von: Samuel Wolff
|
|
|
|
namespace ppb\Controller;
|
|
|
|
use ppb\Libary\Msg;
|
|
use ppb\Model\TagesplanModel;
|
|
|
|
class TagesplanController
|
|
{
|
|
|
|
private $db;
|
|
|
|
public function __construct()
|
|
{
|
|
$this->db = new TagesplanModel();
|
|
}
|
|
|
|
public function getTagesplan()
|
|
{
|
|
$result = $this->db->getTagesplan();
|
|
return json_encode($result);
|
|
}
|
|
|
|
public function writeTagesplan($data)
|
|
{
|
|
$result = $this->db->insertTagesplan($data);
|
|
return json_encode($result);
|
|
}
|
|
|
|
public function deleteTagesplan($id)
|
|
{
|
|
$result = $this->db->deleteTagesplan($id);
|
|
return json_encode($result);
|
|
}
|
|
}
|
|
?>
|