supplier quotation, project shift patch

This commit is contained in:
Anand Doshi
2012-08-02 18:53:00 +05:30
parent dc40385d41
commit a67a74fee1
17 changed files with 1715 additions and 105 deletions

View File

@@ -0,0 +1,18 @@
def execute():
import webnotes
webnotes.conn.sql("""update `tabPurchase Order Item` t1, `tabPurchase Order` t2
set t1.project_name = t2.project_name where t1.parent = t2.name
and ifnull(t1.project_name, '') = ''""")
webnotes.conn.sql("""update `tabPurchase Invoice Item` t1, `tabPurchase Invoice` t2
set t1.project_name = t2.project_name where t1.parent = t2.name
and ifnull(t1.project_name, '') = ''""")
webnotes.conn.sql("""update `tabPurchase Receipt Item` t1, `tabPurchase Receipt` t2
set t1.project_name = t2.project_name where t1.parent = t2.name
and ifnull(t1.project_name, '') = ''""")
webnotes.conn.commit()
from webnotes.model.sync import sync
sync("buying", "purchase_order")
sync("buying", "purchase_request")
sync("accounts", "purchase_invoice")
webnotes.conn.begin()