← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 12153: Fixed build error.

 

------------------------------------------------------------
revno: 12153
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2013-09-19 13:06:15 +0700
message:
  Fixed build error.
modified:
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddPatientAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddRelationshipPatientAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/GetPartnerAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveIdentifierAndAttributeAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveRepresentativeAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/UpdatePatientAction.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-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddPatientAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddPatientAction.java	2013-09-12 07:33:02 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddPatientAction.java	2013-09-19 06:06:15 +0000
@@ -308,11 +308,6 @@
                 value = request.getParameter( PREFIX_ATTRIBUTE + attribute.getId() );
                 if ( StringUtils.isNotBlank( value ) )
                 {
-                    if ( !patient.getAttributes().contains( attribute ) )
-                    {
-                        patient.getAttributes().add( attribute );
-                    }
-
                     attributeValue = new PatientAttributeValue();
                     attributeValue.setPatient( patient );
                     attributeValue.setPatientAttribute( attribute );

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddRelationshipPatientAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddRelationshipPatientAction.java	2013-09-18 02:45:29 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/AddRelationshipPatientAction.java	2013-09-19 06:06:15 +0000
@@ -348,11 +348,6 @@
                 value = request.getParameter( PREFIX_ATTRIBUTE + attribute.getId() );
                 if ( StringUtils.isNotBlank( value ) )
                 {
-                    if ( !patient.getAttributes().contains( attribute ) )
-                    {
-                        patient.getAttributes().add( attribute );
-                    }
-
                     attributeValue = new PatientAttributeValue();
                     attributeValue.setPatient( patient );
                     attributeValue.setPatientAttribute( attribute );
@@ -386,7 +381,7 @@
     // -----------------------------------------------------------------------------
     // Getter/Setter
     // -----------------------------------------------------------------------------
-    
+
     public void setPatientIdentifierTypeService( PatientIdentifierTypeService patientIdentifierTypeService )
     {
         this.patientIdentifierTypeService = patientIdentifierTypeService;

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/GetPartnerAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/GetPartnerAction.java	2013-08-23 16:05:01 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/GetPartnerAction.java	2013-09-19 06:06:15 +0000
@@ -33,7 +33,6 @@
 import java.util.Map;
 
 import org.hisp.dhis.patient.Patient;
-import org.hisp.dhis.patient.PatientAttribute;
 import org.hisp.dhis.patient.PatientService;
 import org.hisp.dhis.patientattributevalue.PatientAttributeValue;
 import org.hisp.dhis.patientattributevalue.PatientAttributeValueService;
@@ -149,11 +148,6 @@
             }
         }
 
-        for ( PatientAttribute patientAttribute : partner.getAttributes() )
-        {
-            patientAttributeValueMap.put( patientAttribute.getId(), PatientAttributeValue.UNKNOWN );
-        }
-
         Collection<PatientAttributeValue> patientAttributeValues = patientAttributeValueService
             .getPatientAttributeValues( partner );
 

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveIdentifierAndAttributeAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveIdentifierAndAttributeAction.java	2013-08-23 16:05:01 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveIdentifierAndAttributeAction.java	2013-09-19 06:06:15 +0000
@@ -68,9 +68,9 @@
     private PatientIdentifierService patientIdentifierService;
 
     private PatientAttributeValueService patientAttributeValueService;
-    
+
     private PatientAttributeService patientAttributeService;
-    
+
     private PatientAttributeOptionService patientAttributeOptionService;
 
     private ProgramService programService;
@@ -78,7 +78,7 @@
     // -------------------------------------------------------------------------
     // Input/Output
     // -------------------------------------------------------------------------
-   
+
     private Integer programId;
 
     private Integer patientId;
@@ -234,11 +234,6 @@
                 {
                     attributeValue = patientAttributeValueService.getPatientAttributeValue( patient, attribute );
 
-                    if ( !patient.getAttributes().contains( attribute ) )
-                    {
-                        patient.getAttributes().add( attribute );
-                    }
-
                     if ( attributeValue == null )
                     {
                         attributeValue = new PatientAttributeValue();
@@ -290,7 +285,6 @@
                 else if ( attributeValue != null )
                 {
                     patientAttributeValueService.deletePatientAttributeValue( attributeValue );
-                    patient.getAttributes().remove( attribute );
                 }
             }
         }

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveRepresentativeAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveRepresentativeAction.java	2013-08-23 16:05:01 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SaveRepresentativeAction.java	2013-09-19 06:06:15 +0000
@@ -51,7 +51,7 @@
     {
         this.patientService = patientService;
     }
-    
+
     private PatientAttributeValueService patientAttributeValueService;
 
     public void setPatientAttributeValueService( PatientAttributeValueService patientAttributeValueService )
@@ -104,11 +104,6 @@
         patient.setRepresentative( representative );
         patient.setUnderAge( true );
 
-        if ( copyAttribute )
-        {
-            patient.getAttributes().addAll( representative.getAttributes() );
-        }
-
         patientService.updatePatient( patient );
 
         if ( copyAttribute )

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/UpdatePatientAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/UpdatePatientAction.java	2013-09-12 07:33:02 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/UpdatePatientAction.java	2013-09-19 06:06:15 +0000
@@ -270,7 +270,6 @@
 
         if ( attributes != null && attributes.size() > 0 )
         {
-            patient.getAttributes().clear();
             valuesForDelete = patientAttributeValueService.getPatientAttributeValues( patient );
 
             for ( PatientAttribute attribute : attributes )
@@ -281,11 +280,6 @@
                 {
                     attributeValue = patientAttributeValueService.getPatientAttributeValue( patient, attribute );
 
-                    if ( !patient.getAttributes().contains( attribute ) )
-                    {
-                        patient.getAttributes().add( attribute );
-                    }
-
                     if ( attributeValue == null )
                     {
                         attributeValue = new PatientAttributeValue();