From 0ae0d13f8ba2835933fcd8632b72759f4f87eaa1 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 28 Sep 2021 12:20:02 +0200 Subject: [PATCH] Update mo_production.php --- htdocs/mrp/mo_production.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/htdocs/mrp/mo_production.php b/htdocs/mrp/mo_production.php index ad95164a2af..fe89eef05b3 100644 --- a/htdocs/mrp/mo_production.php +++ b/htdocs/mrp/mo_production.php @@ -946,10 +946,11 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $preselected = 0; } - $disable = 'disabled'; - if ( ($line->qty - $alreadyconsumed) > 0 ) - $disable = ''; - + $disable = ''; + if (!empty($conf->global->MRP_NEVER_CONSUME_MORE_THAN_EXPECTED) && ($line->qty - $alreadyconsumed) <= 0) { + $disable = 'disabled'; + } + print ''; if ($permissiontoupdatecost && !empty($conf->global->MRP_SHOW_COST_FOR_CONSUMPTION)) { print '';