Translate most of the Sith

This commit is contained in:
Skia 2016-07-19 19:03:16 +02:00
parent 1b4324f38f
commit 97ff4341a7
55 changed files with 1238 additions and 475 deletions

View File

@ -0,0 +1,19 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('accounting', '0010_remove_operation_type'),
]
operations = [
migrations.AlterField(
model_name='operation',
name='mode',
field=models.CharField(max_length=255, verbose_name='payment method', choices=[('cheque', 'Check'), ('cash', 'Cash'), ('transfert', 'Transfert'), ('card', 'Credit card')]),
),
]

View File

@ -1,23 +1,20 @@
{% extends "core/base.jinja" %}
{% block title %}
Accounting type list
{% trans %}Accounting type list{% endtrans %}
{% endblock %}
{% block content %}
<p><a href="{{ url('accounting:type_new') }}">New accounting type</a></p>
<p><a href="{{ url('accounting:type_new') }}">{% trans %}New accounting type{% endtrans %}</a></p>
{% if accountingtype_list %}
<h3>Accounting type list</h3>
<ul>
{% for a in accountingtype_list %}
<li><a href="{{ url('accounting:type_edit', type_id=a.id) }}">{{ a }}</a></li>
{% endfor %}
</ul>
<h3>{% trans %}Accounting type list{% endtrans %}</h3>
<ul>
{% for a in accountingtype_list %}
<li><a href="{{ url('accounting:type_edit', type_id=a.id) }}">{{ a }}</a></li>
{% endfor %}
</ul>
{% else %}
There is no types in this website.
{% trans %}There is no types in this website.{% endtrans %}
{% endif %}
{% endblock %}

View File

@ -1,22 +1,17 @@
{% extends "core/base.jinja" %}
{% block content %}
<p>
<a href="{{ url('accounting:bank_list') }}">Accounting</a> >
{{ object.name }}
</p>
<h2>View account</h2>
<ul>
{% for k,v in object.__dict__.items() %}
<li>{{ k }} - {{ v }}</li>
{% endfor %}
</ul>
<p><a href="{{ url('accounting:club_new') }}?parent={{ object.id }}">New club account</a></p>
<p>
<a href="{{ url('accounting:bank_list') }}">{% trans %}Accounting{% endtrans %}</a> >
{{ object.name }}
</p>
<h2>{% trans %}View account{% endtrans %}</h2>
<p><a href="{{ url('accounting:club_new') }}?parent={{ object.id }}">{% trans %}New club account{% endtrans %}</a></p>
<ul>
{% for c in object.club_accounts.all() %}
<li><a href="{{ url('accounting:club_details', c_account_id=c.id) }}">{{ c }}</a> -
<a href="{{ url('accounting:club_edit', c_account_id=c.id) }}">Edit</a> -
<a href="{{ url('accounting:club_delete', c_account_id=c.id) }}">Delete</a></li>
<a href="{{ url('accounting:club_edit', c_account_id=c.id) }}">{% trans %}Edit{% endtrans %}</a> -
<a href="{{ url('accounting:club_delete', c_account_id=c.id) }}">{% trans %}Delete{% endtrans %}</a></li>
{% endfor %}
</ul>

View File

@ -1,23 +1,23 @@
{% extends "core/base.jinja" %}
{% block title %}
Bank account list
{% trans %}Bank account list{% endtrans %}
{% endblock %}
{% block content %}
<p><a href="{{ url('accounting:type_list') }}">Manage accounting types</a></p>
<p><a href="{{ url('accounting:bank_new') }}">New bank account</a></p>
<p><a href="{{ url('accounting:type_list') }}">{% trans %}Manage accounting types{% endtrans %}</a></p>
<p><a href="{{ url('accounting:bank_new') }}">{% trans %}New bank account{% endtrans %}</a></p>
{% if bankaccount_list %}
<h3>Bank account list</h3>
<h3>{% trans %}Bank account list{% endtrans %}</h3>
<ul>
{% for a in bankaccount_list %}
<li><a href="{{ url('accounting:bank_details', b_account_id=a.id) }}">{{ a }}</a> -
<a href="{{ url('accounting:bank_edit', b_account_id=a.id) }}">Edit</a> -
<a href="{{ url('accounting:bank_delete', b_account_id=a.id) }}">Delete</a></li>
<a href="{{ url('accounting:bank_edit', b_account_id=a.id) }}">{% trans %}Edit{% endtrans %}</a> -
<a href="{{ url('accounting:bank_delete', b_account_id=a.id) }}">{% trans %}Delete{% endtrans %}</a></li>
{% endfor %}
</ul>
{% else %}
There is no accounts in this website.
{% trans %}There is no accounts in this website.{% endtrans %}
{% endif %}
{% endblock %}

View File

@ -1,53 +1,49 @@
{% extends "core/base.jinja" %}
{% block content %}
<p>
<a href="{{ url('accounting:bank_list') }}">Accounting</a> >
<a href="{{ url('accounting:bank_details', b_account_id=object.bank_account.id) }}">{{object.bank_account }}</a> >
{{ object }}
<h2>View account: {{ object.name }}</h2>
<p>
<a href="{{ url('accounting:bank_list') }}">{% trans %}Accounting{% endtrans %}</a> >
<a href="{{ url('accounting:bank_details', b_account_id=object.bank_account.id) }}">{{object.bank_account }}</a> >
{{ object }}
<h2>{% trans %}View account:{% endtrans %} {{ object.name }}</h2>
<ul>
{% for k,v in object.__dict__.items() %}
{% for k,v in object.__dict__.items() %}
<li>{{ k }} - {{ v }}</li>
{% endfor %}
{% endfor %}
</ul>
{% if not object.has_open_journal() %}
<p><a href="{{ url('accounting:journal_new') }}?parent={{ object.id }}">New journal</a></p>
<p><a href="{{ url('accounting:journal_new') }}?parent={{ object.id }}">{% trans %}New journal{% endtrans %}</a></p>
{% else %}
<p>You can not create new journal while you still have one opened</p>
<p>{% trans %}You can not create new journal while you still have one opened{% endtrans %}</p>
{% endif %}
<table>
<tr>
<td>Name</td>
<td>Start</td>
<td>End</td>
<td>Amount</td>
<td>Effective amount</td>
<td>Closed</td>
<td>{% trans %}Name{% endtrans %}</td>
<td>{% trans %}Start{% endtrans %}</td>
<td>{% trans %}End{% endtrans %}</td>
<td>{% trans %}Amount{% endtrans %}</td>
<td>{% trans %}Effective amount{% endtrans %}</td>
<td>{% trans %}Closed{% endtrans %}</td>
</tr>
{% for j in object.journals.all() %}
<tr>
<td>{{ j.name }}</td>
<td>{{ j.start_date }}</td>
{% if j.end_date %}
{% for j in object.journals.all() %}
<tr>
<td>{{ j.name }}</td>
<td>{{ j.start_date }}</td>
{% if j.end_date %}
<td>{{ j.end_date }}</td>
{% else %}
{% else %}
<td> - </td>
{% endif %}
<td>{{ j.amount }} €</td>
<td>{{ j.effective_amount }} €</td>
{% if j.closed %}
<td>Yes</td>
{% else %}
<td>No</td>
{% endif %}
<td> <a href="{{ url('accounting:journal_details', j_id=j.id) }}">View</a>
<a href="{{ url('accounting:journal_edit', j_id=j.id) }}">Edit</a> </td>
</tr>
{% endfor %}
{% endif %}
<td>{{ j.amount }} €</td>
<td>{{ j.effective_amount }} €</td>
{% if j.closed %}
<td>{% trans %}Yes{% endtrans %}</td>
{% else %}
<td>{% trans %}No{% endtrans %}</td>
{% endif %}
<td> <a href="{{ url('accounting:journal_details', j_id=j.id) }}">{% trans %}View{% endtrans %}</a>
<a href="{{ url('accounting:journal_edit', j_id=j.id) }}">{% trans %}Edit{% endtrans %}</a> </td>
</tr>
{% endfor %}
</table>
{% endblock %}

View File

