Sort issues in a filter by due date (or today's date if due date blank)
I want to sort issues in a filter by due date then "review date" (custom field), but where the due date and/or review date is blank, assume the current date and time.
Logic ideally is:
if duedate is blank then set field to current date and time otherwise if due date within four days of current date and time return due date - three days otherwise return due date
Is this possible? I've used calculated date fields but get issues with sort ordering.