diff --git a/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/EnrollmentController.java b/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/EnrollmentController.java index 57c584d1135e..b956c981cae1 100644 --- a/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/EnrollmentController.java +++ b/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/EnrollmentController.java @@ -230,7 +230,7 @@ public WebMessage postEnrollmentJson( if (!importSummary.getStatus().equals(ImportStatus.ERROR)) { importSummaries(importSummaries) .setHttpStatus(HttpStatus.CREATED) - .setLocation("enrollments/" + importSummary.getReference()); + .setLocation("/enrollments/" + importSummary.getReference()); } } @@ -277,7 +277,7 @@ public WebMessage postEnrollmentXml( if (!importSummary.getStatus().equals(ImportStatus.ERROR)) { importSummaries(importSummaries) .setHttpStatus(HttpStatus.CREATED) - .setLocation("enrollments/" + importSummary.getReference()); + .setLocation("/enrollments/" + importSummary.getReference()); } } diff --git a/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/TrackedEntityInstanceController.java b/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/TrackedEntityInstanceController.java index ce3cb7272ef9..6a5cc195034a 100644 --- a/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/TrackedEntityInstanceController.java +++ b/dhis-2/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/event/TrackedEntityInstanceController.java @@ -398,7 +398,7 @@ private WebMessage postTrackedEntityInstance( .setLocation( singleSummary == null ? null - : "trackedEntityInstances/" + singleSummary.getReference()); + : "/trackedEntityInstances/" + singleSummary.getReference()); } return jobConfigurationReport(jobId).setLocation("/system/tasks/" + TEI_IMPORT); }