diff --git a/src/fellchensammlung/models.py b/src/fellchensammlung/models.py index 7fdf9da..15bd6af 100644 --- a/src/fellchensammlung/models.py +++ b/src/fellchensammlung/models.py @@ -14,7 +14,7 @@ from django.contrib.auth.models import AbstractUser from django.core.exceptions import ValidationError from .tools import misc, geo -from notfellchen.settings import MEDIA_URL +from notfellchen.settings import MEDIA_URL, base_url from .tools.geo import LocationProxy, Position from .tools.misc import age_as_hr_string, time_since_as_hr_string @@ -389,6 +389,10 @@ class AdoptionNotice(models.Model): """Returns the url to access a detailed page for the adoption notice.""" return reverse('adoption-notice-detail', args=[str(self.id)]) + def get_full_url(self): + """Returns the url including protocol and domain""" + return f"{base_url}{self.get_absolute_url()}" + def get_report_url(self): """Returns the url to report an adoption notice.""" return reverse('report-adoption-notice', args=[str(self.id)]) diff --git a/src/fellchensammlung/templates/fellchensammlung/mail/notifications/an-to-be-checked.html b/src/fellchensammlung/templates/fellchensammlung/mail/notifications/an-to-be-checked.html index 7c4b8a0..8563f4e 100644 --- a/src/fellchensammlung/templates/fellchensammlung/mail/notifications/an-to-be-checked.html +++ b/src/fellchensammlung/templates/fellchensammlung/mail/notifications/an-to-be-checked.html @@ -11,6 +11,6 @@
- {% translate 'Vermittlung anzeigen' %} + {% translate 'Vermittlung anzeigen' %}
{% endblock %} \ No newline at end of file