ErpNext AttributeError: module 'erpnext.selling.doctype.customer.customer' has no attribute 'get_customer_list'

Please, can help me with this error?
AttributeError: module ‘erpnext.selling.doctype.customer.customer’ has no attribute ‘get_customer_list’

this is because get_customer_list function is not whitelisted in customer.py file in path ‘erpnext.selling.doctype.customer’. Also check if get_customer_list function is defined outside the class and not inside.

I’m new ussing ErpNext, you can help me whit the script?
Of curse if you know how it is… I would appreciate.

I have a idea, but im not sure.
@frappe.whitelist()
def get_customer_list(ref_doctype):
customer_list = [“Standard”]

customer_list.extend([p.name for p in frappe.get_all("Customer",
    filters={"doc_type": ref_doctype})])

return {
    "customer": customer_list
}

try the following

from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
    
class customer(Document):
	pass

@frappe.whitelist()
def get_customer_list():
    #your uncommented code here

Also run the following bench commands whenever you update the code

bench reload-doctype doctype_name
bench restart

Ok that alone should work?

Ty bro.