Downloads Documentation Community Contribute Demo






Show Sidebar
Login | Register

Changeset 4157

Show
Ignore:
Timestamp:
05/09/08 09:23:56 (2 months ago)
Author:
djazayeri
Message:

Improving error message for 'missing birthdate' in ADT A28 Handler

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openmrs/trunk/src/api/org/openmrs/hl7/handler/ADTA28Handler.java

    r4095 r4157  
    289289                // Date of Birth 
    290290                TS dateOfBirth = pid.getDateTimeOfBirth(); 
    291             if (dateOfBirth == null)   
     291            if (dateOfBirth == null || dateOfBirth.getTime() == null || dateOfBirth.getTime().getValue() == null)      
    292292                        throw new HL7Exception("Missing birth date in the PID segment"); 
    293293                patient.setBirthdate(tsToDate(dateOfBirth));