fnp
/
wolnelektury.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Minor Django version bump.
[wolnelektury.git]
/
src
/
club
/
forms.py
diff --git
a/src/club/forms.py
b/src/club/forms.py
index
2ebe4e5
..
d0568c0
100644
(file)
--- a/
src/club/forms.py
+++ b/
src/club/forms.py
@@
-8,7
+8,7
@@
from . import models
from .payu.forms import CardTokenForm
from .payu.forms import CardTokenForm
-class ScheduleForm(
NewsletterForm, forms.Model
Form):
+class ScheduleForm(
forms.ModelForm, Newsletter
Form):
class Meta:
model = models.Schedule
fields = ['monthly', 'amount', 'email']
class Meta:
model = models.Schedule
fields = ['monthly', 'amount', 'email']
@@
-24,6
+24,10
@@
class ScheduleForm(NewsletterForm, forms.ModelForm):
raise forms.ValidationError('Minimalna kwota to %d zł.' % club.min_amount)
return value
raise forms.ValidationError('Minimalna kwota to %d zł.' % club.min_amount)
return value
+ def save(self, *args, **kwargs):
+ NewsletterForm.save(self, *args, **kwargs)
+ return super().save(*args, **kwargs)
+
class PayUCardTokenForm(CardTokenForm):
def get_queryset(self, view):
class PayUCardTokenForm(CardTokenForm):
def get_queryset(self, view):