fix: contact page not loading
This commit is contained in:
parent
20d16c6a32
commit
cef20e37c2
@ -30,15 +30,7 @@ def get_contact(name):
|
|||||||
|
|
||||||
if not len(contact):
|
if not len(contact):
|
||||||
frappe.throw(_("Contact not found"), frappe.DoesNotExistError)
|
frappe.throw(_("Contact not found"), frappe.DoesNotExistError)
|
||||||
contact = contact.pop()
|
|
||||||
|
|
||||||
contact["doctype"] = "Contact"
|
|
||||||
contact["email_ids"] = frappe.get_all(
|
|
||||||
"Contact Email", filters={"parent": name}, fields=["name", "email_id", "is_primary"]
|
|
||||||
)
|
|
||||||
contact["phone_nos"] = frappe.get_all(
|
|
||||||
"Contact Phone", filters={"parent": name}, fields=["name", "phone", "is_primary_mobile_no"]
|
|
||||||
)
|
|
||||||
return contact
|
return contact
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user