From 6d95d89f29bdb04630ee6f0f16455b1608e24975 Mon Sep 17 00:00:00 2001 From: Frank Schubert Date: Thu, 12 Dec 2024 22:41:38 +0100 Subject: [PATCH] Fixed not returning bbcode when upload bb >300 and <1000 --- application/Admin/functions/RtrReporting.php | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/application/Admin/functions/RtrReporting.php b/application/Admin/functions/RtrReporting.php index 6bf1cba41..d7a200269 100644 --- a/application/Admin/functions/RtrReporting.php +++ b/application/Admin/functions/RtrReporting.php @@ -311,16 +311,16 @@ class Admin_RtrReporting { } if(!$bb_down) { - /*$m = []; - if(preg_match('@\d/\d@', $contract->product_name, $m)) { - - }*/ echo "Keine BB für ".$contract->product_name." ".$contract->id."\n"; exit; } $is_sym = false; + $bb_code = 0; + $bb_code_down = 0; + $bb_code_up = 0; + if($bb_down == $bb_up) { $is_sym = true; $bb_code = $this->getRtrBBCode($bb_down, "sym"); @@ -330,7 +330,6 @@ class Admin_RtrReporting { } - if($contract->termination_id) { $plz = trim($contract->termination->building->zip); $ort = trim($contract->termination->building->city); @@ -348,8 +347,6 @@ class Admin_RtrReporting { $ort = preg_replace('/\s+/', ' ', $ort); $orte = [$ort]; - - if(substr($ort, 0, 4) == "St. " || substr($ort, 0, 4) == "St, ") { $orte[] = preg_replace('/^St[.,]/', "Sankt", $ort); } @@ -422,6 +419,7 @@ class Admin_RtrReporting { } } + $csv_header = "gemid;code;bb;anz_akt_anschl"; $csv = $csv_header."\n"; foreach($data as $gemid => $gem) { @@ -493,7 +491,7 @@ class Admin_RtrReporting { if($bb >= 40 && $bb < 100) return 60; if($bb >= 100 && $bb < 150) return 61; if($bb >= 150 && $bb < 300) return 62; - if($bb >= 3000 && $bb < 1000) return 63; + if($bb >= 300 && $bb < 1000) return 63; if($bb >= 1000) return 64; } @@ -513,7 +511,7 @@ class Admin_RtrReporting { if($bb >= 1000) return 33; } - return 0; + return "x"; } } \ No newline at end of file