Skip to content

Commit

Permalink
Merge pull request #44749 from ruthra-kumar/backport_v14_pr_44581
Browse files Browse the repository at this point in the history
fix: allow all dispatch address for drop ship invoice (backport #44581)
  • Loading branch information
ruthra-kumar authored Dec 17, 2024
2 parents 7e00e55 + 0688c0a commit 13be763
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion erpnext/public/js/queries.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,12 @@ $.extend(erpnext.queries, {
},

dispatch_address_query: function (doc) {
var filters = { link_doctype: "Company", link_name: doc.company || "" };
var is_drop_ship = doc.items.some((item) => item.delivered_by_supplier);
if (is_drop_ship) filters = {};
return {
query: "frappe.contacts.doctype.address.address.address_query",
filters: { link_doctype: "Company", link_name: doc.company || "" },
filters: filters,
};
},

Expand Down

0 comments on commit 13be763

Please sign in to comment.