=== modified file 'dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java' --- dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java 2014-06-03 12:31:25 +0000 +++ dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java 2014-06-04 10:34:54 +0000 @@ -365,7 +365,7 @@ { return activityReportingService.findPatient( Integer.parseInt( patientId ) ); } - + @RequestMapping( method = RequestMethod.GET, value = "{clientVersion}/LWUIT/orgUnits/{id}/findPatients" ) @ResponseBody public PatientList findPatientsById( @PathVariable @@ -638,7 +638,7 @@ return activityReportingService.replyMessage( message ); } - + @RequestMapping( method = RequestMethod.POST, value = "{clientVersion}/LWUIT/orgUnits/{id}/sendFeedback" ) @ResponseBody public String sendFeedbackTracker( @PathVariable @@ -650,4 +650,26 @@ } + @RequestMapping( method = RequestMethod.GET, value = "{clientVersion}/LWUIT/orgUnits/{id}/findUser" ) + @ResponseBody + public Recipient findUserTracker( String clientVersion, @PathVariable + int id, @RequestHeader( "name" ) + String keyword ) + throws NotAllowedException + { + Recipient recipient = new Recipient(); + recipient.setUsers( activityReportingService.findUser( keyword ) ); + return recipient; + } + + @RequestMapping( method = RequestMethod.POST, value = "{clientVersion}/LWUIT/orgUnits/{id}/sendMessage" ) + @ResponseBody + public String sendMessageTracker( @PathVariable + int id, @RequestBody + Message message ) + throws NotAllowedException + { + return activityReportingService.sendMessage( message ); + } + }