@ -1,33 +1,34 @@
{% extends "core/base.jinja" %}
{% block content %}
<p>
<a href="{{ url('accounting:bank_list') }}">Accounting</a> >
<a href="{{ url('accounting:bank_details', b_account_id=object.club_account.bank_account.id) }}">{{object.club_account.bank_account }}</a> >
<a href="{{ url('accounting:club_details', c_account_id=object.club_account.id) }}">{{ object.club_account }}</a> >
{{ object.name }}
</p>
<p><strong>Amount: </strong>{{ object.amount }} € - <strong>Effective amount: </strong>{{ object.effective_amount }} €</p>
<p>
<a href="{{ url('accounting:bank_list') }}">{% trans %}Accounting{% endtrans %}</a> >
<a href="{{ url('accounting:bank_details', b_account_id=object.club_account.bank_account.id) }}">{{object.club_account.bank_account }}</a> >
<a href="{{ url('accounting:club_details', c_account_id=object.club_account.id) }}">{{ object.club_account }}</a> >
{{ object.name }}
</p>
<p><strong>{% trans %}Amount: {% endtrans %}</strong>{{ object.amount }} € -
<strong>{% trans %}Effective amount: {% endtrans %}</strong>{{ object.effective_amount }} €</p>
{% if object.closed %}
<p>Journal is closed, you can not create operation</p>
<p>{% trans %}Journal is closed, you can not create operation{% endtrans %}</p>
{% else %}
<p><a href="{{ url('accounting:op_new') }}?parent={{ object.id }}">New operation</a></p>
<p><a href="{{ url('accounting:op_new') }}?parent={{ object.id }}">{% trans %}New operation{% endtrans %}</a></p>
{% endif %}
<table>
<tr>
<td>Nb</td>
<td>Date</td>
<td>Label</td>
<td>Amount</td>
<td>Payment mode</td>
<td>{% trans %}Nb{% endtrans %}</td>
<td>{% trans %}Date{% endtrans %}</td>
<td>{% trans %}Label{% endtrans %}</td>
<td>{% trans %}Amount{% endtrans %}</td>
<td>{% trans %}Payment mode{% endtrans %}</td>
<!-- TODO: <td>Target</td> -->
<td>Code</td>
<td>Nature</td>
<td>Done</td>
<td>Comment</td>
<td>Actions</td>
<td>{% trans %}Code{% endtrans %}</td>
<td>{% trans %}Nature{% endtrans %}</td>
<td>{% trans %}Done{% endtrans %}</td>
<td>{% trans %}Comment{% endtrans %}</td>
<td>{% trans %}Actions{% endtrans %}</td>
</tr>
{% for o in object.operations.all() %}
{% for o in object.operations.all() %}
<tr>
<td>{{ o.id }}</td>
<td>{{ o.date }}</td>
@ -37,21 +38,17 @@
<td>{{ o.accounting_type.code }}</td>
<td>{{ o.accounting_type.label }}</td>
{% if o.done %}
<td>Yes</td>
<td>{% trans %}Yes{% endtrans %}</td>
{% else %}
<td>No</td>
<td>{% trans %}No{% endtrans %}</td>
{% endif %}
<td>{{ o.remark }}</td>
<td>
{% if not o.journal.closed %}
<a href="{{ url('accounting:op_edit', op_id=o.id) }}">Edit</a>
<a href="{{ url('accounting:op_edit', op_id=o.id) }}">{% trans %}Edit{% endtrans %}</a>
{% endif %}
</td>
</tr>
{% endfor %}
{% endfor %}
</table>
{% endblock %}

View File

@ -0,0 +1,25 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
from django.conf import settings
class Migration(migrations.Migration):
dependencies = [
('club', '0002_auto_20160718_1456'),
]
operations = [
migrations.AlterField(
model_name='membership',
name='club',
field=models.ForeignKey(to='club.Club', verbose_name='club', related_name='members'),
),
migrations.AlterField(
model_name='membership',
name='user',
field=models.ForeignKey(to=settings.AUTH_USER_MODEL, verbose_name='user', related_name='membership'),
),
]

View File

