Downloads Documentation Community Contribute Demo






Show Sidebar
Login | Register

Changeset 5295

Show
Ignore:
Timestamp:
08/16/08 17:04:55 (3 months ago)
Author:
sunbiz
Message:

registration: Registration Summary Page has same Look & Feel

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openmrs-modules/registration/web/module/registrationSummary.jsp

    r5161 r5295  
    33<link rel="stylesheet" media="all" href="/openmrs/moduleResources/registration/registerPatient.css" /> 
    44<link rel="stylesheet" media="all" href="/openmrs/moduleResources/registration/registrationSummary.css" /> 
    5 <table cellspacing="7" cellpadding="5" align="left"> 
    6     <tr><th colspan="2" class="headerCell">Patient Summary</tr> 
    7     <tr><td class="leftCell">Patient Identifier: </td><td class="rightCell">${summary.identifier}</td></tr> 
    8     <tr><td class="leftCell">Given Name: </td><td class="rightCell">${summary.givenName}</td></tr> 
    9     <tr><td class="leftCell">Middle Name: </td><td class="rightCell">${summary.middleName}</td></tr> 
    10     <tr><td class="leftCell">Family Name: </td><td class="rightCell">${summary.familyName}</td></tr> 
    11     <tr><td class="leftCell">Family Name2: </td><td class="rightCell">${summary.familyName2}</td></tr> 
    12     <tr><td class="leftCell">Gender: </td><td class="rightCell">${summary.gender}</td></tr> 
    13     <tr><td class="leftCell">Age: </td><td class="rightCell">${summary.age}</td></tr> 
    14     <tr><td class="leftCell">Tribe: </td><td class="rightCell">${summary.tribe}</td></tr> 
    15     <tr><td class="leftCell">Address: </td><td class="rightCell">${summary.address1}</td></tr> 
    16     <tr><td class="leftCell">Address 2: </td><td class="rightCell">${summary.address2}</td></tr> 
    17     <tr><td class="leftCell">City/Village: </td><td class="rightCell">${summary.cityVillage}</td></tr> 
    18     <tr><td class="leftCell">County/District: </td><td class="rightCell">${summary.countyDistrict}</td></tr> 
    19     <tr><td class="leftCell">Country: </td><td class="rightCell">${summary.country}</td></tr> 
    20     <tr><td class="leftCell">PostalCode: </td><td class="rightCell">${summary.postalCode}</td></tr> 
    21     <tr><td class="leftCell">Latitude: </td><td class="rightCell">${summary.latitude}</td></tr> 
    22     <tr><td class="leftCell">Longitude: </td><td class="rightCell">${summary.longitude}</td></tr> 
     5<table width="100%" > 
     6  <tr> 
     7    <td> 
     8      <div id="patientDashboardHeader" class="portlet"> 
     9        <div class="boxHeader" id="patientHeader"> 
     10          <div id="patientHeaderPatientName">${summary.givenName} ${summary.middleName} ${summary.familyName}</div> 
     11          <div id="patientHeaderPreferredIdentifier"> <span class="patientHeaderPatientIdentifier"><span id="patientHeaderPatientIdentifierType">Patient Identifier:</span> ${summary.identifier}</span> </div> 
     12          <table id="patientHeaderGeneralInfo"> 
     13            <tbody> 
     14              <tr> 
     15                <td id="patientHeaderPatientGender"> 
     16                  <c:if test="${summary.gender eq 'M'}"> 
     17                    <img id="maleGenderIcon" alt="Male" src="/openmrs/images/male.gif"/> 
     18                  </c:if> 
     19                  <c:if test="${summary.gender eq 'F'}"> 
     20                    <img id="femaleGenderIcon" alt="Female" src="/openmrs/images/female.gif"/> 
     21                  </c:if> 
     22                </td> 
     23                <td id="patientHeaderPatientAge"> ${summary.age} <span id="patientHeaderPatientBirthdate">(${summary.birthdate})</span> </td> 
     24                <td id="patientHeaderPatientTribe"> Tribe: ${summary.tribe} <b/> </td> 
     25                <td id="patientDashboardHeaderExtension"></td> 
     26                <td style="width: 100%;"> </td> 
     27                <td id="patientHeaderOtherIdentifiers"></td> 
     28              </tr> 
     29            </tbody> 
     30          </table> 
     31        </div> 
     32    </div></td> 
     33  </tr> 
     34  <tr> 
     35    <td><div class="boxHeader">Addresses</div> 
     36      <div class="box"> 
     37        <table cellspacing="10" class="personAddress"> 
     38          <thead> 
     39            <th/> 
     40            <th align="center">Address</th> 
     41            <th align="center">Address 2</th> 
     42            <th align="center">City/Village</th> 
     43            <th align="center">State/Province</th> 
     44            <th align="center">Country</th> 
     45            <th align="center">Postal Code</th> 
     46            <th align="center">Latitude</th> 
     47            <th align="center">Longitude</th> 
     48          </thead> 
     49          <tbody> 
     50            <tr> 
     51              <td></td> 
     52              <td align="center"> ${summary.address1} </td> 
     53              <td align="center"> ${summary.address2} </td> 
     54              <td align="center"> ${summary.cityVillage} </td> 
     55              <td align="center"> ${summary.countyDistrict} </td> 
     56              <td align="center"> ${summary.country} </td> 
     57              <td align="center"> ${summary.postalCode} </td> 
     58              <td align="center"> ${summary.latitude} </td> 
     59              <td align="center"> ${summary.longitude} </td> 
     60            </tr> 
     61          </tbody> 
     62        </table> 
     63    </div></td> 
     64  </tr> 
    2365</table> 
    2466<%@ include file="/WEB-INF/template/footer.jsp"%> 
  • openmrs-modules/registration/web/src/org/openmrs/module/registration/web/controller/RegistrationSummaryController.java

    r5161 r5295  
    1414package org.openmrs.module.registration.web.controller; 
    1515 
     16import java.text.DateFormat; 
    1617import java.util.HashMap; 
    1718import java.util.List; 
     
    6667                        map.put("age", age + " yrs."); 
    6768                    } 
     69                    String birthdate = DateFormat.getDateInstance().format(patient.getBirthdate()); 
     70                    if (birthdate != null) { 
     71                        map.put("birthdate", birthdate); 
     72                    } 
    6873                    Tribe tribe = patient.getTribe(); 
    6974                    if (tribe != null) {