← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 11481: Exception thrown when opening Program-report tab in Dashboard.

 

------------------------------------------------------------
revno: 11481
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2013-07-23 10:14:03 +0700
message:
  Exception thrown when opening Program-report tab in Dashboard.
modified:
  dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramInstanceService.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramInstanceService.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramInstanceService.java	2013-06-21 12:46:21 +0000
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/program/DefaultProgramInstanceService.java	2013-07-23 03:14:03 +0000
@@ -396,12 +396,18 @@
             {
                 for ( PatientIdentifier identifier : identifiers )
                 {
-                    if ( identifier.getIdentifierType().equals( identifierType ) )
+                    if (  identifier.getIdentifierType() != null && identifier.getIdentifierType().equals( identifierType ) )
                     {
                         grid.addRow();
                         grid.addValue( identifierType.getDisplayName() );
                         grid.addValue( identifier.getIdentifier() );
                     }
+                    else if (  identifier.getIdentifierType() == null )
+                    {
+                        grid.addRow();
+                        grid.addValue( i18n.getString( "system_identifier" ));
+                        grid.addValue( identifier.getIdentifier() );
+                    }
                 }
             }
         }