Advertisement
yony258

Untitled

Dec 6th, 2012
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.00 KB | None | 0 0
  1. <%@ include file="/WEB-INF/template/include.jsp" %>
  2.  
  3. <%@ include file="/WEB-INF/template/header.jsp" %>
  4. <%@ include file="localHeader.jsp" %>
  5. <openmrs:htmlInclude file="/scripts/timepicker/timepicker.js" />
  6.  
  7. <script type="text/javascript">
  8. function forceMaxLength(object, maxLength) {
  9. if( object.value.length >= maxLength) {
  10. object.value = object.value.substring(0, maxLength);
  11. }
  12. }
  13. </script>
  14.  
  15. <script src="<openmrs:contextPath/>/dwr/interface/DWRAppointmentService.js"></script>
  16. <script type="text/javascript">
  17. function updatePatient(formFieldId, patientObj, isPageLoad) {
  18. if(!isPageLoad){
  19. DWRAppointmentService.getPatientDescription(patientObj.patientId, function(details){
  20. alert(details);
  21. });
  22. }
  23. }
  24. </script>
  25.  
  26. <h2><spring:message code="appointment.Appointment.create.title"/></h2>
  27.  
  28. <table>
  29. <tr>
  30. <td><spring:message code="appointment.Appointment.create.label.findPatient"/></td>
  31.  
  32. <td>
  33. <spring:bind path="appointment.patient"><openmrs_tag:patientField formFieldName="patientId" callback="updatePatient"/></spring:bind>
  34. </td>
  35. </tr>
  36. <tr>
  37. <td colspan="2">
  38. <label id="labelPhone"></label>
  39. <label id="labelMissed"></label>
  40. </td>
  41. </tr>
  42.  
  43. <tr>
  44. <td><spring:message code="appointment.Appointment.create.label.appointmentType"/></td>
  45. <td>
  46. <select name="appointmentTypeSelect">
  47. <c:forEach var="appointmentType" items="${appointmentTypeList}">
  48. <option value="${appointmentType.appointmentTypeId}">${appointmentType.name}</option>
  49. </c:forEach>
  50. </select>
  51. </td>
  52. </tr>
  53. <tr>
  54. <td><spring:message code="appointment.Appointment.create.label.clinician"/></td>
  55. <td>
  56. <select name="providerSelect">
  57. <option value="0">Not Specified</option>
  58. <c:forEach var="provider" items="${providerList}">
  59. <option value="${appointmentType.providerId}">${provider.name}</option>
  60. </c:forEach>
  61. </select>
  62. </td>
  63. </tr>
  64. <tr>
  65. <td><spring:message code="appointment.Appointment.create.label.betweenDates"/></td>
  66. <td><input type="text" name="Date" id="fromDate" size="15" value="" onfocus="showDateTimePicker(this)"/> and <input type="text" name="Date" id="toDate" size="15" value="" onfocus="showDateTimePicker(this)"/></td>
  67. </tr>
  68. <tr>
  69. <td/><td><input type="button" value="<spring:message code="appointment.Appointment.create.findTime"/>" name="cancel"></td>
  70. </tr>
  71. <tr>
  72. <td><spring:message code="appointment.Appointment.create.label.availbleTimes"/></td>
  73. <td>List of Times</td>
  74. </tr>
  75. <tr>
  76. <td><spring:message code="appointment.Appointment.create.label.reason"/></td>
  77. <td><textarea name="description" rows="3" cols="40" onkeypress="return forceMsaxLength(this, 1024);"></textarea></td>
  78. </tr>
  79. <tr><td><input type="submit" value="<spring:message code="appointment.Appointment.create.save"/>" name="save"></td>
  80. <td><input type="reset" value="<spring:message code="appointment.Appointment.create.cancel"/>" name="cancel"></td>
  81. </tr>
  82. </table>
  83.  
  84. <%@ include file="/WEB-INF/template/footer.jsp" %>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement