mirror of
https://github.com/frappe/erpnext.git
synced 2026-04-13 11:55:11 +00:00
* fix: PO should not be required for internal transfers (#53681)
(cherry picked from commit 5154102468)
# Conflicts:
# erpnext/stock/doctype/purchase_receipt/purchase_receipt.py
* chore: resolve conflicts
* chore: resolve conflicts
* chore: resolve conflicts
---------
Co-authored-by: Mihir Kandoi <kandoimihir@gmail.com>
This commit is contained in:
@@ -328,7 +328,7 @@ class PurchaseReceipt(BuyingController):
|
||||
)
|
||||
|
||||
def po_required(self):
|
||||
if frappe.db.get_value("Buying Settings", None, "po_required") == "Yes":
|
||||
if frappe.db.get_single_value("Buying Settings", "po_required") == "Yes" and not self.is_internal_transfer():
|
||||
for d in self.get("items"):
|
||||
if not d.purchase_order:
|
||||
frappe.throw(_("Purchase Order number required for Item {0}").format(d.item_code))
|
||||
|
||||
Reference in New Issue
Block a user