Update mo.class.php
Use the accuracy of stock for rounding
This commit is contained in:
parent
b469775718
commit
1788b1b252
@ -649,7 +649,7 @@ class Mo extends CommonObject
|
||||
if ($line->qty_frozen) {
|
||||
$moline->qty = $line->qty; // Qty to consume does not depends on quantity to produce
|
||||
} else {
|
||||
$moline->qty = round($line->qty * ($this->qty / $bom->qty) / $line->efficiency, 8); // Calculate with Qty to produce and more presition
|
||||
$moline->qty = price2num(($line->qty / $bom->qty) * $this->qty / $line->efficiency, 'MS'); // Calculate with Qty to produce and more presition
|
||||
}
|
||||
if ($moline->qty <= 0) {
|
||||
$error++;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user