← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 5727: Temporarily remove confirm message for mobile

 

------------------------------------------------------------
revno: 5727
committer: Long <thanhlongngo1988>
branch nick: dhis2
timestamp: Fri 2012-01-13 23:03:02 +0700
message:
  Temporarily remove confirm message for mobile
modified:
  dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.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-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	2012-01-13 07:41:16 +0000
+++ dhis-2/dhis-web/dhis-web-api-mobile/src/main/java/org/hisp/dhis/api/mobile/controller/MobileOrganisationUnitController.java	2012-01-13 16:03:02 +0000
@@ -50,10 +50,6 @@
     @Autowired
     private I18nService i18nService;
 
-    private static final String DATASET_REPORT_IMPORT_SUCCESS_MESSAGE = "dataset_report_imported";
-
-    private static final String TRACKING_REPORT_IMPORT_SUCCESS_MESSAGE = "tracking_report_imported";
-
     @RequestMapping( method = RequestMethod.GET, value = "{id}/all" )
     @ResponseBody
     public MobileModel getAllDataForOrgUnit( @PathVariable int id, @RequestHeader( "accept-language" ) String locale )
@@ -92,12 +88,11 @@
      * @throws NotAllowedException if the {@link DataSetValue} is invalid
      */
     @RequestMapping( method = RequestMethod.POST, value = "     {id}/dataSets" )
-    @ResponseBody
-    public String saveDataSetValues( @PathVariable int id, @RequestBody DataSetValue dataSetValue )
+    @ResponseStatus( value = HttpStatus.NO_CONTENT )
+    public void saveDataSetValues( @PathVariable int id, @RequestBody DataSetValue dataSetValue )
         throws NotAllowedException
     {
         facilityReportingService.saveDataSetValues( getUnit( id ), dataSetValue );
-        return DATASET_REPORT_IMPORT_SUCCESS_MESSAGE;
     }
 
     /**
@@ -108,12 +103,11 @@
      *         is invalid
      */
     @RequestMapping( method = RequestMethod.POST, value = "{id}/activities" )
-    @ResponseBody
-    public String saveActivityReport( @PathVariable int id, @RequestBody ActivityValue activityValue )
+    @ResponseStatus( value = HttpStatus.NO_CONTENT )
+    public void saveActivityReport( @PathVariable int id, @RequestBody ActivityValue activityValue )
         throws NotAllowedException
     {
         activityReportingService.saveActivityReport( getUnit( id ), activityValue );
-        return TRACKING_REPORT_IMPORT_SUCCESS_MESSAGE;
     }
 
     @RequestMapping( method = RequestMethod.POST, value = "{id}/activitiyplan" )