diff --git a/erpnext/accounts/report/accounts_receivable/accounts_receivable.py b/erpnext/accounts/report/accounts_receivable/accounts_receivable.py index 1911152dec1..411b31371b2 100755 --- a/erpnext/accounts/report/accounts_receivable/accounts_receivable.py +++ b/erpnext/accounts/report/accounts_receivable/accounts_receivable.py @@ -128,6 +128,7 @@ class ReceivablePayableReport(object): credit_note_in_account_currency=0.0, outstanding_in_account_currency=0.0, ) + self.get_invoices(ple) if self.filters.get("group_by_party"): self.init_subtotal_row(ple.party) diff --git a/erpnext/buying/doctype/purchase_order/purchase_order.js b/erpnext/buying/doctype/purchase_order/purchase_order.js index c635a7fa71a..2b1e3ce9140 100644 --- a/erpnext/buying/doctype/purchase_order/purchase_order.js +++ b/erpnext/buying/doctype/purchase_order/purchase_order.js @@ -455,7 +455,7 @@ erpnext.buying.PurchaseOrderController = class PurchaseOrderController extends e company: me.frm.doc.company }, allow_child_item_selection: true, - child_fielname: "items", + child_fieldname: "items", child_columns: ["item_code", "qty"] }) }, __("Get Items From")); diff --git a/erpnext/public/js/utils.js b/erpnext/public/js/utils.js index 68b3e2e20af..62abb74c340 100755 --- a/erpnext/public/js/utils.js +++ b/erpnext/public/js/utils.js @@ -717,7 +717,7 @@ erpnext.utils.map_current_doc = function(opts) { get_query: opts.get_query, add_filters_group: 1, allow_child_item_selection: opts.allow_child_item_selection, - child_fieldname: opts.child_fielname, + child_fieldname: opts.child_fieldname, child_columns: opts.child_columns, size: opts.size, action: function(selections, args) { diff --git a/erpnext/stock/dashboard/item_dashboard.js b/erpnext/stock/dashboard/item_dashboard.js index c9d5f61f22b..6e7622c067f 100644 --- a/erpnext/stock/dashboard/item_dashboard.js +++ b/erpnext/stock/dashboard/item_dashboard.js @@ -260,6 +260,16 @@ erpnext.stock.move_item = function (item, source, target, actual_qty, rate, call } dialog.set_primary_action(__('Create Stock Entry'), function () { + if (source && (dialog.get_value("qty") == 0 || dialog.get_value("qty") > actual_qty)) { + frappe.msgprint(__("Quantity must be greater than zero, and less or equal to {0}", [actual_qty])); + return; + } + + if (dialog.get_value("source") === dialog.get_value("target")) { + frappe.msgprint(__("Source and target warehouse must be different")); + return; + } + frappe.model.with_doctype('Stock Entry', function () { let doc = frappe.model.get_new_doc('Stock Entry'); doc.from_warehouse = dialog.get_value('source');