From: Maxime Bourget Date: Sun, 26 May 2013 17:32:45 +0000 (+0100) Subject: Fix discount and parenthesis X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=42e69c0aabcfcc8891e55db7b43456314a3e41d1;p=textcart.git Fix discount and parenthesis Now parse line return the *raw* discount (instead of /100). Meaning its treated exactly as the other. Before formula where converted to integer (/100) before being expanded or evaluated. --- diff --git a/includes/textcart_manager.inc b/includes/textcart_manager.inc index c0f1bfb..45acd24 100644 --- a/includes/textcart_manager.inc +++ b/includes/textcart_manager.inc @@ -223,6 +223,9 @@ class TextCartManager { } + // convert the percentage to float. + if($discount) $discount /= 100; + #echo "Stock Code : $stock_code