mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-09 00:01:18 +00:00
fix: smaller then instead of bigger then :-( dumb mistake (#20693)
* fix: smaller then instead of bigger then :-( dumb mistake * fix: comment on get_all * Update erpnext/projects/doctype/task/task.py Co-Authored-By: Himanshu <himanshuwarekar@yahoo.com> * Update erpnext/projects/doctype/task/task.py Co-Authored-By: Himanshu <himanshuwarekar@yahoo.com> Co-authored-by: Himanshu <himanshuwarekar@yahoo.com>
This commit is contained in:
@@ -199,10 +199,10 @@ def set_multiple_status(names, status):
|
||||
task.save()
|
||||
|
||||
def set_tasks_as_overdue():
|
||||
tasks = frappe.get_all("Task", filters={'status':['not in',['Cancelled', 'Closed']]})
|
||||
tasks = frappe.get_all("Task", filters={"status": ["not in", ["Cancelled", "Closed"]]}, fields=["name", "status", "review_date"])
|
||||
for task in tasks:
|
||||
if frappe.db.get_value("Task", task.name, "status") in 'Pending Review':
|
||||
if getdate(frappe.db.get_value("Task", task.name, "review_date")) < getdate(today()):
|
||||
if task.status == "Pending Review":
|
||||
if getdate(task.review_date) > getdate(today()):
|
||||
continue
|
||||
frappe.get_doc("Task", task.name).update_status()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user