0002615: Rerun. voiding an allocated currency invoice doesn't clear FX account
authorJoe <unknown>
Fri, 17 Jan 2014 12:38:45 +0000 (13:38 +0100)
committerJoe <unknown>
Fri, 17 Jan 2014 12:38:45 +0000 (13:38 +0100)
sales/includes/db/custalloc_db.inc

index 3010931d59ead0b720cae0fc00f605b2b4084362..1e58c2b149bff69f570729b483b6b9e5d7a848a0 100644 (file)
@@ -78,7 +78,7 @@ function clear_cust_alloctions($type, $type_no, $date="")
                // 2014-01-16 Joe Hunt. Fix for voiding allocated currency sales_invoices.              
                elseif ($type == ST_SALESINVOICE && $row['trans_type_to'] == $type && $row['trans_no_to'] == $type_no)          
                        exchange_variation($row['trans_type_from'], $row['trans_no_from'], $row['trans_type_to'], $row['trans_no_to'], 
-                               sql2date($row['date_alloc']), $row['amt'], PT_SUPPLIER, true);
+                               sql2date($row['date_alloc']), $row['amt'], PT_CUSTOMER, true);
                //////////////////////
        }