@@ -637,6 +637,7 @@ def get_buying_amount_from_product_bundle(self, row, product_bundle):
637
637
packed_item_row = row .copy ()
638
638
packed_item_row .warehouse = packed_item .warehouse
639
639
packed_item_row .qty = packed_item .total_qty * - 1
640
+ packed_item_row .serial_and_batch_bundle = packed_item .serial_and_batch_bundle
640
641
buying_amount += self .get_buying_amount (packed_item_row , packed_item .item_code )
641
642
642
643
return flt (buying_amount , self .currency_precision )
@@ -728,6 +729,7 @@ def get_average_buying_rate(self, row, item_code):
728
729
"voucher_no" : row .parent ,
729
730
"allow_zero_valuation" : True ,
730
731
"company" : self .filters .company ,
732
+ "item_code" : item_code ,
731
733
}
732
734
)
733
735
@@ -997,6 +999,7 @@ def get_bundle_item_row(self, row, item):
997
999
"is_return" : row .is_return ,
998
1000
"cost_center" : row .cost_center ,
999
1001
"invoice" : row .parent ,
1002
+ "serial_and_batch_bundle" : row .serial_and_batch_bundle ,
1000
1003
}
1001
1004
)
1002
1005
@@ -1048,6 +1051,7 @@ def load_product_bundle(self):
1048
1051
pki .rate ,
1049
1052
(pki .rate * pki .qty ).as_ ("base_amount" ),
1050
1053
pki .parent_detail_docname ,
1054
+ pki .serial_and_batch_bundle ,
1051
1055
)
1052
1056
.where (pki .docstatus == 1 )
1053
1057
)
0 commit comments