fix: ignore items without info for pending qty computation
This commit is contained in:
parent
be16fb9dbb
commit
4aa74af90d
@ -608,7 +608,10 @@ function check_can_calculate_pending_qty(me) {
|
|||||||
&& doc.fg_completed_qty
|
&& doc.fg_completed_qty
|
||||||
&& erpnext.stock.bom
|
&& erpnext.stock.bom
|
||||||
&& erpnext.stock.bom.name === doc.bom_no;
|
&& erpnext.stock.bom.name === doc.bom_no;
|
||||||
const itemChecks = !!item && !item.allow_alternative_item;
|
const itemChecks = !!item
|
||||||
|
&& !item.allow_alternative_item
|
||||||
|
&& erpnext.stock.bom && erpnext.stock.items
|
||||||
|
&& (item.item_code in erpnext.stock.bom.items);
|
||||||
return docChecks && itemChecks;
|
return docChecks && itemChecks;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user