mirror of https://gitlab.crans.org/bde/nk20
Inclusif, admin and migrations (treasury summary)
This commit is contained in:
parent
15c71ad31a
commit
eda8460014
|
@ -0,0 +1,18 @@
|
||||||
|
# Generated by Django 2.2.28 on 2024-08-07 12:09
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('member', '0012_club_add_registration_form'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='profile',
|
||||||
|
name='promotion',
|
||||||
|
field=models.PositiveSmallIntegerField(default=2024, help_text='Year of entry to the school (None if not ENS student)', null=True, verbose_name='promotion'),
|
||||||
|
),
|
||||||
|
]
|
|
@ -13,47 +13,47 @@
|
||||||
</h1>
|
</h1>
|
||||||
|
|
||||||
<h2>
|
<h2>
|
||||||
Tous les utilisateurs :
|
Tous les utilisateur⋅rices :
|
||||||
</h2>
|
</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Positifs : {{ summary.total_positive_user }} soit {{ summary.balance_positive_user }} euros</li>
|
<li>Positifs : {{ summary.total_positive_user }} soit {{ summary.balance_positive_user / 100 }} €</li>
|
||||||
<li>Neutres : {{ summary.total_zero_user }}</li>
|
<li>Neutres : {{ summary.total_zero_user }}</li>
|
||||||
<li>Négatifs : {{ summary.total_negative_user }} soit {{ summary.balance_negative_user }} euros</li>
|
<li>Négatifs : {{ summary.total_negative_user }} soit {{ summary.balance_negative_user / 100 }} €</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<h2>
|
<h2>
|
||||||
Les adhérents BDE :
|
Les {{ summary.total_positive_user_bde + summary.total_zero_user_bde + summary.total_negative_user_bde }} adhérent⋅es BDE :
|
||||||
</h2>
|
</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Positifs : {{ summary.total_positive_user_bde }} soit {{ summary.balance_positive_user_bde }} euros</li>
|
<li>Positifs : {{ summary.total_positive_user_bde }} soit {{ summary.balance_positive_user_bde / 100 }} €</li>
|
||||||
<li>Neutres : {{ summary.total_zero_user_bde }}</li>
|
<li>Neutres : {{ summary.total_zero_user_bde }}</li>
|
||||||
<li>Négatifs : {{ summary.total_negative_user_bde }} soit {{ summary.balance_negative_user_bde }} euros</li>
|
<li>Négatifs : {{ summary.total_negative_user_bde }} soit {{ summary.balance_negative_user_bde / 100 }} €</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<h2>
|
<h2>
|
||||||
Clubs :
|
Clubs :
|
||||||
</h2>
|
</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Positifs : {{ summary.total_positive_club }} soit {{ summary.balance_positive_club }} euros</li>
|
<li>Positifs : {{ summary.total_positive_club }} soit {{ summary.balance_positive_club / 100 }} €</li>
|
||||||
<li>Neutres : {{ summary.total_zero_club }}</li>
|
<li>Neutres : {{ summary.total_zero_club }}</li>
|
||||||
<li>Négatifs : {{ summary.total_negative_club }} soit {{ summary.balance_negative_club }} euros</li>
|
<li>Négatifs : {{ summary.total_negative_club }} soit {{ summary.balance_negative_club / 100 }} €</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<h2>
|
<h2>
|
||||||
Clubs hors BDE / Kfet et club dont le nom fini par "- BDE" :
|
Clubs hors BDE / Kfet et club dont le nom fini par "- BDE" :
|
||||||
</h2>
|
</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Positifs : {{ summary.total_positive_club_nbde }} soit {{ summary.balance_positive_club_nbde }} euros</li>
|
<li>Positifs : {{ summary.total_positive_club_nbde }} soit {{ summary.balance_positive_club_nbde / 100 }} €</li>
|
||||||
<li>Neutres : {{ summary.total_zero_club_nbde }}</li>
|
<li>Neutres : {{ summary.total_zero_club_nbde }}</li>
|
||||||
<li>Négatifs : {{ summary.total_negative_club_nbde }} soit {{ summary.balance_negative_club_nbde }} euros</li>
|
<li>Négatifs : {{ summary.total_negative_club_nbde }} soit {{ summary.balance_negative_club_nbde / 100 }} €</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<h2>
|
<h2>
|
||||||
Progression :
|
Progression :
|
||||||
</h2>
|
</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Ceci correspond à une différence de {{ balance_difference_user }} euros pour les utilisateurs</li>
|
<li>Ceci correspond à une différence de {{ balance_difference_user / 100 }} € pour les utilisateur⋅rices</li>
|
||||||
<li>Ceci correspond à une différence de {{ balance_difference_club }} euros pour les clubs</li>
|
<li>Ceci correspond à une différence de {{ balance_difference_club / 100 }} € pour les clubs</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
--
|
--
|
||||||
|
|
|
@ -3,29 +3,29 @@
|
||||||
|
|
||||||
Récapitulatif de trésorerie au {{ summary.date|date:"d/m/Y" }} à {{ summary.date|date:"H:i:s" }} :
|
Récapitulatif de trésorerie au {{ summary.date|date:"d/m/Y" }} à {{ summary.date|date:"H:i:s" }} :
|
||||||
|
|
||||||
Tous les utilisateurs :
|
Tous les utilisateur⋅rices :
|
||||||
- Positifs : {{ summary.total_positive_user }} soit {{ summary.balance_positive_user }} euros
|
- Positifs : {{ summary.total_positive_user }} soit {{ summary.balance_positive_user / 100 }} €
|
||||||
- Neutres : {{ summary.total_zero_user }}
|
- Neutres : {{ summary.total_zero_user }}
|
||||||
- Négatifs : {{ summary.total_negative_user }} soit {{ summary.balance_negative_user }} euros
|
- Négatifs : {{ summary.total_negative_user }} soit {{ summary.balance_negative_user / 100 }} €
|
||||||
|
|
||||||
Les adhérents BDE :
|
Les {{ summary.total_positive_user_bde + summary.total_zero_user_bde + summary.total_negative_user_bde }} adhérent⋅es BDE :
|
||||||
- Positifs : {{ summary.total_positive_user_bde }} soit {{ summary.balance_positive_user_bde }} euros
|
- Positifs : {{ summary.total_positive_user_bde }} soit {{ summary.balance_positive_user_bde / 100 }} €
|
||||||
- Neutres : {{ summary.total_zero_user_bde }}
|
- Neutres : {{ summary.total_zero_user_bde }}
|
||||||
- Négatifs : {{ summary.total_negative_user_bde }} soit {{ summary.balance_negative_user_bde }} euros
|
- Négatifs : {{ summary.total_negative_user_bde }} soit {{ summary.balance_negative_user_bde /100 }} €
|
||||||
|
|
||||||
Clubs :
|
Clubs :
|
||||||
- Positifs : {{ summary.total_positive_club }} soit {{ summary.balance_positive_club }} euros
|
- Positifs : {{ summary.total_positive_club }} soit {{ summary.balance_positive_club / 100 }} €
|
||||||
- Neutres : {{ summary.total_zero_club }}
|
- Neutres : {{ summary.total_zero_club }}
|
||||||
- Négatifs : {{ summary.total_negative_club }} soit {{ summary.balance_negative_club }} euros
|
- Négatifs : {{ summary.total_negative_club }} soit {{ summary.balance_negative_club / 100 }} €
|
||||||
|
|
||||||
Clubs hors BDE / Kfet et club dont le nom fini par "- BDE" :
|
Clubs hors BDE / Kfet et club dont le nom fini par "- BDE" :
|
||||||
- Positifs : {{ summary.total_positive_club_nbde }} soit {{ summary.balance_positive_club_nbde }} euros
|
- Positifs : {{ summary.total_positive_club_nbde }} soit {{ summary.balance_positive_club_nbde / 100 }} €
|
||||||
- Neutres : {{ summary.total_zero_club_nbde }}
|
- Neutres : {{ summary.total_zero_club_nbde }}
|
||||||
- Négatifs : {{ summary.total_negative_club_nbde }} soit {{ summary.balance_negative_club_nbde }} euros
|
- Négatifs : {{ summary.total_negative_club_nbde }} soit {{ summary.balance_negative_club_nbde / 100 }} €
|
||||||
|
|
||||||
Progression :
|
Progression :
|
||||||
- Ceci correspond à une différence de {{ balance_difference_user }} euros pour les utilisateurs
|
- Ceci correspond à une différence de {{ balance_difference_user / 100 }} € pour les utilisateur⋅rices
|
||||||
- Ceci correspond à une différence de {{ balance_difference_club }} euros pour les clubs
|
- Ceci correspond à une différence de {{ balance_difference_club / 100 }} € pour les clubs
|
||||||
|
|
||||||
--
|
--
|
||||||
Le BDE
|
Le BDE
|
||||||
|
|
|
@ -5,13 +5,13 @@ from django.contrib import admin
|
||||||
from note_kfet.admin import admin_site
|
from note_kfet.admin import admin_site
|
||||||
|
|
||||||
from .forms import ProductForm
|
from .forms import ProductForm
|
||||||
from .models import RemittanceType, Remittance, SogeCredit, Invoice, Product
|
from .models import Invoice, NoteSummary, Product, RemittanceType, Remittance, SogeCredit
|
||||||
|
|
||||||
|
|
||||||
@admin.register(RemittanceType, site=admin_site)
|
@admin.register(RemittanceType, site=admin_site)
|
||||||
class RemittanceTypeAdmin(admin.ModelAdmin):
|
class RemittanceTypeAdmin(admin.ModelAdmin):
|
||||||
"""
|
"""
|
||||||
Admin customisation for RemiitanceType
|
Admin customisation for RemittanceType
|
||||||
"""
|
"""
|
||||||
list_display = ('note', )
|
list_display = ('note', )
|
||||||
|
|
||||||
|
@ -55,3 +55,19 @@ class InvoiceAdmin(admin.ModelAdmin):
|
||||||
"""
|
"""
|
||||||
list_display = ('object', 'id', 'bde', 'name', 'date', 'acquitted',)
|
list_display = ('object', 'id', 'bde', 'name', 'date', 'acquitted',)
|
||||||
inlines = (ProductInline,)
|
inlines = (ProductInline,)
|
||||||
|
|
||||||
|
|
||||||
|
@admin.register(NoteSummary, site=admin_site)
|
||||||
|
class NoteSummaryAdmin(admin.ModelAdmin):
|
||||||
|
"""
|
||||||
|
Admin customisation for NoteSummary
|
||||||
|
"""
|
||||||
|
list_display = (
|
||||||
|
'date', 'total_positive_user', 'balance_positive_user', 'total_positive_user_bde',
|
||||||
|
'balance_positive_user_bde', 'total_zero_user', 'total_zero_user_bde', 'total_negative_user',
|
||||||
|
'balance_negative_user', 'total_negative_user_bde', 'balance_negative_user_bde',
|
||||||
|
'total_vnegative_user', 'balance_vnegative_user', 'total_vnegative_user_bde',
|
||||||
|
'balance_vnegative_user_bde', 'total_positive_club', 'balance_positive_club',
|
||||||
|
'total_positive_club_nbde', 'balance_positive_club_nbde', 'total_zero_club', 'total_zero_club_nbde',
|
||||||
|
'total_negative_club', 'balance_negative_club', 'total_negative_club_nbde', 'balance_negative_club_nbde',
|
||||||
|
)
|
||||||
|
|
|
@ -0,0 +1,49 @@
|
||||||
|
# Generated by Django 2.2.28 on 2024-08-07 12:09
|
||||||
|
|
||||||
|
import datetime
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('treasury', '0008_auto_20240322_0045'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.CreateModel(
|
||||||
|
name='NoteSummary',
|
||||||
|
fields=[
|
||||||
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||||
|
('date', models.DateField(default=datetime.date.today, verbose_name='Date')),
|
||||||
|
('total_positive_user', models.PositiveIntegerField(verbose_name='Total positive user')),
|
||||||
|
('balance_positive_user', models.PositiveIntegerField(verbose_name='Balance positive user')),
|
||||||
|
('total_positive_user_bde', models.PositiveIntegerField(verbose_name='Total positive user BDE')),
|
||||||
|
('balance_positive_user_bde', models.PositiveIntegerField(verbose_name='Balance positive user BDE')),
|
||||||
|
('total_zero_user', models.PositiveIntegerField(verbose_name='Total zero user')),
|
||||||
|
('total_zero_user_bde', models.PositiveIntegerField(verbose_name='Total zero user BDE')),
|
||||||
|
('total_negative_user', models.PositiveIntegerField(verbose_name='Total negative user')),
|
||||||
|
('balance_negative_user', models.PositiveIntegerField(verbose_name='Balance negative user')),
|
||||||
|
('total_negative_user_bde', models.PositiveIntegerField(verbose_name='Total negative user BDE')),
|
||||||
|
('balance_negative_user_bde', models.PositiveIntegerField(verbose_name='Balance negative user BDE')),
|
||||||
|
('total_vnegative_user', models.PositiveIntegerField(verbose_name='Total very negative user')),
|
||||||
|
('balance_vnegative_user', models.PositiveIntegerField(verbose_name='Balance very negative user')),
|
||||||
|
('total_vnegative_user_bde', models.PositiveIntegerField(verbose_name='Total very negative user BDE')),
|
||||||
|
('balance_vnegative_user_bde', models.PositiveIntegerField(verbose_name='Balance very negative user BDE')),
|
||||||
|
('total_positive_club', models.PositiveIntegerField(verbose_name='Total positive club')),
|
||||||
|
('balance_positive_club', models.PositiveIntegerField(verbose_name='Balance positive club')),
|
||||||
|
('total_positive_club_nbde', models.PositiveIntegerField(verbose_name='Total positive club nbde')),
|
||||||
|
('balance_positive_club_nbde', models.PositiveIntegerField(verbose_name='Balance positive club nbde')),
|
||||||
|
('total_zero_club', models.PositiveIntegerField(verbose_name='Total zero club')),
|
||||||
|
('total_zero_club_nbde', models.PositiveIntegerField(verbose_name='Total zero club nbde')),
|
||||||
|
('total_negative_club', models.PositiveIntegerField(verbose_name='Total negative club')),
|
||||||
|
('balance_negative_club', models.PositiveIntegerField(verbose_name='Balance negative club')),
|
||||||
|
('total_negative_club_nbde', models.PositiveIntegerField(verbose_name='Total negative club nbde')),
|
||||||
|
('balance_negative_club_nbde', models.PositiveIntegerField(verbose_name='Balance negative club nbde')),
|
||||||
|
],
|
||||||
|
options={
|
||||||
|
'verbose_name': 'Summary',
|
||||||
|
'verbose_name_plural': 'Summaries',
|
||||||
|
},
|
||||||
|
),
|
||||||
|
]
|
Loading…
Reference in New Issue