From a930da533e83fbbdfd59323079ec81e48fdc694f Mon Sep 17 00:00:00 2001 From: Paul Date: Tue, 5 Sep 2023 23:04:56 +0200 Subject: [PATCH] wrong UUID --- .../console/service/TransactionService.java | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/src/main/java/eu/heliumiot/console/service/TransactionService.java b/src/main/java/eu/heliumiot/console/service/TransactionService.java index 9b59310c..d25f24c8 100644 --- a/src/main/java/eu/heliumiot/console/service/TransactionService.java +++ b/src/main/java/eu/heliumiot/console/service/TransactionService.java @@ -529,14 +529,16 @@ public TransactionConfigRespItf getTransactionSetup() { contentStream.endText(); // Get tenant - Tenant tenant = heliumTenantService.getTenant( UUID.fromString(t.getSourceTenantUUID()) ); - if ( tenant != null ) { - contentStream.moveTo(0, 0); - contentStream.beginText(); - contentStream.setFont(PDType1Font.TIMES_BOLD, 12); - contentStream.newLineAtOffset(300, 718); - contentStream.showText("Tenant NAME: " + tenant.getName()); - contentStream.endText(); + if ( t.getTargetTenantUUID() != null ) { + Tenant tenant = heliumTenantService.getTenant(UUID.fromString(t.getTargetTenantUUID())); + if (tenant != null) { + contentStream.moveTo(0, 0); + contentStream.beginText(); + contentStream.setFont(PDType1Font.TIMES_BOLD, 12); + contentStream.newLineAtOffset(300, 718); + contentStream.showText("Tenant NAME: " + tenant.getName()); + contentStream.endText(); + } } // date