fix: Missing args while fetching items from delivery note

(cherry picked from commit bbe323fbb4)
This commit is contained in:
Nabin Hait
2024-04-22 16:28:31 +05:30
committed by Mergify
parent c71d1118a9
commit 0df80ad923
2 changed files with 9 additions and 6 deletions

View File

@@ -823,11 +823,14 @@ erpnext.utils.map_current_doc = function (opts) {
if (opts.source_doctype) {
let data_fields = [];
if (["Purchase Receipt", "Delivery Note"].includes(opts.source_doctype)) {
data_fields.push({
fieldname: "merge_taxes",
fieldtype: "Check",
label: __("Merge taxes from multiple documents"),
});
let target_meta = frappe.get_meta(cur_frm.doc.doctype);
if (target_meta.fields.find((f) => f.fieldname === "taxes")) {
data_fields.push({
fieldname: "merge_taxes",
fieldtype: "Check",
label: __("Merge taxes from multiple documents"),
});
}
}
const d = new frappe.ui.form.MultiSelectDialog({
doctype: opts.source_doctype,

View File

@@ -772,7 +772,7 @@ def make_delivery_trip(source_name, target_doc=None):
@frappe.whitelist()
def make_installation_note(source_name, target_doc=None):
def make_installation_note(source_name, target_doc=None, kwargs=None):
def update_item(obj, target, source_parent):
target.qty = flt(obj.qty) - flt(obj.installed_qty)
target.serial_no = obj.serial_no