Skip to content

Commit

Permalink
fix: function batch_no should only be declared once (#35115)
Browse files Browse the repository at this point in the history
fix: remove twice event call of `batch_no` to update batch qty
  • Loading branch information
DaizyModi authored May 14, 2023
1 parent 26c5cfa commit 19cd687
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions erpnext/selling/sales_common.js
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,8 @@ erpnext.selling.SellingController = class SellingController extends erpnext.Tran
}

batch_no(doc, cdt, cdn) {
var me = this;
super.batch_no(doc, cdt, cdn);

var item = frappe.get_doc(cdt, cdn);

if (item.serial_no) {
Expand Down Expand Up @@ -378,10 +379,6 @@ erpnext.selling.SellingController = class SellingController extends erpnext.Tran
}
}

batch_no(doc, cdt, cdn) {
super.batch_no(doc, cdt, cdn);
}

qty(doc, cdt, cdn) {
super.qty(doc, cdt, cdn);

Expand Down

0 comments on commit 19cd687

Please sign in to comment.