-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Todo reminder notification #73
Conversation
…gnee. includes worker script, Command, Event and a new projection
… echos out that it sent an email
The read model is used by the send_reminder_notification worker.
/** | ||
* This script looks for todos with open reminders and reminds the assignees | ||
*/ | ||
namespace { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should have proophessor-do namespace, no?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just tried to match the other scripts in the folder. Dont mind adding the namespace
…d which is stored anyway
e7c42c9
to
d193a42
Compare
atm I can't install Zend\Mail because of zendframework/zend-mime#10. In the meantime is there anything else I can do with this PR or are you guys happy with it as it is? |
Alright. I added Zend\Mail to send actual mails. |
Writing this I realized mail_connection.local.php.dist is a much better name |
@rommsen PR looks great. I'll take a deeper look and test it at the weekend |
return new self( | ||
new \DateTimeImmutable($reminder, new \DateTimeZone('UTC')), | ||
TodoReminderStatus::fromString($status) | ||
); | ||
} | ||
|
||
/** | ||
* @param string $reminder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
\DateTimeImmutable
This is a follow up to #71 (PR to wrong branch).
Compared to the old pull request I added a distinct read model for todo reminders. This read model is used by the worker to get reminders that should be used for notification.
To run the worker with docker:
docker-compose run --rm php php ./scripts/send_reminder_notification.php