omitRequisition($_POST["del"]); } if(!empty($_POST["test"])){ if(file_exists($_POST["test"])){ $form=str_replace(["forms/",".schema.json"], "", $_POST["test"]); $test=json_decode(file_get_contents("forms/".$form.".schema.json"))->description; } else{ $test=$_POST["test"]; $form=""; } $db->addRequisition($pid, $test, $_POST["sample"], $_POST["date"], $_POST["time"], $_POST["room"], $form); } $inv=json_decode(file_get_contents("autocomplete/investigation.json")); $testList=""; foreach(glob("forms/report*.json") as $file){ $form=json_decode(file_get_contents($file)); $testList=$testList.""; } foreach($inv->tests as $t){ $testList=$testList.""; } $roomList=""; foreach($inv->rooms as $r){ $roomList=$roomList.""; } $roomList=$roomList.""; $reqList=$db->getRequisitions($pid); $list=""; while($req=$reqList->fetchArray()){ $list=$list."".$req["test"]."".$req["sample"]."".$req["room"]."".date("M j, Y", $req["time"]).""; } } ?> Laboratory

List of Requisitions

Test NameSampleDestinationDate

>