From 2db46e3958f0881340e330a508ecc01248d8420d Mon Sep 17 00:00:00 2001 From: imperosol Date: Mon, 19 Oct 2026 19:49:18 +0200 Subject: [PATCH] add success message when refunding AE account --- counter/views/admin.py | 3 ++- locale/fr/LC_MESSAGES/django.po | 7 ++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/counter/views/admin.py b/counter/views/admin.py index e5e13306..50cf194b 100644 --- a/counter/views/admin.py +++ b/counter/views/admin.py @@ -408,11 +408,12 @@ class CounterRefillingListView( return super().get_context_data(**kwargs) | {"counter": self.counter} -class RefoundAccountView(UserPassesTestMixin, FormView): +class RefoundAccountView(UserPassesTestMixin, SuccessMessageMixin, FormView): """Create a selling with the same amount as the current user money.""" template_name = "counter/refound_account.jinja" form_class = CloseCustomerAccountForm + success_message = _("%(user)s's AE account has been emptied") def test_func(self): return self.request.user.is_root or self.request.user.is_in_group( diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po index eadaed9e..d3c30c7e 100644 --- a/locale/fr/LC_MESSAGES/django.po +++ b/locale/fr/LC_MESSAGES/django.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2026-10-09 21:44+0200\n" +"POT-Creation-Date: 2026-10-19 19:45+0200\n" "PO-Revision-Date: 2016-07-18\n" "Last-Translator: Maréchal \n" @@ -4413,6 +4413,11 @@ msgstr "" msgid "returnable product : %(returnable)s -> %(returned)s" msgstr "produit consigné : %(returnable)s -> %(returned)s" +#: counter/views/admin.py +#, python-format +msgid "%(user)s's AE account has been emptied" +msgstr "Le compte de %(user)s a été vidé" + #: counter/views/cash.py msgid "10 cents" msgstr "10 centimes"