Commit f3c1ab4a authored by Skia's avatar Skia

forum: use short names

Signed-off-by: Skia's avatarSkia <skia@libskia.so>
parent 11d20f43
Pipeline #1008 passed with stage
in 4 minutes and 33 seconds
......@@ -2,6 +2,10 @@
<a href="{{ url("core:user_profile", user_id=user.id) }}">{{ user.get_display_name() }}</a>
{%- endmacro %}
{% macro user_profile_link_short_name(user) -%}
<a href="{{ url("core:user_profile", user_id=user.id) }}">{{ user.get_short_name() }}</a>
{%- endmacro %}
{% macro user_link_with_pict(user) -%}
<a href="{{ url("core:user_profile", user_id=user.id) }}" class="mini_profile_link" >
{{ user.get_mini_item()|safe }}
......
{% from 'core/macros.jinja' import user_profile_link %}
{% from 'core/macros.jinja' import user_profile_link_short_name %}
{% macro display_forum(forum, user, is_root=False) %}
<div class="forum {% if is_root %}category{% endif %}">
......@@ -29,7 +29,7 @@
</p>
<div class="ib w_medium last_message" style="font-size: x-small; text-align: center">
{% if forum.last_message %}
{{ forum.last_message.author }} <br/>
{{ user_profile_link_short_name(forum.last_message.author) }} <br/>
<a href="{{ forum.last_message.get_absolute_url() }}">
<date>
{{ forum.last_message.date|localtime|date(DATETIME_FORMAT) }}
......@@ -66,7 +66,7 @@
<div class="ib w_medium last_message">
<div class="ib w_medium">
<p class="ib w_medium" style="text-align: center;">
{{ user_profile_link(topic.author) }}
{{ user_profile_link_short_name(topic.author) }}
</p>
<p class="ib w_medium" style="text-align: center;">
{{ topic._message_number }}
......@@ -75,7 +75,7 @@
<p class="ib w_medium" style="text-align: center;">
{% set last_msg = topic.last_message %}
{% if last_msg %}
{{ user_profile_link(last_msg.author) }} <br/>
{{ user_profile_link_short_name(last_msg.author) }} <br/>
<a href="{{ last_msg.get_absolute_url() }}">
<date>{{ last_msg.date|date(DATETIME_FORMAT) }} {{ last_msg.date|time(DATETIME_FORMAT) }}</date>
</a>
......@@ -133,7 +133,7 @@
<ul class="msg_meta">
{% for meta in m.metas.select_related('user').order_by('id') %}
<li style="background: {% if m.author == meta.user %}#bfffbf{% else %}#ffffbf{% endif %}">
{{ meta.get_action_display() }} {{ meta.user.get_display_name() }}
{{ meta.get_action_display() }} {{ meta.user.get_short_name() }}
{% trans %} at {% endtrans %}{{ meta.date|localtime|time(DATETIME_FORMAT) }}
{% trans %} the {% endtrans %}{{ meta.date|localtime|date(DATETIME_FORMAT)}}</li>
{% endfor %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment