The refresh interval should be the same as for the list of tasks with auto-refresh enabled (10 seconds). Actually, the two requests for the list of tasks and for the single task should be in sync with each other, otherwise a task may be removed from the list but is still enabled in the detail view or vice-versa. A (potentially) naive idea would be to use the system time to synchronize the two intervals, e.g. doing a request whenever the system clock displays xx:xx:x0.
The message to close the task should be more descriptive, e.g. "Close Task", instead of just "Dismiss" as dismiss can be misinterpret as "Dismiss this notification only".
I am not sure our standard notification system is the best choice for displaying the notification. Right now we run into the following problem:
- open task detail view-utils
- open process start process modal
- task is completed
- notification is displayed in the process start modal
(same with edit filter and probably also other modals)
Maybe we need a dedicated place in the task detail view itself to display the notification.
There is a lot of whitespace in the task file. Maybe we should have a comment instead to mark the begin and end of the task observation logic.
We should also disable the Complete button of the task form when we notice that the task does not exist anymore
Wouldn't it be better to have the task details "frozen" or even better IMVHO simply hidden rather than allowing the user to close?
It might be surprising for the user and appear to be a bit radical / brutal, sure, but in the end and whatever, the user has to pick a new task to complete...
Selecting the next task automatically would be to much though.