← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 10977: minor fixes (also fixes compile issues in dhis-web-sms)

 

------------------------------------------------------------
revno: 10977
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-05-24 17:15:02 +0700
message:
  minor fixes (also fixes compile issues in dhis-web-sms)
modified:
  dhis-2/dhis-web/dhis-web-sms/pom.xml
  dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/MenuAction.java
  dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/NoAction.java
  dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/input/SMSInput.java
  dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ProcessingSendSMSAction.java
  dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/SearchPatientAction.java
  dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ShowSendSMSFormAction.java
  dhis-2/dhis-web/dhis-web-sms/src/main/resources/META-INF/dhis/beans.xml
  dhis-2/dhis-web/dhis-web-sms/src/main/resources/struts.xml


--
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-sms/pom.xml'
--- dhis-2/dhis-web/dhis-web-sms/pom.xml	2013-03-22 13:47:40 +0000
+++ dhis-2/dhis-web/dhis-web-sms/pom.xml	2013-05-24 10:15:02 +0000
@@ -21,8 +21,8 @@
     <dependency>
       <groupId>javax.servlet</groupId>
       <artifactId>servlet-api</artifactId>
-	</dependency>
-	
+    </dependency>
+
     <!-- DHIS -->
 
     <dependency>
@@ -50,7 +50,7 @@
       <groupId>org.hisp.dhis</groupId>
       <artifactId>dhis-support-test</artifactId>
     </dependency>
-	    
+
   </dependencies>
 
   <properties>

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/MenuAction.java'
--- dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/MenuAction.java	2012-12-04 23:23:28 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/MenuAction.java	2013-05-24 10:15:02 +0000
@@ -1,5 +1,7 @@
+package org.hisp.dhis.sms.action;
+
 /*
- * Copyright (c) 2004-2012, University of Oslo
+ * Copyright (c) 2004-2013, University of Oslo
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -25,8 +27,6 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-package org.hisp.dhis.sms.action;
-
 import org.hisp.dhis.dataset.DataSet;
 import org.hisp.dhis.dataset.DataSetService;
 import org.hisp.dhis.i18n.I18nFormat;

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/NoAction.java'
--- dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/NoAction.java	2012-06-18 06:14:19 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/action/NoAction.java	2013-05-24 10:15:02 +0000
@@ -1,5 +1,7 @@
+package org.hisp.dhis.sms.action;
+
 /*
- * Copyright (c) 2004-2012, University of Oslo
+ * Copyright (c) 2004-2013, University of Oslo
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -25,8 +27,6 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-package org.hisp.dhis.sms.action;
-
 import com.opensymphony.xwork2.Action;
 
 public class NoAction

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/input/SMSInput.java'
--- dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/input/SMSInput.java	2013-04-03 10:50:16 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/input/SMSInput.java	2013-05-24 10:15:02 +0000
@@ -1,20 +1,44 @@
 package org.hisp.dhis.sms.input;
 
+/*
+ * Copyright (c) 2004-2013, University of Oslo
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright notice, this
+ *   list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright notice,
+ *   this list of conditions and the following disclaimer in the documentation
+ *   and/or other materials provided with the distribution.
+ * * Neither the name of the HISP project nor the names of its contributors may
+ *   be used to endorse or promote products derived from this software without
+ *   specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+import com.opensymphony.xwork2.Action;
 import org.hisp.dhis.sms.incoming.IncomingSms;
 import org.hisp.dhis.sms.incoming.IncomingSmsService;
 import org.hisp.dhis.sms.incoming.SmsMessageEncoding;
 import org.hisp.dhis.sms.incoming.SmsMessageStatus;
 
-import com.opensymphony.xwork2.Action;
-
 /**
- * 
  * @author Christian and Magnus
  */
 public class SMSInput
     implements Action
 {
-
     private String sender, phone, number, msisdn;
 
     private String message, text, content;
@@ -28,7 +52,7 @@
         IncomingSms sms = new IncomingSms();
 
         // setter for sms's originator
-        if ( sender != null)
+        if ( sender != null )
         {
             sms.setOriginator( sender );
         }
@@ -46,7 +70,7 @@
         }
 
         // setter for sms's text
-        if ( message != null)
+        if ( message != null )
         {
             sms.setText( message );
         }
