break;
     }
     if ($coodle->RessourceExists($coodle_id, $uid, $ort, $email)) {
         die('Ressource ist bereits zugeteilt');
     }
     $coodle->coodle_id = $coodle_id;
     $coodle->uid = $uid;
     $coodle->ort_kurzbz = $ort;
     $coodle->email = $email;
     $coodle->name = $name;
     $coodle->zugangscode = uniqid();
     $coodle->insertamum = date('Y-m-d H:i:s');
     $coodle->insertvon = $user;
     $coodle->updateamum = date('Y-m-d H:i:s');
     $coodle->updatevon = $user;
     if ($coodle->saveRessource(true)) {
         echo 'true';
     } else {
         echo 'Fehler beim Speichern:' . $coodle->errormsg;
     }
     break;
 case 'removeressource':
     if (isset($_POST['coodle_id'])) {
         $coodle_id = $_POST['coodle_id'];
     } else {
         die('CoodleID Missing');
     }
     if (isset($_POST['id'])) {
         $id = $_POST['id'];
     } else {
         die('RessourceID Missing');