simple upgrade/billing address form
This commit is contained in:
@@ -571,14 +571,14 @@ class PaidPlan(models.Model):
|
||||
clubsize = models.IntegerField(default=0)
|
||||
|
||||
def __unicode__(self):
|
||||
return '{name} - {shortname} at {price} EURO ({paymenttype} payment) / {paymentprocessor}'.format(
|
||||
return '{name} - {shortname} at {price} EURO ({paymenttype} payment)'.format(
|
||||
name = self.name,
|
||||
shortname = self.shortname,
|
||||
price = self.price,
|
||||
paymenttype = self.paymenttype,
|
||||
paymentprocessor = self.paymentprocessor,
|
||||
)
|
||||
|
||||
|
||||
|
||||
# Extension of User with rowing specific data
|
||||
class Rower(models.Model):
|
||||
@@ -3002,6 +3002,20 @@ class RowerImportExportForm(ModelForm):
|
||||
'trainingpeaks_auto_export',
|
||||
]
|
||||
|
||||
# Form to collect rower's Billing Info
|
||||
class RowerBillingAddressForm(ModelForm):
|
||||
class Meta:
|
||||
model = Rower
|
||||
fields = [
|
||||
'street_address',
|
||||
'city',
|
||||
'postal_code',
|
||||
'country'
|
||||
]
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(RowerBillingAddressForm, self).__init__(*args, **kwargs)
|
||||
self.fields['country'].required = True
|
||||
|
||||
|
||||
# Form to set rower's Email and Weight category
|
||||
|
||||
Reference in New Issue
Block a user