Beispiel #1
0
        if ($coodle_help->RessourceExists($coodle_id, $uid)) {
            $coodle_help->getRessourceFromUser($coodle_id, $uid);
            $coodle_ressource_termin = $coodle_help->deleteRessourceTermin($coodle_id, $coodle_help->coodle_ressource_id);
        }
    }
    //  Einträge speichern
    foreach ($_POST as $key => $value) {
        if (mb_substr($key, 0, 5) == 'check') {
            $termin = explode('_', $key);
            $ressource_id = $termin[1];
            $termin_id = $termin[2];
            $coodle_ressource_termin = new coodle();
            $coodle_ressource_termin->coodle_ressource_id = $ressource_id;
            $coodle_ressource_termin->coodle_termin_id = $termin_id;
            $coodle_ressource_termin->new = true;
            if (!$coodle_ressource_termin->saveRessourceTermin()) {
                $error = true;
            }
        }
    }
    if ($error) {
        $message .= "<span class='error'>" . $p->t('global/fehlerBeimSpeichernDerDaten') . "</span><br>";
    } else {
        // email an ersteller senden
        sendBenachrichtigung($coodle_id);
        $saveOk = true;
    }
}
// endgültige auswahl des termins speichern
if (isset($_POST['auswahl_termin'])) {
    if ($ersteller) {