]> _ Git - bastide-resah.git/commitdiff
wip #6875 @0.5
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 23 Apr 2024 07:55:43 +0000 (09:55 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 23 Apr 2024 07:55:43 +0000 (09:55 +0200)
app/Http/Controllers/FluidbookController.php

index 912157506e50339205af0e7559bf444377909c35..b384fe91e8ae1747c7a8fd550e4ae99e5f48bcee 100644 (file)
@@ -92,11 +92,11 @@ class FluidbookController extends Controller
             $p = $data[$i['reference']];
             $quantity += $i['quantity'];
 
-            $ht = self::parseFloat($p['PV RESAH HT']);
+            $pvht = self::parseFloat($p['PV RESAH HT']);
             $ecotaxe = self::parseFloat($p['ECOTAXE']);
-            $tht = ($ht + $ecotaxe) * $i['quantity'];
-            $tva = $ht * $i['quantity'] * 0.01 * self::parseFloat('TVA');
-            $total += $ht;
+            $tht = ($pvht + $ecotaxe) * $i['quantity'];
+            $tva = $pvht * $i['quantity'] * 0.01 * self::parseFloat($p['TVA']);
+            $total += $tht;
 
             $cumul_tva += $tva;
             $cumul_ecotaxe += $ecotaxe;