From c5f60f96c38a0d97ba3b78a2597c438e2e3a5600 Mon Sep 17 00:00:00 2001 From: Frank Schubert Date: Thu, 9 Oct 2025 13:55:55 +0200 Subject: [PATCH] Fixed showing some orders with termination in special orders in Order/Index --- application/Order/OrderController.php | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/application/Order/OrderController.php b/application/Order/OrderController.php index 7a06efd14..986d5ba75 100644 --- a/application/Order/OrderController.php +++ b/application/Order/OrderController.php @@ -225,6 +225,7 @@ class OrderController extends mfBaseController { $has_bras = false; $has_voice = false; + $has_term = false; foreach($order->products as $lop) { if(is_array($lop->product->attributes) && array_key_exists("bras_type", $lop->product->attributes) && $lop->product->attributes['bras_type']) { $has_bras = true; @@ -232,12 +233,20 @@ class OrderController extends mfBaseController { if(is_array($lop->product->attributes) && array_key_exists("voip_chan", $lop->product->attributes) && $lop->product->attributes['voip_chan']) { $has_voice = true; } + if( + is_array($lop->product->attributes) + && array_key_exists("termination_required", $lop->product->attributes) + && $lop->product->attributes['termination_required'] + && $lop->termination_id + ) { + $has_term = true; + } } - if(!$has_bras && !$has_voice) { + if(!$has_bras && !$has_voice && !$has_term) { $special_orders[] = $order; continue; } - if($has_voice && !$has_bras) { + if($has_voice && !$has_bras && !$has_term) { $voice_orders[] = $order; continue; }