Beispiel #1
0
 $motifAutreActive = false;
 $bilan = "";
 $documentation = false;
 $echantillonsMultidataForm = OutilsMultidataForm::init("echantillonsDonnees", 25, OutilsUrl::composer("compte-rendu", "ajax-saisie-echantillons"), array("choixMedicament", "qteOfferte"));
 // Valider
 $valid = array();
 $valid["dateVisite"] = 1;
 $valid["choixPraticien"] = 1;
 $valid["choixMotif"] = 1;
 $valid["motifAutre"] = 1;
 $valid["bilan"] = 1;
 $valid["echantillons"] = 1;
 // Si Formulaire
 if (OutilsForm::existePostEntrees(array("dateVisite", "choixPraticien", "choixMotif", "bilan"))) {
     $dateVisite = $_POST["dateVisite"];
     $valid["dateVisite"] = OutilsForm::valideDate($dateVisite, time()) ? 1 : 0;
     //
     $choixPraticien = $_POST["choixPraticien"];
     $valid["choixPraticien"] = is_array(GsbModele::getLePraticienDetails($choixPraticien));
     //
     $bilan = $_POST["bilan"];
     $valid["bilan"] = OutilsForm::valideMessage($bilan);
     //
     $remplacant = isset($_POST["remplacant"]);
     $documentation = isset($_POST["documentation"]);
     //
     if (isset($_POST["motifAutre"])) {
         $motifAutre = $_POST["motifAutre"];
         $motifAutreActive = true;
         $choixMotif = "autre-saisie";
         $valid["motifAutre"] = OutilsForm::valideMessage($motifAutre, 128);