mirror of
https://github.com/ae-utbm/sith.git
synced 2026-10-30 22:29:32 +00:00
max amount for eboutic refills
This commit is contained in:
1 parent
39bbbc8878
commit
d41a3a524a
7 files changed
+97
-40
No files matched your search
+2
-1
@@ -32,7 +32,8 @@ class CurrencyField(models.DecimalField):
|
||||
res.append(MinValueValidator(self.min_value))
|
||||
return [*super().validators, *res]
|
||||
|
||||
def check(self, **kwargs):
|
||||
def check(self, **kwargs): # pragma: no cover
|
||||
# this is executed during runserver, but won't run in prod
|
||||
errors = super().check(**kwargs)
|
||||
for name, val in ("min_value", self.min_value), ("max_value", self.max_value):
|
||||
if not val:
|
||||
|
||||
Reference in new issue
Block a user