fix: Wrong key sent to gte_valuation_rate
diff --git a/erpnext/controllers/buying_controller.py b/erpnext/controllers/buying_controller.py
index 608e537..89b48f0 100644
--- a/erpnext/controllers/buying_controller.py
+++ b/erpnext/controllers/buying_controller.py
@@ -349,7 +349,7 @@
 			})
 
 			if not rm.rate:
-				rm.rate = get_valuation_rate(raw_material_data.item_code, self.supplier_warehouse,
+				rm.rate = get_valuation_rate(raw_material_data.rm_item_code, self.supplier_warehouse,
 					self.doctype, self.name, currency=self.company_currency, company=self.company)
 
 		rm.amount = qty * flt(rm.rate)