fix: Rate for items with no batch
diff --git a/erpnext/public/js/controllers/buying.js b/erpnext/public/js/controllers/buying.js
index e5be499..a537b86 100644
--- a/erpnext/public/js/controllers/buying.js
+++ b/erpnext/public/js/controllers/buying.js
@@ -194,6 +194,10 @@
this._super(doc, cdt, cdn);
},
+ batch_no: function(doc, cdt, cdn) {
+ this._super(doc, cdt, cdn);
+ },
+
received_qty: function(doc, cdt, cdn) {
this.calculate_accepted_qty(doc, cdt, cdn)
},
diff --git a/erpnext/public/js/controllers/transaction.js b/erpnext/public/js/controllers/transaction.js
index 3dcec89..4a9ecd7 100644
--- a/erpnext/public/js/controllers/transaction.js
+++ b/erpnext/public/js/controllers/transaction.js
@@ -1105,7 +1105,7 @@
batch_no: function(doc, cdt, cdn) {
let item = frappe.get_doc(cdt, cdn);
- this.apply_pricing_rule(item, true);
+ this.apply_price_list(item, true);
},
toggle_conversion_factor: function(item) {
@@ -1412,6 +1412,7 @@
"pricing_rules": d.pricing_rules,
"warehouse": d.warehouse,
"serial_no": d.serial_no,
+ "batch_no": d.batch_no,
"price_list_rate": d.price_list_rate,
"conversion_factor": d.conversion_factor || 1.0
});