Use babel for base views

master
Pierre Jaury 8 years ago
parent fe035114e9
commit a3ad45c8ac

@ -1,7 +1,7 @@
{% extends "base.html" %}
{% block title %}
Confirm action
{% trans %}Confirm action{% endtrans %}
{% endblock %}
{% block subtitle %}
@ -9,6 +9,6 @@ Confirm action
{% endblock %}
{% block box_content %}
<p>You are about to {{ action }}. Please confirm your action.</p>
<p>{% trans action %}You are about to {{ action }}. Please confirm your action.{% endtrans %}</p>
{{ macros.form(form) }}
{% endblock %}

@ -3,10 +3,10 @@
{% block sidebar %}
<section class="sidebar">
<ul class="sidebar-menu">
<li class="header">Your account</li>
<li class="header">{% trans %}Your account{% endtrans %}</li>
<li>
<a href="#">
<i class="fa fa-sign-in"></i> <span>Sign in</span>
<i class="fa fa-sign-in"></i> <span>{% trans %}Sign in{% endtrans %}</span>
</a>
</li>
</ul>
@ -14,11 +14,11 @@
{% endblock %}
{% block title %}
Sign in
{% trans %}Sign in{% endtrans %}
{% endblock %}
{% block subtitle %}
to access the administration tools
{% trans %}to access the administration tools{% endtrans %}
{% endblock %}
{% block box_content %}

@ -1,19 +1,19 @@
{% extends "base.html" %}
{% block title %}
Services status
{% trans %}Services status{% endtrans %}
{% endblock %}
{% block box %}
<table class="table table-bordered">
<tbody>
<tr>
<th>Service</th>
<th>Status</th>
<th>PID</th>
<th>Image</th>
<th>Started</th>
<th>Last update</th>
<th>{% trans %}Service{% endtrans %}</th>
<th>{% trans %}Status{% endtrans %}</th>
<th>{% trans %}PID{% endtrans %}</th>
<th>{% trans %}Image{% endtrans %}</th>
<th>{% trans %}Started{% endtrans %}</th>
<th>{% trans %}Last update{% endtrans %}</th>
</tr>
{% for name, container in containers.items() %}
<tr>

@ -2,61 +2,61 @@
<h4 class="text-center text-primary">{{ current_user }}</h4>
<ul class="sidebar-menu">
<li class="header">My account</li>
<li class="header">{% trans %}My account{% endtrans %}</li>
<li>
<a href="{{ url_for('.user_settings') }}">
<i class="fa fa-wrench"></i> <span>Settings</span>
<i class="fa fa-wrench"></i> <span>{% trans %}Settings{% endtrans %}</span>
</a>
</li>
<li>
<a href="{{ url_for('.user_password') }}">
<i class="fa fa-lock"></i> <span>Update password</span>
<i class="fa fa-lock"></i> <span>{% trans %}Update password{% endtrans %}</span>
</a>
</li>
<li>
<a href="{{ url_for('.user_forward') }}">
<i class="fa fa-share"></i> <span>Auto-forward</span>
<i class="fa fa-share"></i> <span>{% trans %}Auto-forward{% endtrans %}</span>
</a>
</li>
<li>
<a href="{{ url_for('.user_reply') }}">
<i class="fa fa-plane"></i> <span>Auto-reply</span>
<i class="fa fa-plane"></i> <span>{% trans %}Auto-reply{% endtrans %}</span>
</a>
</li>
<li>
<a href="{{ url_for('.fetch_list') }}">
<i class="fa fa-download"></i> <span>Fetched accounts</span>
<i class="fa fa-download"></i> <span>{% trans %}Fetched accounts{% endtrans %}</span>
</a>
</li>
<li>
<a href="{{ url_for('.logout') }}">
<i class="fa fa-sign-out"></i> <span>Sign out</span>
<i class="fa fa-sign-out"></i> <span>{% trans %}Sign out{% endtrans %}</span>
</a>
</li>
<li class="header">Administration</li>
<li class="header">{% trans %}Administration{% endtrans %}</li>
{% if current_user.global_admin %}
<li>
<a href="{{ url_for('.services') }}">
<i class="fa fa-dashboard"></i> <span>Services status</span>
<i class="fa fa-dashboard"></i> <span>{% trans %}Services status{% endtrans %}</span>
</a>
</li>
<li>
<a href="{{ url_for('.admin_list') }}">
<i class="fa fa-user"></i> <span>Administrators</span>
<i class="fa fa-user"></i> <span>{% trans %}Administrators{% endtrans %}</span>
</a>
</li>
{% endif %}
{% if current_user.manager_of or current_user.global_admin %}
<li>
<a href="{{ url_for('.domain_list') }}">
<i class="fa fa-envelope"></i> <span>Mail domains</span>
<i class="fa fa-envelope"></i> <span>{% trans %}Mail domains{% endtrans %}</span>
</a>
</li>
{% endif %}
<li>
<a href="https://github.com/kaiyou/freeposte.io">
<i class="fa fa-life-ring"></i> <span>Help</span>
<i class="fa fa-life-ring"></i> <span>{% trans %}Help{% endtrans %}</span>
</a>
</li>
</ul>

@ -1,5 +1,5 @@
{% extends "base.html" %}
{% block content %}
<div class="alert alert-warning" role="alert">We are still working on this feature!</div>
<div class="alert alert-warning" role="alert">{% trans %}We are still working on this feature!{% endtrans %}</div>
{% endblock %}

Loading…
Cancel
Save