Skip to content

Commit

Permalink
fix: Ignore linked purchase invoice on cancel
Browse files Browse the repository at this point in the history
  • Loading branch information
deepeshgarg007 committed Oct 17, 2022
1 parent e543dca commit faadf78
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ erpnext.accounts.PurchaseInvoice = class PurchaseInvoice extends erpnext.buying.
super.onload();

// Ignore linked advances
this.frm.ignore_doctypes_on_cancel_all = ['Journal Entry', 'Payment Entry'];
this.frm.ignore_doctypes_on_cancel_all = ['Journal Entry', 'Payment Entry', 'Purchase Invoice'];

if(!this.frm.doc.__islocal) {
// show credit_to in print format
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1415,6 +1415,7 @@ def on_cancel(self):
"Stock Ledger Entry",
"Repost Item Valuation",
"Payment Ledger Entry",
"Purchase Invoice",
)
self.update_advance_tax_references(cancel=1)

Expand Down

0 comments on commit faadf78

Please sign in to comment.