mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-07 07:02:54 +00:00
Merge pull request #49639 from aerele/credit-limit-jv
fix(Credit-limit): consider current voucher for credit limit validation
This commit is contained in:
@@ -433,3 +433,14 @@ def create_internal_customer(customer_name=None, represents_company=None, allowe
|
||||
customer_name = frappe.db.get_value("Customer", customer_name)
|
||||
|
||||
return customer_name
|
||||
|
||||
|
||||
def make_customer(customer_name):
|
||||
if not frappe.db.exists("Customer", customer_name):
|
||||
customer = frappe.new_doc("Customer")
|
||||
customer.customer_name = customer_name
|
||||
customer.customer_type = "Individual"
|
||||
customer.insert()
|
||||
return customer.name
|
||||
else:
|
||||
return customer_name
|
||||
|
||||
Reference in New Issue
Block a user