More Presition to 8 decimals

This commit is contained in:
Lenin Rivas 2020-04-21 01:21:08 -05:00 committed by GitHub
parent f3ebc33d1e
commit b469775718
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,7 @@
<?php
/* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2020 Lenin Rivas <lenin@leninrivas.com>
* Copyright (C) ---Put here your own copyright and developer email---
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -648,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, 4); // Calculate with Qty to produce and more presition
$moline->qty = round($line->qty * ($this->qty / $bom->qty) / $line->efficiency, 8); // Calculate with Qty to produce and more presition
}
if ($moline->qty <= 0) {
$error++;