fix: not able to do overproduction

This commit is contained in:
Rohit Waghchaure
2020-10-12 14:54:54 +05:30
parent 448af6a893
commit 1270c53dea

View File

@@ -611,7 +611,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]));