← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 11386: Error when to send sms message from tracker module.

 

------------------------------------------------------------
revno: 11386
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-07-12 13:09:21 +0700
message:
  Error when to send sms message from tracker module.
modified:
  dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SetProgramInstanceStatusAction.java
  dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/reminder/SendSmsAction.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-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java'
--- dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java	2013-01-05 03:03:21 +0000
+++ dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/deletion/DeletionHandler.java	2013-07-12 06:09:21 +0000
@@ -69,6 +69,7 @@
 import org.hisp.dhis.patient.PatientAudit;
 import org.hisp.dhis.patient.PatientIdentifier;
 import org.hisp.dhis.patient.PatientIdentifierType;
+import org.hisp.dhis.patient.PatientRegistrationForm;
 import org.hisp.dhis.patientattributevalue.PatientAttributeValue;
 import org.hisp.dhis.patientdatavalue.PatientDataValue;
 import org.hisp.dhis.period.Period;
@@ -659,6 +660,15 @@
     {
     }
 
+    public String allowDeletePatientRegistrationForm( PatientRegistrationForm patientRegistrationForm )
+    {
+        return null;
+    }
+
+    public void deletePatientRegistrationForm( PatientRegistrationForm patientRegistrationForm )
+    {
+    }
+    
     public String allowDeleteConstant( Constant constant )
     {
         return null;

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SetProgramInstanceStatusAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SetProgramInstanceStatusAction.java	2013-07-12 02:46:16 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/patient/SetProgramInstanceStatusAction.java	2013-07-12 06:09:21 +0000
@@ -253,7 +253,11 @@
         default:
             if ( patient.getPhoneNumber() != null && !patient.getPhoneNumber().isEmpty() )
             {
-                phoneNumbers.add( patient.getPhoneNumber() );
+                String[] _phoneNumbers = patient.getPhoneNumber().split( ";" );
+                for ( String phoneNumber : _phoneNumbers )
+                {
+                    phoneNumbers.add(phoneNumber);
+                }
             }
             break;
         }

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/reminder/SendSmsAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/reminder/SendSmsAction.java	2013-06-20 08:49:00 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/reminder/SendSmsAction.java	2013-07-12 06:09:21 +0000
@@ -131,7 +131,11 @@
         switch ( sendTo )
         {
         case PatientReminder.SEND_TO_PATIENT:
-            phoneNumbers.add( programStageInstance.getProgramInstance().getPatient().getPhoneNumber() );
+            String[] _phoneNumbers = programStageInstance.getProgramInstance().getPatient().getPhoneNumber().split( ";" );
+            for ( String phoneNumber : _phoneNumbers )
+            {
+                phoneNumbers.add(phoneNumber);
+            }
             break;
         case PatientReminder.SEND_TO_HEALTH_WORKER:
             phoneNumbers