from function erp_item_update (erp_item.module)
if (!$node->tax_ex) {
// Convert prices back to ex tax
$node->buy_price = round(array_pop(module_invoke_all('erp_tax_ex_amount', $node->buy_price)), 2);
$node->rrp_price = round(array_pop(module_invoke_all('erp_tax_ex_amount', $node->rrp_price)), 2);
$node->sell_price = round(array_pop(module_invoke_all('erp_tax_ex_amount', $node->sell_price)), 2);
}
this code causes the buy_price of an item node to decrease EVERY time an item node is edited and saved
if (!$node->tax_ex) {
// Convert prices back to ex tax
//$node->buy_price = round(array_pop(module_invoke_all('erp_tax_ex_amount', $node->buy_price)), 2);
$node->rrp_price = round(array_pop(module_invoke_all('erp_tax_ex_amount', $node->rrp_price)), 2);
$node->sell_price = round(array_pop(module_invoke_all('erp_tax_ex_amount', $node->sell_price)), 2);
}
commenting out the line about buy_price line stops it but is this right?
Comments
Comment #1
singularo