2013-03-11 16:32:33 +05:30
|
|
|
import webnotes
|
|
|
|
|
|
|
|
def execute():
|
|
|
|
dn_list = webnotes.conn.sql("""select name from `tabDelivery Note` where docstatus < 2""")
|
|
|
|
for dn in dn_list:
|
2013-03-26 14:49:25 +05:30
|
|
|
webnotes.bean("Delivery Note", dn[0]).run_method("set_buying_amount")
|
2013-03-11 16:32:33 +05:30
|
|
|
|
|
|
|
si_list = webnotes.conn.sql("""select name from `tabSales Invoice` where docstatus < 2""")
|
|
|
|
for si in si_list:
|
2013-03-26 14:49:25 +05:30
|
|
|
webnotes.bean("Sales Invoice", si[0]).run_method("set_buying_amount")
|