From: Janusz Dobrowolski Date: Wed, 10 Dec 2008 13:12:21 +0000 (+0000) Subject: [0000099] New line added to inventory adjustment/transfer sometimes X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=a8be258327c6ee6b14122219078fe70cc4f849ba;p=textcart.git [0000099] New line added to inventory adjustment/transfer sometimes overwrites old one. --- diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 463b46b..60355f1 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,6 +19,10 @@ Legend: ! -> Note $ -> Affected files +10-Dec-2008 Janusz Dobrowolski +# [0000099] New line added to inventory transfer/adjustment sometimes overwrites old one. +$ /inlucdes/ui/items_cart.inc + 09-Dec-2008 Janusz Dobrowolski # [0000098] Unable issue of credit note for invoice with removed item lines. $ /sales/customer_credit_invoice.php diff --git a/includes/ui/items_cart.inc b/includes/ui/items_cart.inc index a2d3e2d..a526852 100644 --- a/includes/ui/items_cart.inc +++ b/includes/ui/items_cart.inc @@ -67,7 +67,7 @@ class items_cart function remove_from_cart($line_no) { - unset($this->line_items[$line_no]); + array_splice($this->line_items, $line_no, 1); } function count_items() @@ -123,7 +123,7 @@ class items_cart { if (isset($index)) { - unset($this->gl_items[$index]); + array_splice($this->gl_items, $line_no, 1); } }