Skip to content

Commit

Permalink
fix: include start and end date for contract status (#18865)
Browse files Browse the repository at this point in the history
  • Loading branch information
Alchez authored and nabinhait committed Sep 3, 2019
1 parent fea9963 commit f800050
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion erpnext/crm/doctype/contract/contract.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def get_status(start_date, end_date):
end_date = getdate(end_date)
now_date = getdate(nowdate())

return "Active" if start_date < now_date < end_date else "Inactive"
return "Active" if start_date <= now_date <= end_date else "Inactive"


def update_status_for_contracts():
Expand Down

0 comments on commit f800050

Please sign in to comment.