@ -74,7 +74,7 @@ class Club(models.Model):
Method to see if that object can be edited by the given user
"""
ms = self.get_membership_for(user)
if ms is not None and ms.role >= 7:
if ms is not None:
return True
return False
@ -104,8 +104,8 @@ class Membership(models.Model):
A User is currently member of all the Clubs where its Membership has an end_date set to null/None.
Otherwise, it's a past membership kept because it can be very useful to see who was in which Club in the past.
"""
user = models.ForeignKey(User, related_name="membership", null=False, blank=False)
club = models.ForeignKey(Club, related_name="members", null=False, blank=False)
user = models.ForeignKey(User, verbose_name=_('user'), related_name="membership", null=False, blank=False)
club = models.ForeignKey(Club, verbose_name=_('club'), related_name="members", null=False, blank=False)
start_date = models.DateField(_('start date'), auto_now=True)
end_date = models.DateField(_('end date'), null=True, blank=True)
role = models.IntegerField(_('role'), choices=sorted(settings.SITH_CLUB_ROLES.items()),

View File

@ -1,17 +1,17 @@
{% extends "core/base.jinja" %}
{% block content %}
<h3>Club</h3>
<p><a href="{{ url('club:club_list') }}">Back to list</a></p>
<h3>{% trans %}Club{% endtrans %}</h3>
<p><a href="{{ url('club:club_list') }}">{% trans %}Back to list{% endtrans %}</a></p>
{% if can_edit(club, user) %}
<p><a href="{{ url('club:club_edit', club_id=club.pk) }}">Edit</a></p>
<p><a href="{{ url('club:club_edit', club_id=club.pk) }}">{% trans %}Edit{% endtrans %}</a></p>
{% endif %}
{% if can_edit_prop(club, user) %}
<p><a href="{{ url('club:club_prop', club_id=club.pk) }}">Prop</a>
</p>
<p><a href="{{ url('club:club_prop', club_id=club.pk) }}">{% trans %}Prop{% endtrans %}</a>
</p>
{% endif %}
{% if can_view(club, user) %}
<p><a href="{{ url('club:club_members', club_id=club.pk) }}">Members</a></p>
<p><a href="{{ url('club:club_members', club_id=club.pk) }}">{% trans %}Members{% endtrans %}</a></p>
{% endif %}
<h3>{{ club.name }}</h3>
<p>{{ club.address }}</p>

View File

@ -1,11 +1,11 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Edit club</h2>
<h2>{% trans %}Edit club{% endtrans %}</h2>
<form action="{{ url('club:club_edit', club_id=club.id) }}" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,11 +1,11 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Edit club properties</h2>
<h2>{% trans %}Edit club properties{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,7 +1,7 @@
{% extends "core/base.jinja" %}
{% block title %}
Club list
{% trans %}Club list{% endtrans %}
{% endblock %}
{% macro display_club(club) -%}
@ -18,17 +18,17 @@
{% block content %}
{% if user.is_superuser or user.is_in_group(settings.SITH_GROUPS['root']['name']) %}
<p><a href="{{ url('club:club_new') }}">New club</a></p>
<p><a href="{{ url('club:club_new') }}">{% trans %}New club{% endtrans %}</a></p>
{% endif %}
{% if club_list %}
<h3>Club list</h3>
<ul>
{%- for c in club_list if c.parent is none %}
{{ display_club(c) }}
{%- endfor %}
</ul>
<h3>{% trans %}Club list{% endtrans %}</h3>
<ul>
{%- for c in club_list if c.parent is none %}
{{ display_club(c) }}
{%- endfor %}
</ul>
{% else %}
There is no club in this website.
{% trans %}There is no club in this website.{% endtrans %}
{% endif %}
{% endblock %}

View File

@ -1,7 +1,7 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Club members</h2>
<h2>{% trans %}Club members{% endtrans %}</h2>
<ul>
{% for m in club.members.all() %}
<li>{{ m }}</li>
@ -10,7 +10,7 @@
<form action="{{ url('club:club_members', club_id=club.id) }}" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Add" /></p>
<p><input type="submit" value="{% trans %}Add{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,25 +1,25 @@
{% extends "core/base.jinja" %}
{% block content %}
<h3>Club tools</h3>
<p><a href="{{ url('club:club_view', club_id=object.id) }}">Back to club</a></p>
<ul>
{% if object.counters.all()|count > 0 %}
<li>Counters:
<ul>
{% for c in object.counters.all() %}
<li>{{ c }}:
<a href="{{ url('counter:details', counter_id=c.id) }}">View</a>
<a href="{{ url('counter:admin', counter_id=c.id) }}">Edit</a>
</li>
{% endfor %}
</ul>
<h3>{% trans %}Club tools{% endtrans %}</h3>
<p><a href="{{ url('club:club_view', club_id=object.id) }}">Back to club</a></p>
<ul>
{% if object.counters.all()|count > 0 %}
<li><h4>{% trans %}Counters:{% endtrans %}</h4>
<ul>
{% for c in object.counters.all() %}
<li>{{ c }}:
<a href="{{ url('counter:details', counter_id=c.id) }}">View</a>
<a href="{{ url('counter:admin', counter_id=c.id) }}">Edit</a>
</li>
{% endif %}
{% if object.club_account %}
<li>Accouting: <a href="{{ url('accounting:club_details', c_account_id=object.club_account.id) }}">{{ object }}</a></li>
{% endif %}
</ul>
{% endfor %}
</ul>
</li>
{% endif %}
{% if object.club_account %}
<li>Accouting: <a href="{{ url('accounting:club_details', c_account_id=object.club_account.id) }}">{{ object }}</a></li>
{% endif %}
</ul>
{% endblock %}

View File

@ -25,7 +25,7 @@ class ClubView(CanViewMixin, DetailView):
pk_url_kwarg = "club_id"
template_name = 'club/club_detail.jinja'
class ClubToolsView(CanViewMixin, DetailView):
class ClubToolsView(CanEditMixin, DetailView):
"""
Tools page of a Club
"""

View File

@ -2,7 +2,7 @@
{% block content %}
<h3>403, Forbidden</h3>
<h3>{% trans %}403, Forbidden{% endtrans %}</h3>
{% endblock %}

View File

@ -2,7 +2,7 @@
{% block content %}
<h3>404, Not Found</h3>
<h3>{% trans %}404, Not Found{% endtrans %}</h3>
{% endblock %}

View File

@ -1,52 +1,53 @@
<!DOCTYPE html>
<html lang="fr">
<head>
{% block head %}
<title>{% block title %}Bienvenue sur le Sith de l'AE!{% endblock %}</title>
<link rel="stylesheet" href="{{ static('core/base.css') }}">
<link rel="stylesheet" href="{{ static('core/form.css') }}">
<link rel="stylesheet" href="{{ static('core/style.css') }}">
<script src="{{ static('core/script.js') }}"></script>
<script src="http://code.jquery.com/jquery-2.2.0.min.js"></script>
{% endblock %}
</head>
<body>
<div id="logo"><a href="{{ url('core:index') }}"><img src="{{ static('core/img/logo.png') }}" alt="Logo" /></a></div>
{% block header %}
<header>
{% if not user.is_authenticated() %}
<a href="{{ url('core:login') }}">Login</a> |
<a href="{{ url('core:register') }}">Register</a>
{% else %}
<a href="{{ url('core:user_profile', user_id=user.id) }}">{{ user.get_display_name() }}</a> |
<a href="{{ url('core:user_tools') }}">Tools</a> |
<a href="{{ url('core:logout') }}">Logout</a>
{% endif %}
</header>
{% endblock %}
<nav>
<a href="{{ url('core:user_list') }}">Users</a>
<a href="{{ url('core:page', page_name="Index") }}">Pages</a>
<a href="{{ url('club:club_list') }}">Clubs</a>
</nav>
<div id="content">
{% if error %}
{{ error }}
{% endif %}
{% block content %}{% endblock %}
</div>
<footer>
{% block footer %}
Site réalisé par des gens biens
<head>
{% block head %}
<title>{% block title %}{% trans %}Welcome!{% endtrans %}{% endblock %}</title>
<link rel="stylesheet" href="{{ static('core/base.css') }}">
<link rel="stylesheet" href="{{ static('core/form.css') }}">
<link rel="stylesheet" href="{{ static('core/style.css') }}">
<script src="{{ static('core/script.js') }}"></script>
{% endblock %}
</footer>
<!--
{% block tests %}
{{ tests }}
{% endblock %}
-->
</body>
</head>
<body>
<div id="logo"><a href="{{ url('core:index') }}"><img src="{{ static('core/img/logo.png') }}"
alt="{% trans %}Logo{% endtrans %}" /></a></div>
{% block header %}
<header>
{% if not user.is_authenticated() %}
<a href="{{ url('core:login') }}">{% trans %}Login{% endtrans %}</a> |
<a href="{{ url('core:register') }}">{% trans %}Register{% endtrans %}</a>
{% else %}
<a href="{{ url('core:user_profile', user_id=user.id) }}">{{ user.get_display_name() }}</a> |
<a href="{{ url('core:user_tools') }}">{% trans %}Tools{% endtrans %}</a> |
<a href="{{ url('core:logout') }}">{% trans %}Logout{% endtrans %}</a>
{% endif %}
</header>
{% endblock %}
<nav>
<a href="{{ url('core:user_list') }}">{% trans %}Users{% endtrans %}</a>
<a href="{{ url('core:page', page_name="Index") }}">{% trans %}Pages{% endtrans %}</a>
<a href="{{ url('club:club_list') }}">{% trans %}Clubs{% endtrans %}</a>
</nav>
<div id="content">
{% if error %}
{{ error }}
{% endif %}
{% block content %}
{% endblock %}
</div>
<footer>
{% block footer %}
{% trans %}Site made by good people{% endtrans %}
{% endblock %}
</footer>
<!--
{% block tests %}
{{ tests }}
{% endblock %}
-->
</body>
</html>

View File

@ -1,12 +1,12 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Create</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
</form>
<h2>{% trans %}Create{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,12 +1,12 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Delete confirmation</h2>
<form action="" method="post">{% csrf_token %}
<p>Are you sure you want to delete "{{ object }}"?</p>
<input type="submit" value="Confirm" />
<input type="submit" name="cancel" value="Cancel" />
</form>
<h2>{% trans %}Delete confirmation{% endtrans %}</h2>
<form action="" method="post">{% csrf_token %}
<p>{% trans obj=object %}Are you sure you want to delete "{{ obj }}"?{% endtrans %}</p>
<input type="submit" value="{% trans %}Confirm{% endtrans %}" />
<input type="submit" name="cancel" value="{% trans %}Cancel{% endtrans %}" />
</form>
{% endblock %}

View File

@ -1,12 +1,12 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Edit {{ object }}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
</form>
<h2>{% trans obj=object %}Edit {{ obj }}{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,13 +1,13 @@
{% extends "core/base.jinja" %}
{% block content %}
<p><a href="{{ url('core:group_list') }}">Back to list</a></p>
<h2>Edit group</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Update" /></p>
</form>
<p><a href="{{ url('core:group_list') }}">{% trans %}Back to list{% endtrans %}</a></p>
<h2>{% trans %}Edit group{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Update{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,16 +1,16 @@
{% extends "core/base.jinja" %}
{% block title %}
Group list
{% trans %}Group list{% endtrans %}
{% endblock %}
{% block content %}
<h3>Group list</h3>
<p><a href="{{ url('core:group_new') }}">New group</a></p>
<h3>{% trans %}Group list{% endtrans %}</h3>
<p><a href="{{ url('core:group_new') }}">{% trans %}New group{% endtrans %}</a></p>
<ul>
{% for g in realgroup_list %}
<li><a href="{{ url('core:group_edit', group_id=g.id) }}">{{ g.name }}</a> - {{ g.description }} -
<a href="{{ url('core:group_delete', group_id=g.id) }}">Delete</a></li>
<a href="{{ url('core:group_delete', group_id=g.id) }}">{% trans %}Delete{% endtrans %}</a></li>
{% endfor %}
</ul>
{% endblock %}

View File

@ -3,5 +3,5 @@
{% block title %}{{ title }}{% endblock %}
{% block content %}
Hello, world. You're at the core index using Jinja2.
{% trans %}Hello, world. You're at the core index using Jinja2.{% endtrans %}
{% endblock %}

View File

@ -3,15 +3,15 @@
{% block content %}
{% if form.errors %}
<p>Your username and password didn't match. Please try again.</p>
<p>{% trans %}Your username and password didn't match. Please try again.{% endtrans %}</p>
{% endif %}
{% if next %}
{% if user.is_authenticated() %}
<p>Your account doesn't have access to this page. To proceed,
please login with an account that has access.</p>
<p>{% trans %}Your account doesn't have access to this page. To proceed,
please login with an account that has access.{% endtrans %}</p>
{% else %}
<p>Please login to see this page.</p>
<p>{% trans %}Please login to see this page.{% endtrans %}</p>
{% endif %}
{% endif %}
@ -28,11 +28,11 @@
</tr>
</table>
<input type="submit" value="login" />
<input type="submit" value="{% trans %}login{% endtrans %}" />
<input type="hidden" name="next" value="{{ next }}" />
</form>
{# Assumes you setup the password_reset view in your URLconf #}
<p><a href="{{ url('core:password_reset') }}">Lost password?</a></p>
<p><a href="{{ url('core:password_reset') }}">{% trans %}Lost password?{% endtrans %}</a></p>
{% endblock %}

View File

@ -1,23 +1,24 @@
{% extends "core/base.jinja" %}
{% block title %}
{% if page %}
{{ page.get_display_name() }}
{% elif page_list %}
Page list
{% elif new_page %}
Create page
{% else %}
Not found
{% endif %}
{% if page %}
{{ page.get_display_name() }}
{% elif page_list %}
{% trans %}Page list{% endtrans %}
{% elif new_page %}
{% trans %}Create page{% endtrans %}
{% else %}
{% trans %}Not found{% endtrans %}
{% endif %}
{% endblock %}
{% block content %}
{% if page %}
{% block page %}
{% endblock %}
{% else %}
<h2>Page does not exist</h2>
<p><a href="{{ url('core:page_new') }}?page={{ request.resolver_match.kwargs['page_name'] }}">Create it?</a></p>
{% endif %}
{% if page %}
{% block page %}
{% endblock %}
{% else %}
<h2>{% trans %}Page does not exist{% endtrans %}</h2>
<p><a href="{{ url('core:page_new') }}?page={{ request.resolver_match.kwargs['page_name'] }}">
{% trans %}Create it?{% endtrans %}</a></p>
{% endif %}
{% endblock %}

View File

@ -1,25 +1,25 @@
{% extends "core/page.jinja" %}
{% block page %}
<h3>Page</h3>
<p><a href="{{ url('core:page_list') }}">Back to list</a></p>
{% if can_edit(page, user) %}
<p><a href="{{ url('core:page_edit', page_name=page.get_full_name()) }}">Edit</a></p>
{% endif %}
{% if can_edit_prop(page, user) %}
<p><a href="{{ url('core:page_prop', page_name=page.get_full_name()) }}">Prop</a></p>
{% endif %}
<p>You're seeing the page <strong>{{ page.get_display_name() }}</strong> -
<a href="{{ url('core:page_hist', page_name=page.get_full_name()) }}">History</a></p>
<hr>
{% if rev %}
<h4>This may not be the last update, you are seeing revision {{ rev.id }}!</h4>
<h3>{{ rev.title }}</h3>
<div class="page_content">{{ rev.content|markdown }}</div>
{% else %}
<h3>{{ page.revisions.last().title }}</h3>
<div class="page_content">{{ page.revisions.last().content|markdown }}</div>
{% endif %}
<h3>{% trans %}Page{% endtrans %}</h3>
<p><a href="{{ url('core:page_list') }}">{% trans %}Back to list{% endtrans %}</a></p>
{% if can_edit(page, user) %}
<p><a href="{{ url('core:page_edit', page_name=page.get_full_name()) }}">{% trans %}Edit{% endtrans %}</a></p>
{% endif %}
{% if can_edit_prop(page, user) %}
<p><a href="{{ url('core:page_prop', page_name=page.get_full_name()) }}">{% trans %}Prop{% endtrans %}</a></p>
{% endif %}
<p>{% trans page_name=page.get_display_name() %}You're seeing the page {{ page_name }}{% endtrans %} -
<a href="{{ url('core:page_hist', page_name=page.get_full_name()) }}">{% trans %}History{% endtrans %}</a></p>
<hr>
{% if rev %}
<h4>{% trans rev_id=rev.id %}This may not be the last update, you are seeing revision {{ rev_id }}!{% endtrans %}</h4>
<h3>{{ rev.title }}</h3>
<div class="page_content">{{ rev.content|markdown }}</div>
{% else %}
<h3>{{ page.revisions.last().title }}</h3>
<div class="page_content">{{ page.revisions.last().content|markdown }}</div>
{% endif %}
{% endblock %}

View File

@ -1,17 +1,17 @@
{% extends "core/page.jinja" %}
{% block page %}
<h3>Page history</h3>
<p><a href="{{ url('core:page', page.get_full_name()) }}">Back to page</a></p>
<p>You're seeing the history of page <strong>{{ page.get_display_name() }}</strong></p>
<ul>
<li><a href="{{ url('core:page', page_name=page.get_full_name()) }}">
<h3>{% trans %}Page history{% endtrans %}</h3>
<p><a href="{{ url('core:page', page.get_full_name()) }}">{% trans %}Back to page{% endtrans %}</a></p>
<p>{% trans page_name=page.get_display_name() %}You're seeing the history of page {{ page_name }}{% endtrans %}</p>
<ul>
<li><a href="{{ url('core:page', page_name=page.get_full_name()) }}">
last - {{ page.revisions.last().author }} - {{ page.revisions.last().date|date('Y-m-d H:i') }}</a></li>
{% for r in (page.revisions.all()|sort(attribute='date', reverse=True))[1:] %}
<li><a href="{{ url('core:page_rev', page_name=page.get_full_name(), rev=r['id']) }}">
{% for r in (page.revisions.all()|sort(attribute='date', reverse=True))[1:] %}
<li><a href="{{ url('core:page_rev', page_name=page.get_full_name(), rev=r['id']) }}">
{{ r['author'] }} - {{ r['date']|date('Y-m-d H:i') }}</a></li>
{% endfor %}
</ul>
{% endfor %}
</ul>
{% endblock %}

View File

@ -1,20 +1,20 @@
{% extends "core/base.jinja" %}
{% block title %}
Page list
{% trans %}Page list{% endtrans %}
{% endblock %}
{% block content %}
{% if page_list %}
<h3>Page list</h3>
<ul>
{% for p in page_list %}
<li><a href="{{ url('core:page', page_name=p.get_full_name()) }}">{{ p.get_display_name() }}</a></li>
{% endfor %}
</ul>
{% else %}
There is no page in this website.
{% endif %}
{% if page_list %}
<h3>{% trans %}Page list{% endtrans %}</h3>
<ul>
{% for p in page_list %}
<li><a href="{{ url('core:page', page_name=p.get_full_name()) }}">{{ p.get_display_name() }}</a></li>
{% endfor %}
</ul>
{% else %}
{% trans %}There is no page in this website.{% endtrans %}
{% endif %}
{% endblock %}

View File

@ -1,12 +1,12 @@
{% extends "core/page.jinja" %}
{% block content %}
<h2>Page properties</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
</form>
<h2>{% trans %}Page properties{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -16,15 +16,15 @@ function make_preview() {
{% endblock %}
{% block page %}
<h2>Edit page</h2>
<form action="{{ url('core:page_edit', page_name=page.get_full_name()) }}" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="button" value="Preview" onclick="javascript:make_preview();" /></p>
<p><input type="submit" value="Save!" /></p>
</form>
<div id="preview">
</div>
<h2>{% trans %}Edit page{% endtrans %}</h2>
<form action="{{ url('core:page_edit', page_name=page.get_full_name()) }}" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="button" value="{% trans %}Preview{% endtrans %}" onclick="javascript:make_preview();" /></p>
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
<div id="preview">
</div>
{% endblock %}

View File

@ -5,6 +5,6 @@
<form method="post" action="{{ url('core:password_change') }}">
{% csrf_token %}
{{ form.as_p() }}
<input type="submit" value="Change!" />
<input type="submit" value="{% trans %}Change{% endtrans %}" />
</form>
{% endblock %}

View File

@ -1,6 +1,6 @@
{% extends "core/base.jinja" %}
{% block content %}
<p>You successfully changed your password!</p>
<p>{% trans %}You successfully changed your password!{% endtrans %}</p>
{% endblock %}

View File

@ -4,6 +4,6 @@
<form method="post" action="">
{% csrf_token %}
{{ form.as_p() }}
<input type="submit" value="Reset!" />
<input type="submit" value="{% trans %}Reset{% endtrans %}" />
</form>
{% endblock %}

View File

@ -1,8 +1,8 @@
{% extends "core/base.jinja" %}
{% block content %}
<p>You successfully reset your password!</p>
<a href="{{ url('core:login') }}">Login</a>
<p>{% trans %}You successfully reset your password!{% endtrans %}</p>
<a href="{{ url('core:login') }}">{% trans %}Login{% endtrans %}</a>
{% endblock %}

View File

@ -4,7 +4,7 @@
<form method="post" action="">
{% csrf_token %}
{{ form.as_p() }}
<input type="submit" value="Reset" />
<input type="submit" value="{% trans %}Reset{% endtrans %}" />
</form>
{% endblock %}

View File

@ -1,15 +1,15 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Password reset sent</h2>
<h2>{% trans %}Password reset sent{% endtrans %}</h2>
<p>
We've emailed you instructions for setting your password, if an account exists with the email you entered. You should
receive them shortly.
{% trans %}We've emailed you instructions for setting your password, if an account exists with the email you entered. You should
receive them shortly.{% endtrans %}
</p>
<p>
If you don't receive an email, please make sure you've entered the address you registered with, and check your spam
folder.
{% trans %}If you don't receive an email, please make sure you've entered the address you registered with, and check your spam
folder.{% endtrans %}
</p>
{% endblock %}

View File

@ -1,20 +1,20 @@
{% extends "core/base.jinja" %}
{% block title %}{{ title }}{% endblock %}
{% block title %}{% trans %}Register a user{% endtrans %}{% endblock %}
{% block content %}
<h1>{{ title }}</h1>
<h1>{% trans %}Register a user{% endtrans %}</h1>
{% if user_registered %}
Welcome {{ user_registered.get_display_name() }}!
You successfully registred and you will soon receive a confirmation mail.
{% trans user_name=user_registered.get_display_name() %}Welcome {{ user_name }}!{% endtrans %}
{% trans %}You successfully registred and you will soon receive a confirmation mail.{% endtrans %}
Your username is {{ user_registered.username }}.
{% trans username=user_registered.username %}Your username is {{ username }}.{% endtrans %}
{% endif %}
<form action="{{ url('core:register') }}" method="post">
{% csrf_token %}
{{ form }}
<p><input type="submit" value="Register!" /></p>
<p><input type="submit" value="{% trans %}Register{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -3,24 +3,24 @@
{% block content %}
<div>{{ profile.get_display_name() }}</div>
<div class="tool-bar">
<a href="{{ url('core:user_profile', user_id=profile.id) }}">Infos</a>
{% if can_edit(profile, request.user) or user.id == profile.id %}
<a href="{{ url('core:user_edit', user_id=profile.id) }}">Edit</a>
{% endif %}
{% if can_edit_prop(profile, request.user) %}
<a href="{{ url('core:user_groups', user_id=profile.id) }}">Groups</a>
{% endif %}
{% if (profile == request.user
or request.user.is_in_group(settings.SITH_GROUPS['accounting-admin']['name'])
or request.user.is_in_group(settings.SITH_GROUPS['root']['name'])) %}
<a href="{{ url('core:user_account', user_id=profile.id) }}">Account</a>
{% endif %}
<hr>
<a href="{{ url('core:user_profile', user_id=profile.id) }}">{% trans %}Infos{% endtrans %}</a>
{% if can_edit(profile, request.user) or user.id == profile.id %}
<a href="{{ url('core:user_edit', user_id=profile.id) }}">{% trans %}Edit{% endtrans %}</a>
{% endif %}
{% if can_edit_prop(profile, request.user) %}
<a href="{{ url('core:user_groups', user_id=profile.id) }}">{% trans %}Groups{% endtrans %}</a>
{% endif %}
{% if (profile == request.user
or request.user.is_in_group(settings.SITH_GROUPS['accounting-admin']['name'])
or request.user.is_in_group(settings.SITH_GROUPS['root']['name'])) %}
<a href="{{ url('core:user_account', user_id=profile.id) }}">{% trans %}Account{% endtrans %}</a>
{% endif %}
<hr>
</div>
<div>
{% block infos %}
{% endblock %}
{% block infos %}
{% endblock %}
</div>
{% endblock %}

View File

@ -1,25 +1,27 @@
{% extends "core/user_base.jinja" %}
{% block title %}
{{ profile.get_display_name() }}'s profile
{% trans user_name=profile.get_display_name() %}{{ user_name }}'s profile{% endtrans %}
{% endblock %}
{% block infos %}
<h3>User Profile</h3>
<h3>{% trans %}User Profile{% endtrans %}</h3>
<div class="user_profile">
<h4>{{ profile.get_full_name() }}</h4>
<p>{{ profile.nick_name }}</p>
<p>Born: {{ profile.date_of_birth|date("d/m/Y") }}</p>
<h4>{{ profile.get_full_name() }}</h4>
<p>{{ profile.nick_name }}</p>
<p>{% trans %}Born: {% endtrans %}{{ profile.date_of_birth|date("d/m/Y") }}</p>
</div>
{% if user.membership.filter(end_date=None).exists() %}
{# if the user is member of a club, he can view the subscription state #}
<p>
{% if get_subscriber(profile).is_subscribed() %}
User is subscriber until {{ get_subscriber(profile).subscriptions.last().subscription_end }}
{% trans subscription_end=get_subscriber(profile).subscriptions.last().subscription_end %}
User is subscriber until {{ subscription_end }}{% endtrans %}
{% else %}
User is not subscribed. <a href="{{ url('subscription:subscription') }}?member={{ profile.id }}">New subscription</a>
{% trans %}User is not subscribed. {% endtrans %}
<a href="{{ url('subscription:subscription') }}?member={{ profile.id }}">{% trans %}New subscription{% endtrans %}</a>
{% endif %}
</p>
{% endif %}

View File

@ -1,15 +1,15 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Edit user profile</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Update" /></p>
</form>
{% if form.instance == user %}
<p><a href="{{ url('core:password_change') }}">Change my password</a></p>
{% endif %}
<h2>{% trans %}Edit user profile{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Update{% endtrans %}" /></p>
</form>
{% if form.instance == user %}
<p><a href="{{ url('core:password_change') }}">{% trans %}Change my password{% endtrans %}</a></p>
{% endif %}
{% endblock %}

View File

@ -1,12 +1,12 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Edit user groups for {{ profile.get_full_name() }}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Update" /></p>
</form>
<h2>{% trans user_name=profile.get_full_name() %}Edit user groups for {{ user_name }}{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Update{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,11 +1,11 @@
{% extends "core/base.jinja" %}
{% block title %}
User list
{% trans %}User list{% endtrans %}
{% endblock %}
{% block content %}
<h3>User list</h3>
<h3>{% trans %}User list{% endtrans %}</h3>
<ul>
{% for u in user_list %}
<li><a href="{{ url('core:user_profile', user_id=u.id) }}">{{ u.get_display_name() }}</a></li>

View File

@ -1,39 +1,39 @@
{% extends "core/base.jinja" %}
{% block title %}
{{ user.get_display_name() }}'s tools
{% trans user_name=user.get_display_name() %}{{ user_name }}'s tools{% endtrans %}
{% endblock %}
{% block content %}
<h3>User Tools</h3>
<h3>{% trans %}User Tools{% endtrans %}</h3>
<h4>Sith management</h4>
<h4>{% trans %}Sith management{% endtrans %}</h4>
<ul>
{% if user.is_in_group(settings.SITH_GROUPS['root']['name']) %}
<li><a href="{{ url('core:group_list') }}">Groups</a></li>
{% endif %}
{% if user.is_in_group(settings.SITH_GROUPS['counter-admin']['name']) %}
<li><a href="{{ url('counter:admin_list') }}">Counters management</a></li>
{% endif %}
{% if user.is_in_group(settings.SITH_GROUPS['accounting-admin']['name']) %}
<li><a href="{{ url('accounting:bank_list') }}">Accounting</a></li>
{% endif %}
{% if user.is_in_group(settings.SITH_MAIN_BOARD_GROUP) or user.is_in_group(settings.SITH_GROUPS['root']['name']) %}
<li><a href="{{ url('subscription:subscription') }}">Subscriptions</a></li>
{% endif %}
</ul>
<h4>Counters</h4>
<ul>
{% for b in settings.SITH_COUNTER_BARS %}
{% if user.is_in_group(b[1]+" admin") %}
<li><a href="{{ url('counter:details', counter_id=b[0]) }}">{{ b[1] }}</a> -
<a href="{{ url('counter:admin', counter_id=b[0]) }}">Edit</a></li>
{% if user.is_in_group(settings.SITH_GROUPS['root']['name']) %}
<li><a href="{{ url('core:group_list') }}">{% trans %}Groups{% endtrans %}</a></li>
{% endif %}
{% if user.is_in_group(settings.SITH_GROUPS['counter-admin']['name']) %}
<li><a href="{{ url('counter:admin_list') }}">{% trans %}Counters management{% endtrans %}</a></li>
{% endif %}
{% if user.is_in_group(settings.SITH_GROUPS['accounting-admin']['name']) %}
<li><a href="{{ url('accounting:bank_list') }}">{% trans %}Accounting{% endtrans %}</a></li>
{% endif %}
{% if user.is_in_group(settings.SITH_MAIN_BOARD_GROUP) or user.is_in_group(settings.SITH_GROUPS['root']['name']) %}
<li><a href="{{ url('subscription:subscription') }}">{% trans %}Subscriptions{% endtrans %}</a></li>
{% endif %}
{% endfor %}
</ul>
<h4>Clubs</h4>
<h4>{% trans %}Counters{% endtrans %}</h4>
<ul>
{% for b in settings.SITH_COUNTER_BARS %}
{% if user.is_in_group(b[1]+" admin") %}
<li><a href="{{ url('counter:details', counter_id=b[0]) }}">{{ b[1] }}</a> -
<a href="{{ url('counter:admin', counter_id=b[0]) }}">{% trans %}Edit{% endtrans %}</a></li>
{% endif %}
{% endfor %}
</ul>
<h4>{% trans %}Clubs{% endtrans %}</h4>
<ul>
{% for m in user.membership.filter(end_date=None).all() %}
<li><a href="{{ url('club:tools', club_id=m.club.id) }}">{{ m.club }}</a></li>

View File

@ -74,7 +74,7 @@ def password_reset_complete(request):
def register(request):
context = {'title': 'Register a user'}
context = {}
if request.method == 'POST':
form = RegisteringForm(request.POST)
if form.is_valid():

View File

@ -0,0 +1,19 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('counter', '0007_permanency'),
]
operations = [
migrations.AlterField(
model_name='refilling',
name='payment_method',
field=models.CharField(max_length=255, verbose_name='payment method', default='cash', choices=[('cheque', 'Check'), ('cash', 'Cash')]),
),
]

View File

@ -17,59 +17,59 @@
{% endmacro %}
{% block content %}
<h3>Counter</h3>
<h4>{{ counter }}</h4>
<p><strong>Club: </strong> {{ counter.club }}</p>
<h3>{% trans %}Counter{% endtrans %}</h3>
<h4>{{ counter }}</h4>
<p><strong>{% trans %}Club: {% endtrans %}</strong> {{ counter.club }}</p>
<div>
<h5>Customer</h5>
<p>{{ customer.user.get_display_name() }}, {{ customer.amount }} €</p>
</div>
<div>
<h5>Refilling</h5>
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
{{ refill_form.as_p() }}
<input type="hidden" name="action" value="refill">
<input type="submit" value="Go" />
</form>
</div>
<div>
<h5>Selling</h5>
{% if request.session['not_enough'] %}
<p><strong>Not enough money</strong></p>
{% endif %}
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
<input type="hidden" name="action" value="code">
<input type="input" name="code" value="" autofocus />
<input type="submit" value="Go" />
</form>
<p>Basket: </p>
<ul>
<div>
<h5>{% trans %}Customer{% endtrans %}</h5>
<p>{{ customer.user.get_display_name() }}, {{ customer.amount }} €</p>
</div>
<div>
<h5>{% trans %}Refilling{% endtrans %}</h5>
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
{{ refill_form.as_p() }}
<input type="hidden" name="action" value="refill">
<input type="submit" value="{% trans %}Go{% endtrans %}" />
</form>
</div>
<div>
<h5>{% trans %}Selling{% endtrans %}</h5>
{% if request.session['not_enough'] %}
<p><strong>{% trans %}Not enough money{% endtrans %}</strong></p>
{% endif %}
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
<input type="hidden" name="action" value="code">
<input type="input" name="code" value="" autofocus />
<input type="submit" value="{% trans %}Go{% endtrans %}" />
</form>
<p>{% trans %}Basket: {% endtrans %}</p>
<ul>
{% for id,infos in request.session['basket'].items() %}
{% set product = counter.products.filter(id=id).first() %}
{% set s = infos['qty'] * infos['price'] / 100 %}
<li>{{ del_product(id, '-') }} {{ infos['qty'] }} {{ add_product(id, '+') }} {{ product.name }}: {{ "%0.2f"|format(s) }} €</li>
{% set product = counter.products.filter(id=id).first() %}
{% set s = infos['qty'] * infos['price'] / 100 %}
<li>{{ del_product(id, '-') }} {{ infos['qty'] }} {{ add_product(id, '+') }} {{ product.name }}: {{ "%0.2f"|format(s) }} €</li>
{% endfor %}
</ul>
<p><strong>Total: {{ "%0.2f"|format(basket_total) }} €</strong></p>
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
<input type="hidden" name="action" value="finish">
<input type="submit" value="Finish" />
</form>
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
<input type="hidden" name="action" value="cancel">
<input type="submit" value="Cancel" />
</form>
<p><strong>Products: </strong>
{% for p in counter.products.all() %}
{{ add_product(p.id, p.name) }}
{% endfor %}
</p>
</div>
</ul>
<p><strong>{% trans %}Total: {% endtrans %}{{ "%0.2f"|format(basket_total) }} €</strong></p>
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
<input type="hidden" name="action" value="finish">
<input type="submit" value="{% trans %}Finish{% endtrans %}" />
</form>
<form method="post" action="{{ url('counter:click', counter_id=counter.id, user_id=customer.user.id) }}">
{% csrf_token %}
<input type="hidden" name="action" value="cancel">
<input type="submit" value="{% trans %}Cancel{% endtrans %}" />
</form>
<p><strong>{% trans %}Products: {% endtrans %}</strong>
{% for p in counter.products.all() %}
{{ add_product(p.id, p.name) }}
{% endfor %}
</p>
</div>
{% endblock %}

View File

@ -1,12 +1,12 @@
{% extends "core/base.jinja" %}
{% block content %}
<h2>Edit counter</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
</form>
<h2>{% trans %}Edit counter{% endtrans %}</h2>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}

View File

@ -1,22 +1,22 @@
{% extends "core/base.jinja" %}
{% block title %}
Counter admin list
{% trans %}Counter admin list{% endtrans %}
{% endblock %}
{% block content %}
<p><a href="{{ url('counter:new') }}">New counter</a></p>
{% if counter_list %}
<h3>Counter admin list</h3>
<ul>
{% for c in counter_list %}
<li><a href="{{ url('counter:details', counter_id=c.id) }}">{{ c }}</a> -
<a href="{{ url('counter:admin', counter_id=c.id) }}">Edit</a></li>
{% endfor %}
</ul>
{% else %}
There is no counters in this website.
{% endif %}
<p><a href="{{ url('counter:new') }}">{% trans %}New counter{% endtrans %}</a></p>
{% if counter_list %}
<h3>{% trans %}Counter admin list{% endtrans %}</h3>
<ul>
{% for c in counter_list %}
<li><a href="{{ url('counter:details', counter_id=c.id) }}">{{ c }}</a> -
<a href="{{ url('counter:admin', counter_id=c.id) }}">{% trans %}Edit{% endtrans %}</a></li>
{% endfor %}
</ul>
{% else %}
{% trans %}There is no counters in this website.{% endtrans %}
{% endif %}
{% endblock %}

View File

@ -9,37 +9,37 @@
{% endmacro %}
{% block content %}
<h3>Counter</h3>
<h3>{% trans %}Counter{% endtrans %}</h3>
<h4>{{ counter }}</h4>
<p><strong>Club: </strong> {{ counter.club }}</p>
<p><strong>Products: </strong> {{ counter.products.all() }}</p>
<p><strong>{% trans %}Club: {% endtrans %}</strong> {{ counter.club }}</p>
<p><strong>{% trans %}Products: {% endtrans %}</strong> {{ counter.products.all() }}</p>
<div>
<h3>Sellings</h3>
<h3>{% trans %}Sellings{% endtrans %}</h3>
{% if last_basket %}
<h4>Last selling: </h4>
<p>Client: {{ last_customer }}, new amount: {{ new_customer_amount }} €.</p>
<h4>{% trans %}Last selling: {% endtrans %}</h4>
<p>{% trans %}Client: {% endtrans %}{{ last_customer }} - {% trans %}New amount: {% endtrans %}{{ new_customer_amount }} €.</p>
<ul>
{% for s in last_basket %}
<li>{{ s }}</li>
{% endfor %}
</ul>
<p><strong>Total: {{ last_total }} €</strong></p>
<p><strong>{% trans %}Total: {% endtrans %}{{ last_total }} €</strong></p>
{% endif %}
{% if barmen %}
<p>Enter client code:</p>
<p>{% trans %}Enter client code:{% endtrans %}</p>
<form method="post" action="{{ url('counter:details', counter_id=counter.id) }}">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="VALIDATE" /></p>
<p><input type="submit" value="{% trans %}validate{% endtrans %}" /></p>
</form>
{% else %}
<p>Please, login</p>
<p>{% trans %}Please, login{% endtrans %}</p>
{% endif %}
</div>
<div>
<h3>Barman: </h3>
<h3>{% trans %}Barman: {% endtrans %}</h3>
<ul>
{% for b in barmen %}
<li>{{ barman_logout_link(b) }}</li>
@ -48,7 +48,7 @@
<form method="post" action="{{ url('counter:login', counter_id=counter.id) }}">
{% csrf_token %}
{{ login_form.as_p() }}
<p><input type="submit" value="LOGIN" /></p>
<p><input type="submit" value="{% trans %}login{% endtrans %}" /></p>
</form>
</div>
{% endblock %}

View File

@ -1,15 +1,13 @@
{% extends "core/user_base.jinja" %}
{% block title %}
{{ profile.get_display_name() }}'s account
{% trans user_name=profile.get_display_name() %}{{ user_name }}'s account{% endtrans %}
{% endblock %}
{% block infos %}
<h3>User account</h3>
<h3>{% trans %}User account{% endtrans %}</h3>
<p>{{ customer.refillings.all() }}</p>
<p>{{ customer.buyings.all() }}</p>
{% endblock %}

Binary file not shown.

View File

@ -6,7 +6,7 @@
msgid ""
msgstr ""
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-07-18 15:44+0000\n"
"POT-Creation-Date: 2016-07-19 17:00+0000\n"
"PO-Revision-Date: 2016-07-18\n"
"Last-Translator: Skia <skia@libskia.so>\n"
"Language-Team: AE info <ae.info@utbm.fr>\n"
@ -84,6 +84,172 @@ msgstr "code"
msgid "movement type"
msgstr "type de mouvement"
#: accounting/templates/accounting/accountingtype_list.jinja:4
#: accounting/templates/accounting/accountingtype_list.jinja:10
msgid "Accounting type list"
msgstr "Liste des types comptable"
#: accounting/templates/accounting/accountingtype_list.jinja:8
msgid "New accounting type"
msgstr "Nouveau type comptable"
#: accounting/templates/accounting/accountingtype_list.jinja:17
msgid "There is no types in this website."
msgstr "Il n'y a pas de types comptable dans ce site web."
#: accounting/templates/accounting/bank_account_details.jinja:5
#: accounting/templates/accounting/club_account_details.jinja:5
#: accounting/templates/accounting/journal_details.jinja:5
#: core/templates/core/user_tools.jinja:19
msgid "Accounting"
msgstr "Comptabilité"
#: accounting/templates/accounting/bank_account_details.jinja:8
msgid "View account"
msgstr "Voir le compte"
#: accounting/templates/accounting/bank_account_details.jinja:9
msgid "New club account"
msgstr "Nouveau compte club"
#: accounting/templates/accounting/bank_account_details.jinja:13
#: accounting/templates/accounting/bank_account_list.jinja:15
#: accounting/templates/accounting/club_account_details.jinja:45
#: accounting/templates/accounting/journal_details.jinja:48
#: club/templates/club/club_detail.jinja:7
#: core/templates/core/page_detail.jinja:7
#: core/templates/core/user_base.jinja:8
#: core/templates/core/user_tools.jinja:31
#: counter/templates/counter/counter_list.jinja:14
msgid "Edit"
msgstr "Éditer"
#: accounting/templates/accounting/bank_account_details.jinja:14
#: accounting/templates/accounting/bank_account_list.jinja:16
#: core/templates/core/group_list.jinja:13
msgid "Delete"
msgstr "Supprimer"
#: accounting/templates/accounting/bank_account_list.jinja:4
#: accounting/templates/accounting/bank_account_list.jinja:11
msgid "Bank account list"
msgstr "Liste des comptes en banque"
#: accounting/templates/accounting/bank_account_list.jinja:8
msgid "Manage accounting types"
msgstr "Gérer les types comptable"
#: accounting/templates/accounting/bank_account_list.jinja:9
msgid "New bank account"
msgstr "Nouveau compte en banque"
#: accounting/templates/accounting/bank_account_list.jinja:20
msgid "There is no accounts in this website."
msgstr "Il n'y a pas de comptes dans ce site web."
#: accounting/templates/accounting/club_account_details.jinja:8
msgid "View account:"
msgstr "Voir le compte:"
#: accounting/templates/accounting/club_account_details.jinja:15
msgid "New journal"
msgstr "Nouveau classeur"
#: accounting/templates/accounting/club_account_details.jinja:17
msgid "You can not create new journal while you still have one opened"
msgstr "Vous ne pouvez pas créer de journal tant qu'il y en a un d'ouvert"
#: accounting/templates/accounting/club_account_details.jinja:21
msgid "Name"
msgstr "Nom"
#: accounting/templates/accounting/club_account_details.jinja:22
msgid "Start"
msgstr "Début"
#: accounting/templates/accounting/club_account_details.jinja:23
msgid "End"
msgstr "Fin"
#: accounting/templates/accounting/club_account_details.jinja:24
#: accounting/templates/accounting/journal_details.jinja:22
msgid "Amount"
msgstr "Montant"
#: accounting/templates/accounting/club_account_details.jinja:25
msgid "Effective amount"
msgstr "Montant effectif"
#: accounting/templates/accounting/club_account_details.jinja:26
msgid "Closed"
msgstr "Fermé"
#: accounting/templates/accounting/club_account_details.jinja:40
#: accounting/templates/accounting/journal_details.jinja:41
msgid "Yes"
msgstr "Oui"
#: accounting/templates/accounting/club_account_details.jinja:42
#: accounting/templates/accounting/journal_details.jinja:43
msgid "No"
msgstr "Non"
#: accounting/templates/accounting/club_account_details.jinja:44
msgid "View"
msgstr "Voir"
#: accounting/templates/accounting/journal_details.jinja:10
msgid "Amount: "
msgstr "Montant: "
#: accounting/templates/accounting/journal_details.jinja:11
msgid "Effective amount: "
msgstr "Montant effectif: "
#: accounting/templates/accounting/journal_details.jinja:13
msgid "Journal is closed, you can not create operation"
msgstr "Le classeur est fermé, vous ne pouvez pas créer d'opération"
#: accounting/templates/accounting/journal_details.jinja:15
msgid "New operation"
msgstr "Nouvelle opération"
#: accounting/templates/accounting/journal_details.jinja:19
msgid "Nb"
msgstr "No"
#: accounting/templates/accounting/journal_details.jinja:20
msgid "Date"
msgstr "Date"
#: accounting/templates/accounting/journal_details.jinja:21
msgid "Label"
msgstr "Intitulé"
#: accounting/templates/accounting/journal_details.jinja:23
msgid "Payment mode"
msgstr "Méthode de paiement"
#: accounting/templates/accounting/journal_details.jinja:25
msgid "Code"
msgstr "Code"
#: accounting/templates/accounting/journal_details.jinja:26
msgid "Nature"
msgstr "Nature"
#: accounting/templates/accounting/journal_details.jinja:27
msgid "Done"
msgstr "Effectué"
#: accounting/templates/accounting/journal_details.jinja:28
msgid "Comment"
msgstr "Commentaire"
#: accounting/templates/accounting/journal_details.jinja:29
msgid "Actions"
msgstr "Actions"
#: club/models.py:20
msgid "unix name"
msgstr "nom unix"
@ -108,6 +274,14 @@ msgstr "Adresse"
msgid "You can not make loops in clubs"
msgstr "Vous ne pouvez pas faire de boucles dans les clubs"
#: club/models.py:107
msgid "user"
msgstr "nom d'utilisateur"
#: club/models.py:108
msgid "club"
msgstr "club"
#: club/models.py:111
msgid "role"
msgstr "rôle"
@ -129,9 +303,74 @@ msgstr "L'utilisateur est déjà membre de ce club"
msgid "past member"
msgstr "Anciens membres"
#: club/templates/club/club_detail.jinja:4
msgid "Club"
msgstr "Club"
#: club/templates/club/club_detail.jinja:5
#: core/templates/core/group_edit.jinja:4
#: core/templates/core/page_detail.jinja:5
msgid "Back to list"
msgstr "Retour à la liste"
#: club/templates/club/club_detail.jinja:10
#: core/templates/core/page_detail.jinja:10
msgid "Prop"
msgstr "Propriétés"
#: club/templates/club/club_detail.jinja:14
msgid "Members"
msgstr "Membres"
#: club/templates/club/club_edit.jinja:4
msgid "Edit club"
msgstr "Éditer le club"
#: club/templates/club/club_edit.jinja:8
#: club/templates/club/club_edit_prop.jinja:8
#: core/templates/core/create.jinja:8 core/templates/core/edit.jinja:8
#: core/templates/core/page_prop.jinja:8
#: core/templates/core/pagerev_edit.jinja:24
#: counter/templates/counter/counter_edit.jinja:8
#: subscription/templates/subscription/subscription.jinja:12
msgid "Save"
msgstr "Sauver"
#: club/templates/club/club_edit_prop.jinja:4
msgid "Edit club properties"
msgstr "Éditer les propriétés du club"
#: club/templates/club/club_list.jinja:4 club/templates/club/club_list.jinja:24
msgid "Club list"
msgstr "Liste des clubs"
#: club/templates/club/club_list.jinja:21
msgid "New club"
msgstr "Nouveau club"
#: club/templates/club/club_list.jinja:31
msgid "There is no club in this website."
msgstr "Il n'y a pas de club dans ce site web."
#: club/templates/club/club_members.jinja:4
msgid "Club members"
msgstr "Membres du club"
#: club/templates/club/club_members.jinja:13
msgid "Add"
msgstr "Ajouter"
#: club/templates/club/club_tools.jinja:4
msgid "Club tools"
msgstr "Outils du club"
#: club/templates/club/club_tools.jinja:8
msgid "Counters:"
msgstr "Comptoirs:"
#: core/models.py:23
msgid "meta group status"
msgstr "Status du meta-groupe"
msgstr "status du meta-groupe"
#: core/models.py:25
msgid "Whether a group is a meta group or not"
@ -239,14 +478,249 @@ msgstr "titre de la page"
msgid "page content"
msgstr "contenu de la page"
#: core/templates/core/403.jinja:5
msgid "403, Forbidden"
msgstr "403. Non autorisé"
#: core/templates/core/404.jinja:5
msgid "404, Not Found"
msgstr "404. Non trouvé"
#: core/templates/core/base.jinja:5
msgid "Welcome!"
msgstr "Bienvenue!"
#: core/templates/core/base.jinja:15
msgid "Logo"
msgstr "Logo"
#: core/templates/core/base.jinja:19
#: core/templates/core/password_reset_complete.jinja:5
msgid "Login"
msgstr "Connexion"
#: core/templates/core/base.jinja:20 core/templates/core/register.jinja:18
msgid "Register"
msgstr "S'enregister"
#: core/templates/core/base.jinja:23
msgid "Tools"
msgstr "Outils"
#: core/templates/core/base.jinja:24
msgid "Logout"
msgstr "Déconnexion"
#: core/templates/core/base.jinja:29
msgid "Users"
msgstr "Utilisateurs"
#: core/templates/core/base.jinja:30
msgid "Pages"
msgstr "Pages"
#: core/templates/core/base.jinja:31 core/templates/core/user_tools.jinja:36
msgid "Clubs"
msgstr "Clubs"
#: core/templates/core/base.jinja:44
msgid "Site made by good people"
msgstr "Site réalisé par des gens biens"
#: core/templates/core/create.jinja:4
msgid "Create"
msgstr "Créer"
#: core/templates/core/delete_confirm.jinja:4
msgid "Delete confirmation"
msgstr "Confirmation de suppression"
#: core/templates/core/delete_confirm.jinja:6
#, python-format
msgid "Are you sure you want to delete \"%(obj)s\"?"
msgstr "Êtes-vous sûr de vouloir supprimer \"%(obj)s\" ?"
#: core/templates/core/delete_confirm.jinja:7
msgid "Confirm"
msgstr "Confirmation"
#: core/templates/core/delete_confirm.jinja:8
#: counter/templates/counter/counter_click.jinja:65
msgid "Cancel"
msgstr "Annuler"
#: core/templates/core/edit.jinja:4
#, python-format
msgid "Edit %(obj)s"
msgstr "Éditer %(obj)s"
#: core/templates/core/group_edit.jinja:5
msgid "Edit group"
msgstr "Éditer le groupe"
#: core/templates/core/group_edit.jinja:9 core/templates/core/user_edit.jinja:8
#: core/templates/core/user_group.jinja:8
msgid "Update"
msgstr "Mettre à jour"
#: core/templates/core/group_list.jinja:4
#: core/templates/core/group_list.jinja:8
msgid "Group list"
msgstr "Liste des groupes"
#: core/templates/core/group_list.jinja:9
msgid "New group"
msgstr "Nouveau groupe"
#: core/templates/core/index.jinja:6
msgid "Hello, world. You're at the core index using Jinja2."
msgstr "Hello, world! Vous êtes sur la page d'accueil utilisant Jinja2."
#: core/templates/core/login.jinja:6
msgid "Your username and password didn't match. Please try again."
msgstr ""
"Votre nom d'utilisateur et votre mot de passe ne correspondent pas. Merci de "
"réessayer."
#: core/templates/core/login.jinja:11
msgid ""
"Your account doesn't have access to this page. To proceed,\n"
" please login with an account that has access."
msgstr ""
"Votre compte n'a pas accès à cette page. Merci de vous identifier avec un "
"compte qui a accès."
#: core/templates/core/login.jinja:14
msgid "Please login to see this page."
msgstr "Merci de vous identifier pour voir cette page."
#: core/templates/core/login.jinja:31
#: counter/templates/counter/counter_main.jinja:51
msgid "login"
msgstr "login"
#: core/templates/core/login.jinja:36
msgid "Lost password?"
msgstr "Mot de passe perdu ?"
#: core/templates/core/page.jinja:7 core/templates/core/page_list.jinja:4
#: core/templates/core/page_list.jinja:9
msgid "Page list"
msgstr "Liste des pages"
#: core/templates/core/page.jinja:9
msgid "Create page"
msgstr "Créer une page"
#: core/templates/core/page.jinja:11
msgid "Not found"
msgstr "Non trouvé"
#: core/templates/core/page.jinja:20
msgid "Page does not exist"
msgstr "La page n'existe pas."
#: core/templates/core/page.jinja:22
msgid "Create it?"
msgstr "La créer ?"
#: core/templates/core/page_detail.jinja:4
msgid "Page"
msgstr "Page"
#: core/templates/core/page_detail.jinja:12
#, python-format
msgid "You're seeing the page %(page_name)s"
msgstr "Vous consultez la page %(page_name)s"
#: core/templates/core/page_detail.jinja:13
msgid "History"
msgstr "Historique"
#: core/templates/core/page_detail.jinja:16
#, python-format
msgid "This may not be the last update, you are seeing revision %(rev_id)s!"
msgstr ""
"Ceci n'est peut-être pas la dernière version de la page. Vous consultez la "
"version %(rev_id)s."
#: core/templates/core/page_hist.jinja:4
msgid "Page history"
msgstr "Historique de la page"
#: core/templates/core/page_hist.jinja:5
msgid "Back to page"
msgstr "Retour à la page"
#: core/templates/core/page_hist.jinja:6
msgid "You're seeing the history of page %(page_name)s"
msgstr "Vous consultez l'historique de la page %(page_name)s"
#: core/templates/core/page_list.jinja:16
msgid "There is no page in this website."
msgstr "Il n'y a pas de page sur ce site web."
#: core/templates/core/page_prop.jinja:4
msgid "Page properties"
msgstr "Propriétés de la page"
#: core/templates/core/pagerev_edit.jinja:19
msgid "Edit page"
msgstr "Éditer la page"
#: core/templates/core/pagerev_edit.jinja:23
msgid "Preview"
msgstr "Prévisualiser"
#: core/templates/core/password_change.jinja:8
msgid "Change"
msgstr "Changer"
#: core/templates/core/password_change_done.jinja:4
msgid "You successfully changed your password!"
msgstr "Vous avez correctement changé votre mot de passe !"
#: core/templates/core/password_reset.jinja:7
#: core/templates/core/password_reset_confirm.jinja:7
msgid "Reset"
msgstr "Reset"
#: core/templates/core/password_reset_complete.jinja:4
msgid "You successfully reset your password!"
msgstr "Vous avez correctement réinitialisé votre mot de passe !"
#: core/templates/core/password_reset_done.jinja:4
msgid "Password reset sent"
msgstr "Réinitialisation de mot de passe envoyée"
#: core/templates/core/password_reset_done.jinja:7
msgid ""
"We've emailed you instructions for setting your password, if an account "
"exists with the email you entered. You should\n"
"receive them shortly."
msgstr ""
"Nous vous avons envoyé les instructions pour réinitialiser votre mot de "
"passe par email, si un compte avec l'email entré existe effectivement.\n"
"Vous devriez les recevoir rapidement."
#: core/templates/core/password_reset_done.jinja:12
msgid ""
"If you don't receive an email, please make sure you've entered the address "
"you registered with, and check your spam\n"
"folder."
msgstr ""
"Si vous ne recevez pas d'email, assurez-vous d'avoir correctement entré "
"l'adresse email avec laquelle vous vous êtes inscrit, et vérifiez votre "
"dossier de spam."
#: core/templates/core/password_reset_email.jinja:2
#, python-format
# msgid ""
# "You're receiving this email because you requested a password reset for your "
# "user account at %(site_name)s."
# msgstr ""
# "Vous avez reçu cet email parce que vous avez demandé une réinitialisation du "
# "mot de passe pour votre compte sur le site %(site_name)."
msgid ""
"You're receiving this email because you requested a password reset for your "
"user account at %(site_name)s."
msgstr ""
"Vous avez reçu cet email parce que vous avez demandé une réinitialisation du "
"mot de passe pour votre compte sur le site %(site_name)s."
#: core/templates/core/password_reset_email.jinja:4
msgid "Please go to the following page and choose a new password:"
@ -260,13 +734,121 @@ msgstr "Votre nom d'utilisateur, en cas d'oubli :"
#: core/templates/core/password_reset_email.jinja:10
msgid "Thanks for using our site! "
msgstr "Merci d'utiliser notre site!"
msgstr "Merci d'utiliser notre site !"
#: core/templates/core/password_reset_email.jinja:12
#, python-format
msgid "The %(site_name)s team"
msgstr "L'équipe de %(site_name)s"
#: core/templates/core/register.jinja:3 core/templates/core/register.jinja:6
msgid "Register a user"
msgstr "Enregistrer un utilisateur"
#: core/templates/core/register.jinja:9
#, python-format
msgid "Welcome %(user_name)s!"
msgstr "Bienvenue, %(user_name)s!"
#: core/templates/core/register.jinja:10
msgid ""
"You successfully registred and you will soon receive a confirmation mail."
msgstr ""
"Vous vous êtes correctement enregistré, et vous devriez recevoir rapidement "
"un email de confirmation."
#: core/templates/core/register.jinja:12
#, python-format
msgid "Your username is %(username)s."
msgstr "Votre nom d'utilisateur est %(username)s."
#: core/templates/core/user_base.jinja:6
msgid "Infos"
msgstr "Infos"
#: core/templates/core/user_base.jinja:11
#: core/templates/core/user_tools.jinja:13
msgid "Groups"
msgstr "Groupes"
#: core/templates/core/user_base.jinja:16
msgid "Account"
msgstr "Compte"
#: core/templates/core/user_detail.jinja:4
#, python-format
msgid "%(user_name)s's profile"
msgstr "Profil de %(user_name)s"
#: core/templates/core/user_detail.jinja:8
msgid "User Profile"
msgstr "Profil de l'utilisateur"
#: core/templates/core/user_detail.jinja:13
msgid "Born: "
msgstr "Né le : "
#: core/templates/core/user_detail.jinja:20
#, python-format
msgid ""
"\n"
"User is subscriber until %(subscription_end)s"
msgstr ""
"\n"
"L'utilisateur est cotisant jusqu'au %(subscription_end)s"
#: core/templates/core/user_detail.jinja:23
msgid "User is not subscribed. "
msgstr "L'utilisateur n'est pas cotisant."
#: core/templates/core/user_detail.jinja:24
#: subscription/templates/subscription/subscription.jinja:4
#: subscription/templates/subscription/subscription.jinja:8
msgid "New subscription"
msgstr "Nouvelle cotisation"
#: core/templates/core/user_edit.jinja:4
msgid "Edit user profile"
msgstr "Éditer le profil de l'utilisateur"
#: core/templates/core/user_edit.jinja:11
msgid "Change my password"
msgstr "Changer mon mot de passe"
#: core/templates/core/user_group.jinja:4
#, python-format
msgid "Edit user groups for %(user_name)s"
msgstr "Éditer les groupes pour %(user_name)s"
#: core/templates/core/user_list.jinja:4 core/templates/core/user_list.jinja:8
msgid "User list"
msgstr "Liste d'utilisateurs"
#: core/templates/core/user_tools.jinja:4
#, python-format
msgid "%(user_name)s's tools"
msgstr "Outils de %(user_name)s"
#: core/templates/core/user_tools.jinja:8
msgid "User Tools"
msgstr "Outils utilisateurs"
#: core/templates/core/user_tools.jinja:10
msgid "Sith management"
msgstr "Gestion de Sith"
#: core/templates/core/user_tools.jinja:16
msgid "Counters management"
msgstr "Gestion des comptoirs"
#: core/templates/core/user_tools.jinja:22
msgid "Subscriptions"
msgstr "Cotisations"
#: core/templates/core/user_tools.jinja:26
msgid "Counters"
msgstr "Comptoirs"
#: counter/models.py:20
msgid "account id"
msgstr "numéro de compte"
@ -315,6 +897,113 @@ msgstr "prix unitaire"
msgid "quantity"
msgstr "quantité"
#: counter/templates/counter/counter_click.jinja:20
#: counter/templates/counter/counter_main.jinja:12
msgid "Counter"
msgstr "Comptoir"
#: counter/templates/counter/counter_click.jinja:22
#: counter/templates/counter/counter_main.jinja:14
msgid "Club: "
msgstr "Club : "
#: counter/templates/counter/counter_click.jinja:25
msgid "Customer"
msgstr "Client"
#: counter/templates/counter/counter_click.jinja:29
msgid "Refilling"
msgstr "Rechargement"
#: counter/templates/counter/counter_click.jinja:34
#: counter/templates/counter/counter_click.jinja:46
msgid "Go"
msgstr "Valider"
#: counter/templates/counter/counter_click.jinja:38
msgid "Selling"
msgstr "Vente"
#: counter/templates/counter/counter_click.jinja:40
msgid "Not enough money"
msgstr "Solde insuffisant"
#: counter/templates/counter/counter_click.jinja:48
msgid "Basket: "
msgstr "Panier : "
#: counter/templates/counter/counter_click.jinja:56
#: counter/templates/counter/counter_main.jinja:28
msgid "Total: "
msgstr "Total : "
#: counter/templates/counter/counter_click.jinja:60
msgid "Finish"
msgstr "Terminer"
#: counter/templates/counter/counter_click.jinja:67
#: counter/templates/counter/counter_main.jinja:15
msgid "Products: "
msgstr "Produits : "
#: counter/templates/counter/counter_edit.jinja:4
msgid "Edit counter"
msgstr "Éditer le comptoir"
#: counter/templates/counter/counter_list.jinja:4
#: counter/templates/counter/counter_list.jinja:10
msgid "Counter admin list"
msgstr "Liste des comptoirs"
#: counter/templates/counter/counter_list.jinja:8
msgid "New counter"
msgstr "Nouveau comptoir"
#: counter/templates/counter/counter_list.jinja:18
msgid "There is no counters in this website."
msgstr "Il n'y a pas de comptoirs dans ce site web."
#: counter/templates/counter/counter_main.jinja:19
msgid "Sellings"
msgstr "Ventes"
#: counter/templates/counter/counter_main.jinja:21
msgid "Last selling: "
msgstr "Dernière vente : "
#: counter/templates/counter/counter_main.jinja:22
msgid "Client: "
msgstr "Client : "
#: counter/templates/counter/counter_main.jinja:22
msgid "New amount: "
msgstr "Nouveau montant : "
#: counter/templates/counter/counter_main.jinja:31
msgid "Enter client code:"
msgstr "Entrez un code client : "
#: counter/templates/counter/counter_main.jinja:35
msgid "validate"
msgstr "valider"
#: counter/templates/counter/counter_main.jinja:38
msgid "Please, login"
msgstr "Merci de vous identifier"
#: counter/templates/counter/counter_main.jinja:42
msgid "Barman: "
msgstr "Barman : "
#: counter/templates/counter/user_account.jinja:4
#, python-format
msgid "%(user_name)s's account"
msgstr "Compte de %(user_name)s"
#: counter/templates/counter/user_account.jinja:8
msgid "User account"
msgstr "Compte utilisateur"
#: counter/views.py:194
msgid "END"
msgstr "FIN"

View File

@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('subscription', '0001_initial'),
]
operations = [
migrations.AlterField(
model_name='subscription',
name='payment_method',
field=models.CharField(max_length=255, verbose_name='payment method', choices=[('cheque', 'Check'), ('cash', 'Cash'), ('other', 'Other')]),
),
migrations.AlterField(
model_name='subscription',
name='subscription_type',
field=models.CharField(max_length=255, verbose_name='subscription type', choices=[('cursus-branche', 'Branch cursus'), ('cursus-tronc-commun', 'Common core cursus'), ('deux-semestres', 'Two semesters'), ('un-semestre', 'One semester')]),
),
]

View File

@ -1,14 +1,14 @@
{% extends "core/base.jinja" %}
{% block title %}
New subscription
{% trans %}New subscription{% endtrans %}
{% endblock %}
{% block content %}
<h3>New subscription</h3>
<h3>{% trans %}New subscription{% endtrans %}</h3>
<form action="" method="post">
{% csrf_token %}
{{ form.as_p() }}
<p><input type="submit" value="Save!" /></p>
<p><input type="submit" value="{% trans %}Save{% endtrans %}" /></p>
</form>
{% endblock %}