diff options
-rw-r--r-- | service/mailservice.php | 5 | ||||
-rw-r--r-- | templates/email.newuser.disabled_html.php | 1 | ||||
-rw-r--r-- | templates/email.newuser.disabled_plaintext.php | 1 |
3 files changed, 6 insertions, 1 deletions
diff --git a/service/mailservice.php b/service/mailservice.php index e9a301e..0232cda 100644 --- a/service/mailservice.php +++ b/service/mailservice.php @@ -147,9 +147,12 @@ class MailService { * @throws \Exception */ private function sendNewUserNotifEmail(array $to, $username, $userIsEnabled) { + $link = $this->urlGenerator->linkToRoute('settings_users'); + $link = $this->urlGenerator->getAbsoluteURL($link); $template_var = [ 'user' => $username, - 'sitename' => $this->defaults->getName() + 'sitename' => $this->defaults->getName(), + 'link' => $link, ]; // handle user enableness diff --git a/templates/email.newuser.disabled_html.php b/templates/email.newuser.disabled_html.php index 6407ffb..8670e62 100644 --- a/templates/email.newuser.disabled_html.php +++ b/templates/email.newuser.disabled_html.php @@ -1,2 +1,3 @@ <?php echo $l->t('A new user "%s" has created an account on %s and awaits admin approbation', [$_['user'], $_['sitename']]); +echo str_replace('{link}', $_['link'], '<br/><br/><a href="{link}">{link}</a>'); diff --git a/templates/email.newuser.disabled_plaintext.php b/templates/email.newuser.disabled_plaintext.php index 6407ffb..3b16a8d 100644 --- a/templates/email.newuser.disabled_plaintext.php +++ b/templates/email.newuser.disabled_plaintext.php @@ -1,2 +1,3 @@ <?php echo $l->t('A new user "%s" has created an account on %s and awaits admin approbation', [$_['user'], $_['sitename']]); +echo "\n\n".$_['link']; |