adjust update author and content display

This commit is contained in:
krmax44 2022-03-28 12:00:27 +02:00
parent 3cfac9bd6d
commit 7e6d5d4222
No known key found for this signature in database
GPG key ID: 5C499A4F4EC4EE03

View file

@ -20,12 +20,18 @@
</div> </div>
<div class="small"> <div class="small">
<time datetime="{{ update.timestamp|date:'c' }}">{{ update.timestamp|date:"DATE_FORMAT" }}</time> <time datetime="{{ update.timestamp|date:'c' }}">{{ update.timestamp|date:"DATE_FORMAT" }}</time>
<span>{% if update.user %}von {{ update.user.get_full_name }}{% endif %}{% if update.organization %}, {{ update.organization.name }}{% endif %}</span>
{% if update.user or update.organization %}
<span>
von {{ update.user.get_full_name }}{% if update.user and update.organization %},{% endif %}
{{ update.organization.name }}
</span>
{% endif %}
</div> </div>
</div> </div>
</a> </a>
{% if update.content %} {% if update.content or show_context %}
<div class="p-3 p-md-4 tight-margin"> <div class="p-3 p-md-4 tight-margin">
{% if show_context %} {% if show_context %}
<h4 class="h5">{{ update.title }}</h4> <h4 class="h5">{{ update.title }}</h4>
@ -33,7 +39,7 @@
{% with update.content|markdown as content %} {% with update.content|markdown as content %}
{% if show_context %} {% if show_context %}
{{ content|truncatewords_html:75 }} {{ content|truncatewords_html:50 }}
{% else %} {% else %}
{{ content }} {{ content }}
{% endif %} {% endif %}