Notify assignee when todo deadline is expired feature
mikemix opened this issue · comments
@prolic / @codeliner What's the requirement for this feature?
Am I supposed to subscribe to the event when the todo is marked as expired and notify the assignee about the fact?
@mikemix Exactly. Additionally you need to trigger this event, measure timeout with amqp or a cronjob
What event am I supposed to trigger? Though just adding a subscriber when the MarkTodoAsExpired command is dispatched would be enough.
The MarkTodoAsExpired command is not dispatched! Therefore we need a cronjob or amqp to check expired todos and send the command.
Ah sorry, the script for detecting expired todos is already there (https://github.com/prooph/proophessor-do/blob/master/scripts/mark_expired_todos.php). Sorry!
So you only need to attach a listener to TodoWasMarkedAsExpired and send an email to the user.
Added with #84
We should keep the issue open until it is merged to master.