[Lada-commits] [PATCH 2 of 2] Fixed ort generation from messprogramme

Wald Commits scm-commit at wald.intevation.org
Fri Jul 10 14:04:03 CEST 2015


# HG changeset patch
# User Raimund Renkert <raimund.renkert at intevation.de>
# Date 1436529836 -7200
# Node ID cd22674b4673f56c9a2a7884463be269aea7bbdc
# Parent  8c486052264ca8d42d6b61d4c06a599440afbf9c
Fixed ort generation from messprogramme.

diff -r 8c486052264c -r cd22674b4673 src/main/java/de/intevation/lada/factory/ProbeFactory.java
--- a/src/main/java/de/intevation/lada/factory/ProbeFactory.java	Fri Jul 10 14:03:27 2015 +0200
+++ b/src/main/java/de/intevation/lada/factory/ProbeFactory.java	Fri Jul 10 14:03:56 2015 +0200
@@ -189,14 +189,14 @@
                 repository.create(wert, "land");
             }
         }
-        if (messprogramm.getGemId() != null &&
-            !messprogramm.getGemId().equals("")) {
+        if (messprogramm.getOrtId() != null &&
+            !messprogramm.getOrtId().equals("")) {
             LOrt ort = new LOrt();
             ort.setOrtsTyp("E");
             ort.setProbeId(probe.getId());
             QueryBuilder<SOrt> ortBuilder = new QueryBuilder<SOrt>(
                 repository.entityManager("stamm"), SOrt.class);
-            ortBuilder.and("verwaltungseinheitId", messprogramm.getGemId());
+            ortBuilder.and("id", messprogramm.getOrtId());
             Response ortResponse = repository.filter(ortBuilder.getQuery(), "stamm");
             @SuppressWarnings("unchecked")
             List<SOrt> orte = (List<SOrt>) ortResponse.getData();


More information about the Lada-commits mailing list