feat: Add ANs to rescue organization
This commit is contained in:
parent
6c52246bb7
commit
efabebfdbf
@ -113,6 +113,13 @@ class RescueOrganization(models.Model):
|
|||||||
comment = models.TextField(verbose_name=_("Kommentar"), null=True, blank=True, )
|
comment = models.TextField(verbose_name=_("Kommentar"), null=True, blank=True, )
|
||||||
description = models.TextField(null=True, blank=True, verbose_name=_('Beschreibung')) # Markdown allowed
|
description = models.TextField(null=True, blank=True, verbose_name=_('Beschreibung')) # Markdown allowed
|
||||||
|
|
||||||
|
def get_absolute_url(self):
|
||||||
|
return reverse("rescue-organization-detail", args=[str(self.pk)])
|
||||||
|
|
||||||
|
@property
|
||||||
|
def adoption_notices(self):
|
||||||
|
return AdoptionNotice.objects.filter(organization=self)
|
||||||
|
|
||||||
|
|
||||||
class User(AbstractUser):
|
class User(AbstractUser):
|
||||||
"""
|
"""
|
||||||
|
@ -16,4 +16,14 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
<p>{{ org.description | render_markdown }}</p>
|
<p>{{ org.description | render_markdown }}</p>
|
||||||
</div>
|
</div>
|
||||||
|
<h2>{% translate 'Vermittlungen der Organisation' %}</h2>
|
||||||
|
<div class="container-cards">
|
||||||
|
{% if org.adoption_notices %}
|
||||||
|
{% for adoption_notice in org.adoption_notices %}
|
||||||
|
{% include "fellchensammlung/partials/partial-adoption-notice-minimal.html" %}
|
||||||
|
{% endfor %}
|
||||||
|
{% else %}
|
||||||
|
<p>{% translate "Keine Vermittlungen gefunden." %}</p>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
Loading…
Reference in New Issue
Block a user