From 9249628ff47e96b0cb12f68729eccbae9217995b Mon Sep 17 00:00:00 2001 From: bsiggel Date: Sun, 25 Jan 2026 14:25:11 +0100 Subject: [PATCH] =?UTF-8?q?feat:=20Update=20eviction=20lawsuit=20naming=20?= =?UTF-8?q?to=20use=20first=20Mietverh=C3=A4ltnis=20if=20available?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- custom/Espo/Custom/Services/CKuendigung.php | 8 +++++++- custom/Espo/Custom/Services/CVmhMietverhltnis.php | 4 +++- data/config.php | 4 ++-- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/custom/Espo/Custom/Services/CKuendigung.php b/custom/Espo/Custom/Services/CKuendigung.php index 7b1ae787..46a65954 100644 --- a/custom/Espo/Custom/Services/CKuendigung.php +++ b/custom/Espo/Custom/Services/CKuendigung.php @@ -83,7 +83,13 @@ class CKuendigung extends \Espo\Services\Record // 7. Prepare data for new Räumungsklage $data = new \stdClass(); - $data->name = 'Räumungsklage - ' . $kuendigung->get('name'); + + // Use name from first Mietverhältnis (or fallback to Kündigung) + if (!empty($alleMietverhaeltnisse)) { + $data->name = 'Räumungsklage - ' . $alleMietverhaeltnisse[0]->get('name'); + } else { + $data->name = 'Räumungsklage - ' . $kuendigung->get('name'); + } // Copy Advoware fields if found if ($advowareAktenzeichen) { diff --git a/custom/Espo/Custom/Services/CVmhMietverhltnis.php b/custom/Espo/Custom/Services/CVmhMietverhltnis.php index c143579b..1c8cab0e 100644 --- a/custom/Espo/Custom/Services/CVmhMietverhltnis.php +++ b/custom/Espo/Custom/Services/CVmhMietverhltnis.php @@ -68,7 +68,9 @@ class CVmhMietverhltnis extends \Espo\Services\Record // 7. Prepare data for new Räumungsklage $data = new \stdClass(); - $data->name = 'Räumungsklage - ' . $mietverhaeltnis->get('name'); + + // Use name from first Mietverhältnis + $data->name = 'Räumungsklage - ' . $alleMietverhaeltnisse[0]->get('name'); // Copy Advoware fields if found if ($advowareAktenzeichen) { diff --git a/data/config.php b/data/config.php index d1619539..cace27b7 100644 --- a/data/config.php +++ b/data/config.php @@ -361,8 +361,8 @@ return [ 0 => 'youtube.com', 1 => 'google.com' ], - 'cacheTimestamp' => 1769346856, - 'microtime' => 1769346856.162518, + 'cacheTimestamp' => 1769347057, + 'microtime' => 1769347057.472966, 'siteUrl' => 'https://crm.bitbylaw.com', 'fullTextSearchMinLength' => 4, 'appTimestamp' => 1768843902,