blob: fe681548676402e92a5c313cbfbae28c8459a82c [file] [log] [blame]
Rushabh Mehta5f1d57e2012-12-27 14:05:02 +05301import webnotes
2
3def execute():
Anand Doshia773e522012-12-27 18:10:45 +05304 webnotes.reload_doc("utilities", "doctype", "address")
5
Rushabh Mehta5f1d57e2012-12-27 14:05:02 +05306 webnotes.conn.sql("""update tabAddress set address_title = customer_name where ifnull(customer_name,'')!=''""")
7 webnotes.conn.sql("""update tabAddress set address_title = supplier_name where ifnull(supplier_name,'')!=''""")
Anand Doshid9f44e22012-12-27 19:11:04 +05308 webnotes.conn.sql("""update tabAddress set address_title = sales_partner where ifnull(sales_partner,'')!=''""")
9
10 webnotes.reload_doc("website", "doctype", "product_settings")
Rushabh Mehta5f1d57e2012-12-27 14:05:02 +053011 webnotes.reset_perms("Product Settings")
12
13 # move code to new doctype
14 webnotes.conn.set_value("Website Script", None, "javascript",
15 webnotes.conn.get_value("Website Settings", None, "startup_code"))