<commit_before>import webnotes
def execute():
	webnotes.conn.sql("""update `tabQuotation` set customer_name = organization 
		where quotation_to = 'Lead' and ifnull(lead, '') != '' 
		and ifnull(organization, '') != ''""")
	
	webnotes.conn.sql("""update `tabQuotation` set customer_name = lead_name 
		where quotation_to = 'Lead' and ifnull(lead, '') != '' 
		and ifnull(organization, '') = '' and ifnull(lead_name, '') != ''""")
		
	webnotes.conn.sql("""update `tabQuotation` set contact_display = lead_name 
		where quotation_to = 'Lead' and ifnull(lead, '') != '' and ifnull(lead_name, '') != ''""")
		
	webnotes.conn.sql("""update `tabOpportunity` set contact_display = lead_name 
		where enquiry_from = 'Lead' and ifnull(lead, '') != '' and ifnull(lead_name, '') != ''""")<commit_msg>[quotation][improvement] when made from lead<commit_after>import webnotes
def execute():
	webnotes.conn.sql("""update `tabQuotation` set customer_name = organization 
		where quotation_to = 'Lead' and ifnull(lead, '') != '' 
		and ifnull(organization, '') != ''""")
	
	webnotes.conn.sql("""update `tabQuotation` set customer_name = lead_name 
		where quotation_to = 'Lead' and ifnull(lead, '') != '' 
		and ifnull(organization, '') = '' and ifnull(lead_name, '') != ''""")
		
	webnotes.conn.sql("""update `tabQuotation` set contact_display = lead_name 
		where quotation_to = 'Lead' and ifnull(lead, '') != '' and ifnull(lead_name, '') != ''""")
		
	webnotes.conn.sql("""update `tabOpportunity` set contact_display = lead_name 
		where enquiry_from = 'Lead' and ifnull(lead, '') != '' and ifnull(lead_name, '') != ''""")
		
	webnotes.conn.sql("""update `tabOpportunity` opp, `tabLead` lead 
		set opp.customer_name = lead.company_name where opp.lead = lead.name""")
{'fraction_non_alphanumeric': 0.18529076396807298, 'fraction_numerical': 0.0, 'mean_word_length': 5.201413427561837, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6267156', 'n_tokens_mistral': 636, 'n_tokens_neox': 565, 'n_words': 123}