← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20093: dateOfEnrollment -> enrollmentDate

 

------------------------------------------------------------
revno: 20093
committer: Abyot Asalefew Gizaw <abyota@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2015-09-11 17:53:13 +0200
message:
  dateOfEnrollment -> enrollmentDate
modified:
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/AbstractEnrollmentService.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/Enrollment.java
  dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationMultiEventsServiceTest.java
  dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationSingleEventServiceTest.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-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/AbstractEnrollmentService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/AbstractEnrollmentService.java	2015-09-11 11:54:53 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/AbstractEnrollmentService.java	2015-09-11 15:53:13 +0000
@@ -171,7 +171,7 @@
         enrollment.setLastUpdated( programInstance.getLastUpdated() );
         enrollment.setProgram( programInstance.getProgram().getUid() );
         enrollment.setStatus( EnrollmentStatus.fromInt( programInstance.getStatus() ) );
-        enrollment.setDateOfEnrollment( programInstance.getEnrollmentDate() );
+        enrollment.setEnrollmentDate( programInstance.getEnrollmentDate() );
         enrollment.setIncidentDate( programInstance.getIncidentDate() );
         enrollment.setFollowup( programInstance.getFollowup() );
 
@@ -283,7 +283,7 @@
         OrganisationUnit organisationUnit = getOrganisationUnit( enrollment.getOrgUnit() );
 
         ProgramInstance programInstance = programInstanceService.enrollTrackedEntityInstance( entityInstance, program,
-            enrollment.getDateOfEnrollment(), enrollment.getIncidentDate(), organisationUnit, enrollment.getEnrollment() );
+            enrollment.getEnrollmentDate(), enrollment.getIncidentDate(), organisationUnit, enrollment.getEnrollment() );
 
         if ( programInstance == null )
         {
@@ -373,7 +373,7 @@
         programInstance.setProgram( program );
         programInstance.setEntityInstance( entityInstance );
         programInstance.setIncidentDate( enrollment.getIncidentDate() );
-        programInstance.setEnrollmentDate( enrollment.getDateOfEnrollment() );
+        programInstance.setEnrollmentDate( enrollment.getEnrollmentDate() );
         programInstance.setFollowup( enrollment.getFollowup() );
 
         if ( programInstance.getStatus() != enrollment.getStatus().getValue() )

=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/Enrollment.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/Enrollment.java	2015-09-11 11:54:53 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/events/enrollment/Enrollment.java	2015-09-11 15:53:13 +0000
@@ -61,7 +61,7 @@
 
     private String orgUnit;
 
-    private Date dateOfEnrollment;
+    private Date enrollmentDate;
 
     private Date incidentDate;
 
@@ -173,14 +173,14 @@
 
     @JsonProperty( required = true )
     @JacksonXmlProperty( namespace = DxfNamespaces.DXF_2_0 )
-    public Date getDateOfEnrollment()
+    public Date getEnrollmentDate()
     {
-        return dateOfEnrollment;
+        return enrollmentDate;
     }
 
-    public void setDateOfEnrollment( Date dateOfEnrollment )
+    public void setEnrollmentDate( Date enrollmentDate )
     {
-        this.dateOfEnrollment = dateOfEnrollment;
+        this.enrollmentDate = enrollmentDate;
     }
 
     @JsonProperty( required = true )
@@ -240,7 +240,7 @@
         Enrollment that = (Enrollment) o;
 
         if ( attributes != null ? !attributes.equals( that.attributes ) : that.attributes != null ) return false;
-        if ( dateOfEnrollment != null ? !dateOfEnrollment.equals( that.dateOfEnrollment ) : that.dateOfEnrollment != null ) return false;
+        if ( enrollmentDate != null ? !enrollmentDate.equals( that.enrollmentDate ) : that.enrollmentDate != null ) return false;
         if ( incidentDate != null ? !incidentDate.equals( that.incidentDate ) : that.incidentDate != null ) return false;
         if ( enrollment != null ? !enrollment.equals( that.enrollment ) : that.enrollment != null ) return false;
         if ( trackedEntityInstance != null ? !trackedEntityInstance.equals( that.trackedEntityInstance ) : that.trackedEntityInstance != null )
@@ -259,7 +259,7 @@
         result = 31 * result + (trackedEntityInstance != null ? trackedEntityInstance.hashCode() : 0);
         result = 31 * result + (program != null ? program.hashCode() : 0);
         result = 31 * result + (status != null ? status.hashCode() : 0);
-        result = 31 * result + (dateOfEnrollment != null ? dateOfEnrollment.hashCode() : 0);
+        result = 31 * result + (enrollmentDate != null ? enrollmentDate.hashCode() : 0);
         result = 31 * result + (incidentDate != null ? incidentDate.hashCode() : 0);
         result = 31 * result + (attributes != null ? attributes.hashCode() : 0);
         result = 31 * result + (notes != null ? notes.hashCode() : 0);
@@ -274,7 +274,7 @@
             ", trackedEntityInstance='" + trackedEntityInstance + '\'' +
             ", program='" + program + '\'' +
             ", status=" + status +
-            ", dateOfEnrollment=" + dateOfEnrollment +
+            ", dateOfEnrollment=" + enrollmentDate +
             ", incidentDate=" + incidentDate +
             ", attributes=" + attributes +
             ", notes=" + notes +

=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationMultiEventsServiceTest.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationMultiEventsServiceTest.java	2015-09-11 11:54:53 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationMultiEventsServiceTest.java	2015-09-11 15:53:13 +0000
@@ -329,7 +329,7 @@
         enrollment.setOrgUnit( organisationUnitA.getUid() );
         enrollment.setProgram( program );
         enrollment.setTrackedEntityInstance( person );
-        enrollment.setDateOfEnrollment( new Date() );
+        enrollment.setEnrollmentDate( new Date() );
         enrollment.setIncidentDate( new Date() );
 
         return enrollment;

=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationSingleEventServiceTest.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationSingleEventServiceTest.java	2015-09-11 11:54:53 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/events/RegistrationSingleEventServiceTest.java	2015-09-11 15:53:13 +0000
@@ -216,7 +216,7 @@
         enrollment.setOrgUnit( organisationUnitA.getUid() );
         enrollment.setProgram( program );
         enrollment.setTrackedEntityInstance( person );
-        enrollment.setDateOfEnrollment( new Date() );
+        enrollment.setEnrollmentDate( new Date() );
         enrollment.setIncidentDate( new Date() );
 
         return enrollment;