← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 12568: Fixed bug - Update person doesn't work

 

------------------------------------------------------------
revno: 12568
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-10-11 11:31:33 +0700
message:
  Fixed bug - Update person doesn't work
modified:
  dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/patient/hibernate/HibernatePatientStore.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientRegistrationList.vm
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/resources/org/hisp/dhis/user/i18n_module.properties


--
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/patient/hibernate/HibernatePatientStore.java'
--- dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/patient/hibernate/HibernatePatientStore.java	2013-10-08 17:16:47 +0000
+++ dhis-2/dhis-services/dhis-service-patient/src/main/java/org/hisp/dhis/patient/hibernate/HibernatePatientStore.java	2013-10-11 04:31:33 +0000
@@ -568,7 +568,7 @@
             {
 
                 String[] keyValues = id.split( " " );
-                patientWhere += patientOperator + "(";
+                patientWhere += patientOperator + " pi.patientidentifiertypeid is not null AND (";
                 String opt = "";
                 for ( String v : keyValues )
                 {

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-10-11 03:57:57 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-10-11 04:31:33 +0000
@@ -1126,24 +1126,7 @@
       url: 'updatePatient.action',
       data: params,
       success: function( json ) {
-			if( getFieldValue('programIdAddPatient')!='')
-			{
-				jQuery.postJSON( "saveProgramEnrollment.action",
-				{
-					patientId: getFieldValue('id'),
-					programId: getFieldValue('programIdAddPatient'),
-					dateOfIncident: jQuery('#patientForm [id=dateOfIncident]').val(),
-					enrollmentDate: jQuery('#patientForm [id=enrollmentDate]').val()
-				}, 
-				function( json ) 
-				{ 
-					showPatientDashboardForm( getFieldValue('id') );
-				});
-			}
-			else
-			{
-				showPatientDashboardForm( getFieldValue('id') );
-			}
+			showPatientDashboardForm( getFieldValue('id') );
       }
      });
 }

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientRegistrationList.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientRegistrationList.vm	2013-10-11 03:57:57 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/patientRegistrationList.vm	2013-10-11 04:31:33 +0000
@@ -19,7 +19,13 @@
 		</td>
 	</tr>
 	<tr>
-		<td class='text-column' >$i18n.getString( "total_result" ): $!total</td>
+		<td class='text-column' >
+			#if( $!total != 0) 
+				$i18n.getString( "total_result" ): $!total 
+			#else 
+				$i18n.getString("no_result_found") 
+			#end
+		</td>
 	</tr>
 </table>
 

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/resources/org/hisp/dhis/user/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/resources/org/hisp/dhis/user/i18n_module.properties	2013-10-10 15:32:40 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-user/src/main/resources/org/hisp/dhis/user/i18n_module.properties	2013-10-11 04:31:33 +0000
@@ -123,7 +123,7 @@
 F_RELATIONSHIPTYPE_UPDATE=Update Relationship Type
 F_ORGANISATION_REGISTRATION=Organisation Unit Registration
 F_PATIENT_REMOVE_EMPTY_EVENTS=Remove Empty Person Events
-F_ACCESS_PATIENT_ATTRIBUTES = View and Search Person identifiers
+F_ACCESS_PATIENT_ATTRIBUTES = View and Search Person Attributes and Identifiers
 F_ALLOW_EDIT_PATIENT_ATTRIBUTES = Add and Edit Person Attributes
 F_ALLOW_EDIT_PATIENT_PROPERTIES = Add and Edit Person Properties
 F_ALLOW_EDIT_PATIENT_IDENTIFIERS = Add and Edit Person Identifiers