From 6581ef944988ba1cd42d62926ae086918cd37dcb Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Fri, 8 Jun 2012 18:19:32 +0530 Subject: [PATCH] fetch organization from lead to quote --- erpnext/patches/june_2012/fetch_organization_from_lead.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/patches/june_2012/fetch_organization_from_lead.py b/erpnext/patches/june_2012/fetch_organization_from_lead.py index fe178dd746..1d2485289a 100644 --- a/erpnext/patches/june_2012/fetch_organization_from_lead.py +++ b/erpnext/patches/june_2012/fetch_organization_from_lead.py @@ -1,3 +1,3 @@ def execute(): import webnotes - webnotes.conn.sql("update `tabQuotation` t1, `tabLead` t2 set t1.organization = t2.company_name where ifnull(t1.lead, '') = '' and t1.quotation_to = 'Lead' and ifnull(t1.organization, '') = '' and t1.lead = t2.name") \ No newline at end of file + webnotes.conn.sql("update `tabQuotation` t1, `tabLead` t2 set t1.organization = t2.company_name where ifnull(t1.lead, '') != '' and t1.quotation_to = 'Lead' and ifnull(t1.organization, '') = '' and t1.lead = t2.name") \ No newline at end of file