fix: make contact structure call popup compatible
diff --git a/erpnext/communication/doctype/call_log/call_log.py b/erpnext/communication/doctype/call_log/call_log.py
index c9fdfbe..88965de 100644
--- a/erpnext/communication/doctype/call_log/call_log.py
+++ b/erpnext/communication/doctype/call_log/call_log.py
@@ -70,9 +70,13 @@
numbers = [doc.get('phone'), doc.get('mobile_no')]
for_doc = doc.doctype.lower()
+ # Contact now has all the nos saved in child table
+ if doc.doctype == 'Contact':
+ numbers = [nos.phone for nos in doc.phone_nos]
+
for number in numbers:
if not number: continue
- print(number)
+
filters = frappe._dict({
'from': ['like', '%{}'.format(number.lstrip('0'))],
for_doc: ''
diff --git a/erpnext/crm/doctype/utils.py b/erpnext/crm/doctype/utils.py
index 756b0a2..5553276 100644
--- a/erpnext/crm/doctype/utils.py
+++ b/erpnext/crm/doctype/utils.py
@@ -1,7 +1,6 @@
import frappe
from frappe import _
import json
-from frappe.contacts.doctype.contact.contact import get_contact_with_phone_number
@frappe.whitelist()
def get_last_interaction(contact=None, lead=None):
diff --git a/erpnext/erpnext_integrations/doctype/exotel_settings/exotel_settings.py b/erpnext/erpnext_integrations/doctype/exotel_settings/exotel_settings.py
index 77de84c..6a846ef 100644
--- a/erpnext/erpnext_integrations/doctype/exotel_settings/exotel_settings.py
+++ b/erpnext/erpnext_integrations/doctype/exotel_settings/exotel_settings.py
@@ -3,7 +3,6 @@
# For license information, please see license.txt
from __future__ import unicode_literals
-# import frappe
from frappe.model.document import Document
import requests
import frappe