fix: not able to do overproduction

This commit is contained in:
Rohit Waghchaure 2020-10-12 14:54:54 +05:30
parent 8115be58a3
commit 6471912216

View File

@ -636,7 +636,7 @@ erpnext.work_order = {
description: __('Max: {0}', [max]),
default: max
}, data => {
max += (max * (frm.doc.__onload.overproduction_percentage || 0.0)) / 100;
max += (frm.doc.qty * (frm.doc.__onload.overproduction_percentage || 0.0)) / 100;
if (data.qty > max) {
frappe.msgprint(__('Quantity must not be more than {0}', [max]));