Beispiel #1
0
     if (isset($_GET["projet"]) && $_GET["projet"] != -1) {
         $tempProjet = new Projet($_GET["projet"]);
         $tempProjet->delete();
         $_SESSION["projet"] = -1;
     } elseif (isset($_GET["projet"]) && $_GET["projet"] == -1) {
         $_SESSION["projet"] = -1;
     }
     break;
 case $ACTION_projetCreate:
     $tempProjet = new Projet(0, $_POST["project_name"], $_POST["project_description"], new Client($_POST["select_project_client"]), new Personne($_POST["select_project_respo"]));
     $_SESSION["projet"] = $tempProjet->create();
     break;
 case $ACTION_projetSave:
     $tempProjet = new Projet($_POST["projet"], $_POST["project_name"], $_POST["project_description"], new Client($_POST["select_project_client"]), new Personne($_POST["select_project_respo"]));
     $tempProjet->save();
     $_SESSION["projet"] = $tempProjet->getId();
     break;
 case $ACTION_tacheView:
     if (isset($_GET["tache"]) && $_GET["tache"] != -1) {
         $_SESSION["tache"] = $_GET["tache"];
     } elseif (isset($_GET["tache"]) && $_GET["tache"] == -1) {
         $_SESSION["tache"] = -1;
     }
     break;
 case $ACTION_tacheDelete:
     if (isset($_GET["tache"]) && $_GET["tache"] != -1) {
         $tacheTemp = new Tache($_GET["tache"]);
         $tacheTemp->delete();
     }
     break;
 case $ACTION_tacheSave: