make all editor templates translatable

This commit is contained in:
Laura Klünder 2017-05-16 16:36:54 +02:00
parent 77b6bb868c
commit 0af1599eb9
4 changed files with 10 additions and 9 deletions

View file

@ -19,7 +19,7 @@
<nav class="navbar navbar-static-top navbar-default">
<div class="container">
<div class="navbar-header">
<a class="navbar-brand" href="{% url 'editor.index' %}">c3nav map editor</a>
<a class="navbar-brand" href="{% url 'editor.index' %}">{% trans 'c3nav map editor' %}</a>
</div>
{% block addnav %}
{% endblock %}

View file

@ -1,19 +1,20 @@
{% load bootstrap3 %}
{% load i18n %}
{% include 'editor/fragment_sections.html' %}
<h3>Delete {{ model_title }}</h3>
<h3>{% blocktrans %}Delete {{ model_title }}{% endblocktrans %}</h3>
<form action="{{ path }}" method="post">
{% csrf_token %}
<p>Please confirm deleting: {{ title }}</p>
<p>{% blocktrans %}Please confirm deleting: {{ model_title }}{% endblocktrans %}</p>
<input type="hidden" name="delete" value="1">
<input type="hidden" name="pk" value="{{ pk }}">
{% buttons %}
<button class="invisiblesubmit" type="submit"></button>
<a class="btn btn-default" href="{{ path }}" data-insert-level>
Cancel
{% trans 'Cancel' %}
</a>
<button type="submit" name="delete_confirm" value="1" class="btn btn-danger pull-right" data-reload-geometries>
Delete
{% trans 'Delete' %}
</button>
{% endbuttons %}
</form>

View file

@ -4,7 +4,7 @@
{% include 'editor/fragment_sections.html' %}
<a class="btn btn-sm {% if new %}btn-danger{% else %}btn-default{% endif %} pull-right" href="{{ back_url }}">
Cancel
{% trans 'Cancel' %}
</a>
{% if new %}
<h3>{% blocktrans %}New {{ model_title }}{% endblocktrans %}</h3>
@ -25,7 +25,7 @@
{% trans 'Save' %}
</button>
<a class="btn {% if new %}btn-danger{% else %}btn-default pull-right{% endif %} cancel-btn" href="{{ back_url }}">
Cancel
{% trans 'Cancel' %}
</a>
{% endbuttons %}
</form>

View file

@ -9,8 +9,8 @@
<div id="responsive_switch" class="navbar-collapse collapse">
<ul class="nav navbar-nav navbar-right">
<li>
<a href="#" id="show_map">&laquo; Show Map</a>
<a href="#" id="show_details">Show Details &raquo;</a>
<a href="#" id="show_map">&laquo; {% trans 'Show map' %}</a>
<a href="#" id="show_details">{% trans 'Show details' %} &raquo;</a>
</li>
</ul>
</div>