Fixed lead status not updating on Creation of oppurtunity issue

This commit is contained in:
Neil Trini Lasrado 2015-06-29 17:01:32 +05:30
parent a1f1edc786
commit b9e5cd0df4

View File

@ -75,8 +75,7 @@ class Lead(SellingController):
return frappe.db.get_value("Customer", {"lead_name": self.name})
def has_opportunity(self):
return frappe.db.get_value("Opportunity", {"lead": self.name, "docstatus": 1,
"status": ["!=", "Lost"]})
return frappe.db.get_value("Opportunity", {"lead": self.name, "status": ["!=", "Lost"]})
@frappe.whitelist()
def make_customer(source_name, target_doc=None):