changeset 860:7c6b7c08d31d

Allow GET for status objects with messungsId.
author Raimund Renkert <raimund.renkert@intevation.de>
date Wed, 03 Feb 2016 13:34:32 +0100
parents 0e895f13f0b6
children 68348c675b13
files src/main/java/de/intevation/lada/rest/StatusService.java
diffstat 1 files changed, 1 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/src/main/java/de/intevation/lada/rest/StatusService.java	Tue Feb 02 15:33:24 2016 +0100
+++ b/src/main/java/de/intevation/lada/rest/StatusService.java	Wed Feb 03 13:34:32 2016 +0100
@@ -147,23 +147,12 @@
         catch(NumberFormatException nfe) {
             return new Response(false, 698, null);
         }
-        LMessung messung = defaultRepo.getByIdPlain(
-            LMessung.class,
-            id,
-            "land");
-        if (!authorization.isAuthorized(
-            request,
-            messung,
-            RequestMethod.GET,
-            LMessung.class)) {
-            return new Response(false, 697, null);
-        }
 
         QueryBuilder<LStatusProtokoll> builder =
             new QueryBuilder<LStatusProtokoll>(
                 defaultRepo.entityManager("land"),
                 LStatusProtokoll.class);
-        builder.and("messungsId", messungId);
+        builder.and("messungsId", id);
         return authorization.filter(
             request,
             defaultRepo.filter(builder.getQuery(), "land"),
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)