mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-08 23:52:57 +00:00
fix: remove bad hardcoded max value
(cherry picked from commit 5f9bd9b8e9)
This commit is contained in:
committed by
Ankush Menat
parent
48acb56cb0
commit
99a1eea982
@@ -685,9 +685,7 @@ class WorkOrder(Document):
|
|||||||
if not d.operation:
|
if not d.operation:
|
||||||
d.operation = operation
|
d.operation = operation
|
||||||
else:
|
else:
|
||||||
# Attribute a big number (999) to idx for sorting putpose in case idx is NULL
|
for item in sorted(item_dict.values(), key=lambda d: d['idx'] or float('inf')):
|
||||||
# For instance in BOM Explosion Item child table, the items coming from sub assembly items
|
|
||||||
for item in sorted(item_dict.values(), key=lambda d: d['idx'] or 9999):
|
|
||||||
self.append('required_items', {
|
self.append('required_items', {
|
||||||
'rate': item.rate,
|
'rate': item.rate,
|
||||||
'amount': item.rate * item.qty,
|
'amount': item.rate * item.qty,
|
||||||
|
|||||||
Reference in New Issue
Block a user