<option value="07">Jul</option> <option value="08">Aug</option> <option value="09">Sept</option> <option value="10">Oct</option> <option value="11">Nov</option> <option value="12">Dec</option> </select></td> <td style="padding:0px 0px 0px 5px"><select name="assayDateYear" id="assayDateYear" class="search"> <? if($assayDate) { echo "<option value=\"".getFormattedDateYear($assayDate)."\" selected=\"selected\">".getFormattedDateYear($assayDate)."</option>"; } else { echo "<option value=\"\" selected=\"selected\">Select Year</option>"; } for($j=getFormattedDateYear($datetime);$j<=(getCurrentYear()+10);$j++) { echo "<option value=\"$j\">$j</option>"; } ?> </select></td> </tr> </table></td> </tr> <tr> <td style="padding:10px 0px 5px 0px">Include Calibrators in Worksheet</td> <td style="padding:10px 0px 5px 0px"><input name="includeCalibrators" id="includeCalibrators" type="checkbox" value="1" <?php echo $includeCalibrators ? "checked=\"checked\"" : ""; ?> /></td> </tr> </table>
<option value="06">Jun</option> <option value="07">Jul</option> <option value="08">Aug</option> <option value="09">Sept</option> <option value="10">Oct</option> <option value="11">Nov</option> <option value="12">Dec</option> </select></td> <td style="padding:0px 0px 0px 5px"><select name="suspectedTreatmentFailureLastVLDateYear" id="suspectedTreatmentFailureLastVLDateYear" class="search"> <? if($suspectedTreatmentFailureLastVLDate) { echo "<option value=\"".getFormattedDateYear($suspectedTreatmentFailureLastVLDate)."\" selected=\"selected\">".getFormattedDateYear($suspectedTreatmentFailureLastVLDate)."</option>"; } else { echo "<option value=\"\" selected=\"selected\">Select Year</option>"; } for($j=getFormattedDateYear(getDualInfoWithAlias("last_day(now())","lastmonth"));$j>=(getCurrentYear()-10);$j--) { echo "<option value=\"$j\">$j</option>"; } ?> </select></td> </tr> </table> </td> <td style="padding: 0px 0px 0px 10px" align="right">Value:</td> <td style="padding:0px 0px 0px 5px"><input type="text" name="suspectedTreatmentFailureValue" id="suspectedTreatmentFailureValue" value="<?php echo $suspectedTreatmentFailureValue; ?> " class="search_pre" size="7" maxlength="10" /></td> <td align="right">Sample Type:</td> <td style="padding:0px 0px 0px 5px"> <select name="suspectedTreatmentFailureSampleTypeID" id="suspectedTreatmentFailureSampleTypeID" class="search">
/** * function to get current year */ function getCurrentYear() { global $c,$default_GMTtimezone,$default_country; //return gmdate("Y"); return getFormattedDateYear(getDualInfoWithAlias("now()","datetime")); }
<option value="01">Jan</option> <option value="02">Feb</option> <option value="03">Mar</option> <option value="04">Apr</option> <option value="05">May</option> <option value="06">Jun</option> <option value="07">Jul</option> <option value="08">Aug</option> <option value="09">Sept</option> <option value="10">Oct</option> <option value="11">Nov</option> <option value="12">Dec</option> </select></td> <td style="padding:0px 0px 0px 5px"><select name="dispatchedDateYear" id="dispatchedDateYear" class="search"> <? for($j=getFormattedDateYear($oldDispatchedDate?$oldDispatchedDate:$datetime);$j>=(getCurrentYear()-10);$j--) { echo "<option value=\"$j\">$j</option>"; } ?> </select></td> </tr> </table></td> </tr> <tr> <td>To Facility (Destination) <font class="vl_red">*</font></td> <td><select name="facilityID" id="facilityID" class="search"> <? $query=0; $query=mysqlquery("select * from vl_facilities where facility!='' order by facility"); if($facilityID) { echo "<option value=\"$facilityID\" selected=\"selected\">".getDetailedTableInfo2("vl_facilities","id='$facilityID' limit 1","facility")."</option>";
<option value="02">Feb</option> <option value="03">Mar</option> <option value="04">Apr</option> <option value="05">May</option> <option value="06">Jun</option> <option value="07">Jul</option> <option value="08">Aug</option> <option value="09">Sept</option> <option value="10">Oct</option> <option value="11">Nov</option> <option value="12">Dec</option> </select></td> <td style="padding:0px 0px 0px 5px"><select name="receivedDateYear" id="receivedDateYear" class="search"> <? echo "<option value=\"".getFormattedDateYear($created)."\" selected=\"selected\">".getFormattedDateYear($created)."</option>"; for($j=getFormattedDateYear($datetime);$j>=(getCurrentYear()-10);$j--) { echo "<option value=\"$j\">$j</option>"; } ?> </select></td> </tr> </table></td> </tr> </table> </fieldset> </td> </tr> <tr> <td style="padding:10px 0px 0px 0px"><input type="submit" name="saveEnvelope" id="saveEnvelope" class="button" value=" Save Changes to Envelope " /></td> </tr> <tr>
<option value="02">February</option> <option value="03">March</option> <option value="04">April</option> <option value="05">May</option> <option value="06">June</option> <option value="07">July</option> <option value="08">August</option> <option value="09">September</option> <option value="10">October</option> <option value="11">November</option> <option value="12">December</option> </select></td> <td style="padding:0px 0px 0px 5px"><select name="toYear" id="toYear" class="search"> <? for($j=(getFormattedDateYear($datetime)-5);$j<=(getCurrentYear()+50);$j++) { echo "<option value=\"$j\"".($j==getFormattedDateYear($datetime)?" selected=\"selected\"":"").">$j</option>"; } ?> </select></td> </tr> </table></td> </tr> <tr> <td> </td> <td style="padding:0px 0px 0px 0px"> <input type="submit" name="downloadXLS" id="downloadXLS" onclick="document.pressed=this.value" value=" Download Excel " class="button" /> <!--<input type="submit" name="downloadCSV" id="downloadCSV" onclick="document.pressed=this.value" value=" Download CSV " class="button" />--> </td> </tr> </table> </form>
/** * update patient's ART */ function updatePatientData($patientID,$field,$data,$collectionDate) { global $datetime,$user; if($patientID && $field && $data && getDetailedTableInfo2("vl_patients","id='$patientID' limit 1","id")) { //special provisions for date of birth if($field=="dateOfBirth") { $dateOfBirth=0; $dateOfBirth=getFormattedDateYear(subtractFromDate(($collectionDate?$collectionDate:$datetime),($data*12*30.5)))."-01-01"; //replace data with dateOfBirth $data=$dateOfBirth; } //log table change logTableChange("vl_patients","$field",$patientID,getDetailedTableInfo2("vl_patients","id='$patientID'","$field"),$data); //update vl_hubs mysqlquery("update vl_patients set $field='$data' where id='$patientID'"); } }