email with with url()

This commit is contained in:
Jannis Portmann 2021-05-29 09:02:25 +02:00
parent 0055c0e60c
commit 484903a5d3
2 changed files with 2 additions and 1 deletions

View file

@ -34,6 +34,7 @@ class TradeController extends AbstractController
->htmlTemplate('user/trade/offer_email.html.twig')
->context([
'user' => $user,
'id' => $offer->getByUser()->getId(),
'userOffersLink' => $this->generateUrl('user_public', [
'id' => $offer->getByUser()->getId(),
], UrlGeneratorInterface::ABSOLUTE_URL)

View file

@ -1,5 +1,5 @@
<h1>{{ user.username }} wants to trade!</h1>
<p>Checkout {{ user.username}}'s offers:</p>
<a href="{{ userOffersLink }}">Link</a>
<a href="{{ url('user_public', {'id': id}) }}">Link</a>
<p>Reply to this email to start trading.</p>