You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
1.2 KiB
43 lines
1.2 KiB
{% load i18n %}
|
|
{% load template_filters %}
|
|
{% get_current_language as LANGUAGE_CODE %}
|
|
{% load pytils_dt %}
|
|
|
|
|
|
|
|
{% if obj.data_begin|timesince_exp:obj.data_end %}
|
|
|
|
{{ obj.data_begin|date:"F" }}
|
|
|
|
{% else %}
|
|
{% if obj.data_begin|timesince:obj.data_end < "1 day" %}
|
|
{% ifequal LANGUAGE_CODE 'ru' %}
|
|
{{ obj.data_begin|ru_strftime:"%d %B %Y" }}
|
|
{% else %}
|
|
{{ obj.data_begin }}
|
|
{% endifequal %}
|
|
|
|
{% else %}
|
|
|
|
{% if obj.data_end %}
|
|
{% trans 'с' %}
|
|
{% ifnotequal obj.data_begin|date:"F" obj.data_end|date:"F" %}
|
|
{% ifequal LANGUAGE_CODE 'ru' %}
|
|
{{ obj.data_begin|ru_strftime:"%d %B" }}
|
|
{% else %}
|
|
{{ obj.data_begin|date:"F j" }}
|
|
{% endifequal %}
|
|
{% else %}
|
|
{{ obj.data_begin|date:"j" }}{% endifnotequal %} {% trans 'по' %}
|
|
{% ifequal LANGUAGE_CODE 'ru' %}
|
|
{{ obj.data_end|ru_strftime:"%d %B" }}
|
|
{% else %}
|
|
{{ obj.data_end }}
|
|
{% endifequal %}
|
|
{% else %}
|
|
{{ obj.data_begin }}
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
{% endif %}
|
|
|
|
|