I am trying to add a link inside the @UniqueEntity message inside my Doctrine mapping so that the link is not hardcoded inside the translation file. I am invoking this with Symfony2 forms.
Doctrine mapping:
@UniqueEntity(
fields={"email"},
message="form.error.email_exists"
)
Translation file:
<trans-unit id="a81086a8eea38842e4c8351657840086" resname="form.error.email_exists">
<source>form.error.email_exists</source>
<target>We have an account with that email. %link1%Forgot your login?%linkEnd%</target>
</trans-unit>
Normally you would just pass the %link1% through a translation filter, but I don't know how to do this within an annotation or if it is even possible.
Thanks in advance.