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
Send unique notification via Email per user #28
Conversation
Conflicts: tests/ScrumMasterTest/Functional/EmailNotifierCommandTest.php
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.
Awesome :)) 👍
@@ -66,7 +66,7 @@ private function postToSlack(Company $company, array $tickets, array $jiraUsersT | |||
|
|||
$response = $this->slackClient->postToChannel( | |||
$this->slackMapping->toSlackId($ticket->assignee()->name()), | |||
$this->messageGenerator->forJiraTicket($ticket, $company->companyName()) | |||
$this->messageGenerator->forJiraTickets([$ticket], $company->companyName()) |
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.
Why in the email you pass an array and here you transform the $thicket
var into an array manually?
I mean, what is the difference between slack and email and why $ticket
is not already an array?
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.
Because this issue (PR) was thinking in a way of pure Email\Channel
, without modifying (or at least as less at possible) the Slack\Channel
.
Actually, I/we might create another PR where we are doing this same feature-idea to the Slack\Channel
as well.
BUT in order to keep it simple, I decided to focus this PR only for the Email\Channel
, because, actually, the Slack\Channel
is not really hurt by these multiple notifications (aka 1 message per ticket) :)
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.
Oh, I got it.
Nice then! >:D
Description
In order to avoid spam via email, we should send a unique email per user with all the tickets information that the user is assigned to.