brotherton-erpnext/patches/january_2013/purchase_price_list.py
2013-01-18 13:07:02 +05:30

9 lines
227 B
Python

import webnotes
def execute():
webnotes.reload_doc("stock", "doctype", "item_price")
# check for selling
webnotes.conn.sql("""update `tabItem Price` set selling=1
where ifnull(selling, 0)=0 and ifnull(buying, 0)=0""")