]> _ Git - fluidbook-toolbox.git/commitdiff
#7423
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 11 Apr 2025 16:56:42 +0000 (18:56 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 11 Apr 2025 16:56:42 +0000 (18:56 +0200)
app/Http/Controllers/Admin/Operations/FluidbookPublication/Services/PumaOperation.php

index a48a2433f90084a4bd6387fc04b0c3df92c4364c..3505caf9f7b8e860b820c5dada81177471a56783 100644 (file)
@@ -43,8 +43,8 @@ trait PumaOperation
                 continue;
             }
             $r[$reference] = $data;
-            $title = trim(trim($data['Catégorie']) . ' ' . trim($data['RBU']));
-            $subtitle = trim(trim($data['Age Group']) . ' - ' . trim($data['Product Line']), '- ');
+            $title = trim(trim($data['Catégorie']??'') . ' ' . trim($data['RBU']??''));
+            $subtitle = trim(trim($data['Age Group']??'') . ' - ' . trim($data['Product Line']??''), '- ');
             $key = md5($title . $subtitle);
             if (!isset($planches[$key])) {
                 $planches[$key] = ['class' => $data['Catégorie'], 'title' => $title, 'subtitle' => $subtitle, 'products' => []];
@@ -72,9 +72,9 @@ trait PumaOperation
                 $html .= '<img src="' . Files::asDataURI($f) . '">';
                 $html .= '<div class="infos">';
                 $html .= '<h3>' . $reference . '</h3>';
-                $html .= '<div>' . $product['Désignation'] . '</div>';
-                $html .= '<div>' . $product['Color Name'] . '</div>';
-                $html .= '<div>PA : ' . number_format(floatval($product['Tarif']), 2, ',', ' ') . ' € / PVP : ' . number_format(floatval($product['PVC']), 2, ',', ' ') . ' €</div>';
+                $html .= '<div>' . $product['Désignation']??'' . '</div>';
+                $html .= '<div>' . $product['Color Name']??''. '</div>';
+                $html .= '<div>PA : ' . number_format(floatval($product['Tarif']??0), 2, ',', ' ') . ' € / PVP : ' . number_format(floatval($product['PVC']??0), 2, ',', ' ') . ' €</div>';
                 $html .= '</div>';
                 $html .= '</article>';
             }