Update project.py

This commit is contained in:
rohitwaghchaure 2019-05-10 12:03:20 +05:30 committed by GitHub
parent 6b9543b213
commit 490411ba28
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -514,6 +514,7 @@ def allow_to_make_project_update(project, time, frequency):
data = frappe.db.sql(""" SELECT name from `tabProject Update` data = frappe.db.sql(""" SELECT name from `tabProject Update`
WHERE project = %s and date = %s """, (project, today())) WHERE project = %s and date = %s """, (project, today()))
# len(data) > 1 condition is checked for twicely frequency
if data and (frequency in ['Daily', 'Weekly'] or len(data) > 1): if data and (frequency in ['Daily', 'Weekly'] or len(data) > 1):
return False return False