Merge pull request #3369 from anandpdoshi/anand-may-27
Check if company exists in re-order item
This commit is contained in:
commit
960118a954
@ -7,7 +7,7 @@ from frappe.utils import flt, cstr, nowdate, add_days, cint
|
||||
def reorder_item():
|
||||
""" Reorder item if stock reaches reorder level"""
|
||||
# if initial setup not completed, return
|
||||
if not frappe.db.sql("select name from `tabFiscal Year` limit 1"):
|
||||
if not (frappe.db.a_row_exists("Company") and frappe.db.a_row_exists("Fiscal Year")):
|
||||
return
|
||||
|
||||
if cint(frappe.db.get_value('Stock Settings', None, 'auto_indent')):
|
||||
|
Loading…
x
Reference in New Issue
Block a user