-
Notifications
You must be signed in to change notification settings - Fork 5
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
moved email message to & cc names to config file #538
Conversation
Signed-off-by: Jurj-Bogdan <[email protected]>
Signed-off-by: Jurj-Bogdan <[email protected]>
config/autoload/local.php.dist
Outdated
@@ -47,10 +47,11 @@ return [ | |||
'contact' => [ | |||
'notification_receivers' => [], | |||
'message_receivers' => [ |
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 do not like the string 'receiver'.
In email world, the standard string is 'recipients'
At least for me , 'receiver' is confusing
@alexmerlin your opionion ?
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.
Another idea might be dropping the "contact" key from local.php
altogether, as the only part it's used by default is the sendContactMail
function in MessageService.php
.
That function already uses the config file from dot-mail (mail.global.php) for the "addFrom" method, and that has the to
and cc
keys available as well.
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.
Another idea might be dropping the "contact" key from
local.php
altogether, as the only part it's used by default is thesendContactMail
function inMessageService.php
.That function already uses the config file from dot-mail (mail.global.php) for the "addFrom" method, and that has the
to
andcc
keys available as well.
Let' discuss tomorrow
as i do not like either the line from MessageService.php
$this->config['contact']['message_receivers']['to'],
$this->config['contact']['message_receivers']['cc'],
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.
Refactor the below key from local.php.dist
- remove unused key notification_receivers
- use the variable names: recipient, sender
- add a variable for subject and BCC
- for mandatory fields use fallback from maip config ( sender, recipient, subject )
'contact' => [ 'notification_receivers' => [], 'message_receivers' => [ 'to' => [ '[email protected]', ], 'cc' => [ '[email protected]', ], ], ],
contact form sender, in general, is platform sender configured in mail.php config file |
Signed-off-by: MarioRadu <[email protected]>
Signed-off-by: MarioRadu <[email protected]>
Signed-off-by: Jurj-Bogdan <[email protected]>
Signed-off-by: Jurj-Bogdan <[email protected]>
config/autoload/local.php.dist
Outdated
'message_receivers' => [ | ||
'subject' => 'Dotkernel Contact', | ||
'message_sender' => [ | ||
'name' => '', |
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.
better a variable name like
from_name
config/autoload/local.php.dist
Outdated
'subject' => 'Dotkernel Contact', | ||
'message_sender' => [ | ||
'name' => '', | ||
'address' => '', |
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.
better a variable name like
from_email
why there are 19 files commited ? |
Signed-off-by: Jurj-Bogdan <[email protected]>
Because @Jurj-Bogdan must have merged the latest changes from |
yup, i rebased this branch to make sure no conflicts exist with the default branch which was updated while this PR was open |
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.
@alexmerlin please merge this one
moved the hardcoded "Dotkernel Team" string to a config file.