Fix #300 - Feature/remove flag as language (#542)

* don't use flags to indicate languages #300

* cleaned code

* removed the filter and moved the logic to context.py

* cleaned code

* show the text in the local language

* cleaned code

* changed loop for list comprehension

* fix indentation

* ordered import
This commit is contained in:
Michele Fattoruso
2017-07-06 02:13:57 -05:00
committed by Raphael Michel
parent 7b22adb72e
commit 5932558ca2
2 changed files with 6 additions and 4 deletions

View File

@@ -37,10 +37,10 @@
<div class="pull-right loginbox">
{% if request.event.settings.locales|length > 1 %}
<div class="locales">
{% for l in request.event.settings.locales %}
<a href="{% url "presale:locale.set" %}?locale={{ l }}&next={{ request.path }}%3F{{ request.META.QUERY_STRING|urlencode }}"
class="{% if l == request.LANGUAGE_CODE %}active{% endif %}"
><img src="{% static "pretixbase/img/flags/"|add:l|add:".png" %}"/></a>
{% for l in languages %}
<a href="{% url "presale:locale.set" %}?locale={{ l.code }}&next={{ request.path }}%3F{{ request.META.QUERY_STRING|urlencode }}" class="{% if l.code == request.LANGUAGE_CODE %}active{% endif %}">
{{ l.name_local }}
</a>
{% endfor %}
</div>
{% endif %}