Ra0 effective

This commit is contained in:
Alseidon 2020-12-09 22:11:21 +01:00
parent 73c068055b
commit 319db68655
2 changed files with 6 additions and 2 deletions

View file

@ -1,5 +1,9 @@
{% extends "base_title.html" %} {% extends "base_title.html" %}
{% block realcontent %} {% block realcontent %}
<p> Order 66 done </p> <h2>Remise à zéro des membres COF</h2>
<p> Voulez-vous vraiment remettre à zéro le statut COF de tous les membres actuels ? </p>
<form action="" method="POST">
<input type='submit' value="Confirmer">{% csrf_token %}
</form>
{% endblock %} {% endblock %}

View file

@ -81,7 +81,7 @@ class HomeView(LoginRequiredMixin, TemplateView):
class ResetComptes(LoginRequiredMixin, TemplateView): class ResetComptes(LoginRequiredMixin, TemplateView):
template_name = "gestioncof/reset_comptes.html" template_name = "gestioncof/reset_comptes.html"
def get(self, request): def post(self, request):
for profile in CofProfile.objects.all(): for profile in CofProfile.objects.all():
profile.is_cof = False profile.is_cof = False
profile.mailing_cof = False profile.mailing_cof = False