Propagate ignore_permissions during mapping from quotation to sales order
This commit is contained in:
parent
201dbbd977
commit
4362443b6e
@ -33,8 +33,9 @@ class SellingController(StockController):
|
||||
|
||||
def set_missing_lead_customer_details(self):
|
||||
if self.doc.customer:
|
||||
from erpnext.accounts.party import get_party_details
|
||||
self.doc.update_if_missing(get_party_details(self.doc.customer))
|
||||
from erpnext.accounts.party import _get_party_details
|
||||
self.doc.update_if_missing(_get_party_details(self.doc.customer,
|
||||
ignore_permissions=self.bean.ignore_permissions))
|
||||
|
||||
elif self.doc.lead:
|
||||
from erpnext.selling.doctype.lead.lead import get_lead_details
|
||||
|
@ -112,6 +112,7 @@ def _make_sales_order(source_name, target_doclist=None, ignore_permissions=False
|
||||
target[0].customer_name = customer.doc.customer_name
|
||||
|
||||
si = frappe.bean(target)
|
||||
si.ignore_permissions = ignore_permissions
|
||||
si.run_method("onload_post_render")
|
||||
|
||||
doclist = get_mapped_doclist("Quotation", source_name, {
|
||||
|
Loading…
Reference in New Issue
Block a user