@@ -58,14 +82,14 @@
         {
             sms.setText( content );
         }
-        
+
         // check whether 2 necessary attributes are null 
         if ( sms.getOriginator() == null || sms.getText() == null )
         {
             setNullToAll();
             return ERROR;
         }
-        
+
         java.util.Date rec = new java.util.Date();
         sms.setReceivedDate( rec );
         sms.setSentDate( rec );
@@ -88,7 +112,7 @@
         number = null;
         message = null;
         text = null;
-        content =null;
+        content = null;
     }
 
     public void setSender( String sender )
@@ -100,7 +124,7 @@
     {
         this.phone = phone;
     }
-    
+
     public void setNumber( String number )
     {
         this.number = number;
@@ -115,12 +139,12 @@
     {
         this.message = message;
     }
-    
+
     public void setText( String text )
     {
         this.text = text;
     }
-    
+
     public void setContent( String content )
     {
         this.content = content;

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ProcessingSendSMSAction.java'
--- dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ProcessingSendSMSAction.java	2013-05-20 09:32:19 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ProcessingSendSMSAction.java	2013-05-24 10:15:02 +0000
@@ -1,7 +1,7 @@
 package org.hisp.dhis.sms.outcoming;
 
 /*
- * Copyright (c) 2004-2012, University of Oslo
+ * Copyright (c) 2004-2013, University of Oslo
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -27,14 +27,10 @@
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-import java.io.IOException;
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Set;
-
+import com.opensymphony.xwork2.Action;
 import org.codehaus.jackson.JsonParseException;
+import org.codehaus.jackson.annotate.JsonAutoDetect.Visibility;
 import org.codehaus.jackson.annotate.JsonMethod;
-import org.codehaus.jackson.annotate.JsonAutoDetect.Visibility;
 import org.codehaus.jackson.map.DeserializationConfig;
 import org.codehaus.jackson.map.JsonMappingException;
 import org.codehaus.jackson.map.ObjectMapper;
@@ -44,7 +40,6 @@
 import org.hisp.dhis.oust.manager.SelectionTreeManager;
 import org.hisp.dhis.patient.Patient;
 import org.hisp.dhis.patient.PatientService;
-
 import org.hisp.dhis.sms.outbound.OutboundSmsTransportService;
 import org.hisp.dhis.user.CurrentUserService;
 import org.hisp.dhis.user.User;
@@ -52,7 +47,10 @@
 import org.hisp.dhis.user.UserGroupService;
 import org.springframework.beans.factory.annotation.Autowired;
 
-import com.opensymphony.xwork2.Action;
+import java.io.IOException;
+import java.util.Collection;
+import java.util.HashSet;
+import java.util.Set;
 
 /**
  * @author Dang Duy Hieu
@@ -86,7 +84,7 @@
     {
         this.messageSender = messageSender;
     }
-    
+
     // -------------------------------------------------------------------------
     // Input & Output
     // -------------------------------------------------------------------------
@@ -155,7 +153,7 @@
     // Action Implementation
     // -------------------------------------------------------------------------
 
-    @SuppressWarnings( "unchecked" )
+    @SuppressWarnings("unchecked")
     public String execute()
     {
         gatewayId = transportService.getDefaultGateway();
@@ -175,9 +173,9 @@
         }
 
         User currentUser = currentUserService.getCurrentUser();
-        
+
         Set<User> recipientsList = new HashSet<User>();
-        
+
         if ( sendTarget != null && sendTarget.equals( "phone" ) )
         {
             try
@@ -185,8 +183,8 @@
                 ObjectMapper mapper = new ObjectMapper().setVisibility( JsonMethod.FIELD, Visibility.ANY );
                 mapper.configure( DeserializationConfig.Feature.FAIL_ON_UNKNOWN_PROPERTIES, false );
                 recipients = mapper.readValue( recipients.iterator().next(), Set.class );
-                
-                for( String each: recipients )
+
+                for ( String each : recipients )
                 {
                     User user = new User();
                     user.setPhoneNumber( each );
@@ -207,7 +205,7 @@
             }
             //message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, true, recipients, gatewayId );
             message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, recipientsList, false );
-            
+
         }
         else if ( sendTarget.equals( "userGroup" ) )
         {
@@ -277,7 +275,7 @@
             }
 
             //message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, true, recipients, gatewayId );
-            message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, recipientsList, false);
+            message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, recipientsList, false );
         }
         else
         {
@@ -325,7 +323,7 @@
             }
 
             //message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, true, phones, gatewayId );
-            message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, recipientsList, false);
+            message = messageSender.sendMessage( smsSubject, smsMessage, currentUser, recipientsList, false );
         }
 
         if ( message != null && !message.equals( "success" ) )

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/SearchPatientAction.java'
--- dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/SearchPatientAction.java	2013-03-12 05:40:42 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/SearchPatientAction.java	2013-05-24 10:15:02 +0000
@@ -27,12 +27,6 @@
 
 package org.hisp.dhis.sms.outcoming;
 
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
 import org.hisp.dhis.organisationunit.OrganisationUnit;
 import org.hisp.dhis.ouwt.manager.OrganisationUnitSelectionManager;
 import org.hisp.dhis.paging.ActionPagingSupport;
@@ -43,6 +37,12 @@
 import org.hisp.dhis.program.ProgramService;
 import org.springframework.beans.factory.annotation.Autowired;
 
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
 /**
  * @author Abyot Asalefew Gizaw
  * @version $Id SearchPatientAction.java copyright from SearchPatientAction in case-entry$
@@ -153,7 +153,7 @@
 
             total = patientService.countSearchPatients( searchTexts, organisationUnit );
             this.paging = createPaging( total );
-            patients = patientService.searchPatients( searchTexts, organisationUnit, paging.getStartPos(), paging
+            patients = patientService.searchPatients( searchTexts, organisationUnit, null, paging.getStartPos(), paging
                 .getPageSize() );
 
             if ( !searchBySelectedOrgunit )

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ShowSendSMSFormAction.java'
--- dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ShowSendSMSFormAction.java	2013-03-12 05:40:42 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/java/org/hisp/dhis/sms/outcoming/ShowSendSMSFormAction.java	2013-05-24 10:15:02 +0000
@@ -1,7 +1,7 @@
 package org.hisp.dhis.sms.outcoming;
 
 /*
- * Copyright (c) 2004-2012, University of Oslo
+ * Copyright (c) 2004-2013, University of Oslo
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-sms/src/main/resources/META-INF/dhis/beans.xml	2013-05-20 09:32:19 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/resources/META-INF/dhis/beans.xml	2013-05-24 10:15:02 +0000
@@ -1,26 +1,26 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <beans xmlns="http://www.springframework.org/schema/beans";
-	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
-	xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd";>
-
-	<bean id="org.hisp.dhis.sms.input.SMSInput" class="org.hisp.dhis.sms.input.SMSInput">
-		<property name="incomingSmsService"
-			ref="org.hisp.dhis.sms.incoming.IncomingSmsService" />
-	</bean>
-
-	<bean id="org.hisp.dhis.sms.outcoming.ShowSendSMSFormAction"
-		class="org.hisp.dhis.sms.outcoming.ShowSendSMSFormAction" scope="prototype" />
-
-	<bean id="org.hisp.dhis.sms.outcoming.ShowSendSMSBeneficiaryFormAction"
-		class="org.hisp.dhis.sms.outcoming.ShowSendSMSBeneficiaryFormAction"
-		scope="prototype" />
-
-	<bean id="org.hisp.dhis.sms.outcoming.ProcessingSendSMSAction"
-		class="org.hisp.dhis.sms.outcoming.ProcessingSendSMSAction" scope="prototype">
-		<property name="messageSender" ref="org.hisp.dhis.sms.outbound.SmsSender" />
-	</bean>
-
-	<bean id="org.hisp.dhis.sms.outcoming.SearchPatientAction" class="org.hisp.dhis.sms.outcoming.SearchPatientAction"
-		scope="prototype" />
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+  xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd";>
+
+  <bean id="org.hisp.dhis.sms.input.SMSInput" class="org.hisp.dhis.sms.input.SMSInput">
+    <property name="incomingSmsService"
+      ref="org.hisp.dhis.sms.incoming.IncomingSmsService" />
+  </bean>
+
+  <bean id="org.hisp.dhis.sms.outcoming.ShowSendSMSFormAction"
+    class="org.hisp.dhis.sms.outcoming.ShowSendSMSFormAction" scope="prototype" />
+
+  <bean id="org.hisp.dhis.sms.outcoming.ShowSendSMSBeneficiaryFormAction"
+    class="org.hisp.dhis.sms.outcoming.ShowSendSMSBeneficiaryFormAction"
+    scope="prototype" />
+
+  <bean id="org.hisp.dhis.sms.outcoming.ProcessingSendSMSAction"
+    class="org.hisp.dhis.sms.outcoming.ProcessingSendSMSAction" scope="prototype">
+    <property name="messageSender" ref="org.hisp.dhis.sms.outbound.SmsSender" />
+  </bean>
+
+  <bean id="org.hisp.dhis.sms.outcoming.SearchPatientAction" class="org.hisp.dhis.sms.outcoming.SearchPatientAction"
+    scope="prototype" />
 
 </beans>

=== modified file 'dhis-2/dhis-web/dhis-web-sms/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-sms/src/main/resources/struts.xml	2013-04-17 09:03:38 +0000
+++ dhis-2/dhis-web/dhis-web-sms/src/main/resources/struts.xml	2013-05-24 10:15:02 +0000
@@ -1,86 +1,70 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE struts PUBLIC
-    "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
-    "http://struts.apache.org/dtds/struts-2.0.dtd";>
-<struts>
-	<include file="dhis-web-commons.xml" />
-
-	<package name="dhis-web-sms" extends="dhis-web-commons"
-		namespace="/sms">
-
-		<action name="index" class="org.hisp.dhis.sms.action.NoAction">
-			<result name="success" type="redirect">
-				showSendingSMSForm.action
-			</result>
-		</action>
-
-		<action name="testSMS" class="org.hisp.dhis.sms.action.NoAction">
-			<result name="success" type="velocity">
-				/dhis-web-sms/main.vm
-			</result>
-			<param name="page">/dhis-web-sms/testsms.vm</param>
-		</action>
-
-		<action name="smsinput" class="org.hisp.dhis.sms.input.SMSInput">
-			<result name="success" type="velocity">
-				/dhis-web-sms/smssuccess.vm
-			</result>
-			<result name="error" type="velocity">
-				/dhis-web-sms/smserror.vm
-			</result>
-		</action>
-
-		<!-- Sending SMS Action -->
-
-		<action name="showSendingSMSForm"
-			class="org.hisp.dhis.sms.outcoming.ShowSendSMSFormAction">
-			<result name="success" type="velocity">/main.vm</result>
-			<param name="page">/dhis-web-sms/sendSMSPage.vm</param>
-			<param name="menu">/dhis-web-sms/menu.vm</param>
-			<param name="javascripts">
-				../dhis-web-commons/oust/oust.js,
-				../dhis-web-sms/javascript/sendSMS.js
-			</param>
-			<param name="stylesheets">../dhis-web-sms/css/patient.css</param>
-			<param name="requiredAuthorities">F_MOBILE_SENDSMS</param>
-		</action>
-
-		<action name="showBeneficiarySMSForm"
-			class="org.hisp.dhis.sms.outcoming.ShowSendSMSBeneficiaryFormAction">
-			<result name="success" type="velocity">/main.vm</result>
-			<param name="page">
-				/dhis-web-sms/sendBeneficiarySMSPage.vm
-			</param>
-			<param name="menu">/dhis-web-sms/menuWithTree.vm</param>
-			<param name="javascripts">../dhis-web-commons/ouwt/ouwt.js</param>
-			<param name="stylesheets">../dhis-web-sms/css/patient.css</param>
-			<param name="requiredAuthorities">F_MOBILE_SENDSMS,F_PATIENT_SEARCH</param>
-		</action>
-
-		<action name="searchRegistrationPatient" class="org.hisp.dhis.sms.outcoming.SearchPatientAction">
-			<result name="success" type="velocity">/content.vm</result>
-			<param name="page">
-				/dhis-web-sms/patientRegistrationList.vm
-			</param>
-			<param name="requiredAuthorities">F_PATIENT_SEARCH</param>
-		</action>
-
-		<action name="sendSMS"
-			class="org.hisp.dhis.sms.outcoming.ProcessingSendSMSAction">
-			<result name="success" type="velocity-json">
-				../dhis-web-commons/ajax/jsonResponseSuccess.vm
-			</result>
-			<result name="error" type="velocity-json">
-				../dhis-web-commons/ajax/jsonResponseError.vm
-			</result>
-			<param name="onExceptionReturn">plainTextError</param>
-			<param name="requiredAuthorities">F_MOBILE_SENDSMS</param>
-		</action>
-		<action name="searchAllFacilities" class="org.hisp.dhis.sms.action.NoAction">
-			<result name="success" type="velocity-json">/dhis-web-commons/ajax/jsonResponseSuccess.vm
-			</result>
-			<param name="requiredAuthorities">F_SEARCH_PATIENT_IN_ALL_FACILITIES</param>
-		</action>
-
-	</package>
-</struts>
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE struts PUBLIC
+  "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
+  "http://struts.apache.org/dtds/struts-2.0.dtd";>
+<struts>
+  <include file="dhis-web-commons.xml" />
+
+  <package name="dhis-web-sms" extends="dhis-web-commons"
+    namespace="/sms">
+
+    <action name="index" class="org.hisp.dhis.sms.action.NoAction">
+      <result name="success" type="redirect">showSendingSMSForm.action</result>
+    </action>
+
+    <action name="testSMS" class="org.hisp.dhis.sms.action.NoAction">
+      <result name="success" type="velocity">/dhis-web-sms/main.vm</result>
+      <param name="page">/dhis-web-sms/testsms.vm</param>
+    </action>
+
+    <action name="smsinput" class="org.hisp.dhis.sms.input.SMSInput">
+      <result name="success" type="velocity">/dhis-web-sms/smssuccess.vm</result>
+      <result name="error" type="velocity">/dhis-web-sms/smserror.vm</result>
+    </action>
+
+    <!-- Sending SMS Action -->
+
+    <action name="showSendingSMSForm"
+      class="org.hisp.dhis.sms.outcoming.ShowSendSMSFormAction">
+      <result name="success" type="velocity">/main.vm</result>
+      <param name="page">/dhis-web-sms/sendSMSPage.vm</param>
+      <param name="menu">/dhis-web-sms/menu.vm</param>
+      <param name="javascripts">
+        ../dhis-web-commons/oust/oust.js,
+        ../dhis-web-sms/javascript/sendSMS.js
+      </param>
+      <param name="stylesheets">../dhis-web-sms/css/patient.css</param>
+      <param name="requiredAuthorities">F_MOBILE_SENDSMS</param>
+    </action>
+
+    <action name="showBeneficiarySMSForm"
+      class="org.hisp.dhis.sms.outcoming.ShowSendSMSBeneficiaryFormAction">
+      <result name="success" type="velocity">/main.vm</result>
+      <param name="page">/dhis-web-sms/sendBeneficiarySMSPage.vm</param>
+      <param name="menu">/dhis-web-sms/menuWithTree.vm</param>
+      <param name="javascripts">../dhis-web-commons/ouwt/ouwt.js</param>
+      <param name="stylesheets">../dhis-web-sms/css/patient.css</param>
+      <param name="requiredAuthorities">F_MOBILE_SENDSMS,F_PATIENT_SEARCH</param>
+    </action>
+
+    <action name="searchRegistrationPatient" class="org.hisp.dhis.sms.outcoming.SearchPatientAction">
+      <result name="success" type="velocity">/content.vm</result>
+      <param name="page">/dhis-web-sms/patientRegistrationList.vm</param>
+      <param name="requiredAuthorities">F_PATIENT_SEARCH</param>
+    </action>
+
+    <action name="sendSMS"
+      class="org.hisp.dhis.sms.outcoming.ProcessingSendSMSAction">
+      <result name="success" type="velocity-json">../dhis-web-commons/ajax/jsonResponseSuccess.vm</result>
+      <result name="error" type="velocity-json">../dhis-web-commons/ajax/jsonResponseError.vm</result>
+      <param name="onExceptionReturn">plainTextError</param>
+      <param name="requiredAuthorities">F_MOBILE_SENDSMS</param>
+    </action>
+    <action name="searchAllFacilities" class="org.hisp.dhis.sms.action.NoAction">
+      <result name="success" type="velocity-json">/dhis-web-commons/ajax/jsonResponseSuccess.vm
+      </result>
+      <param name="requiredAuthorities">F_SEARCH_PATIENT_IN_ALL_FACILITIES</param>
+    </action>
+
+  </package>
+</struts>