author | Madhusudan.C.S <madhusudancs@gmail.com> |
Thu, 18 Nov 2010 16:16:28 +0530 | |
branch | payments |
changeset 276 | 325ec5a41269 |
parent 268 | 2d47a3eb5ec4 |
parent 275 | 679a9cab4bf1 |
child 294 | 7c12c63fef3b |
permissions | -rw-r--r-- |
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
1 |
from django.db import models |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
2 |
from django.contrib.auth.models import User |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
3 |
|
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
4 |
from project.scipycon.base import models as base_models |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
5 |
|
117
1b68c8aa6091
Renamed and reordered the imports.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
104
diff
changeset
|
6 |
from project.scipycon.registration.labels import WIFI_CHOICES |
1b68c8aa6091
Renamed and reordered the imports.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
104
diff
changeset
|
7 |
from project.scipycon.registration.labels import WIFI_HELP |
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
8 |
|
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
9 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
10 |
SIZE_CHOICES = ( |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
11 |
('S', 'S'), |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
12 |
('M', 'M'), |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
13 |
('L', 'L'), |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
14 |
('XL', 'XL'), |
137
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
15 |
('XXL', 'XXL'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
16 |
) |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
17 |
|
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
18 |
OCCUPATION_CHOICES = ( |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
19 |
('Education: Student', 'Education: Student'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
20 |
('Education: Faculty', 'Education: Faculty'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
21 |
('Education: Research', 'Education: Research'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
22 |
('Education: Other', 'Education: Other'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
23 |
('Corporate: Research', 'Corporate: Research'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
24 |
('Corporate: Other', 'Corporate: Other'), |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
25 |
('Other', 'Other') |
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
26 |
) |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
27 |
|
198
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
28 |
SEX_CHOICES = ( |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
29 |
('Male', 'Male'), |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
30 |
('Female', 'Female'), |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
31 |
) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
32 |
|
244
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
33 |
PAYMENT_MODE_CHOICES = ( |
245
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
34 |
('Cheque', 'Cheque'), |
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
35 |
('Demand Draft(DD)', 'Demand Draft(DD)'), |
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
36 |
('Net Banking', 'Net Banking') |
244
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
37 |
) |
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
38 |
|
272
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
39 |
|
104
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
40 |
class Wifi(base_models.ScopedBase): |
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
41 |
"""Defines wifi options at SciPy.in |
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
42 |
""" |
137
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
43 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
44 |
user = models.ForeignKey(User) |
104
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
45 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
46 |
wifi = models.CharField(max_length=50, choices=WIFI_CHOICES, |
104
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
47 |
help_text=WIFI_HELP, verbose_name="Laptop") |
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
48 |
|
272
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
49 |
registration_id = models.CharField( |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
50 |
max_length=255, verbose_name="Identification Number", |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
51 |
help_text="- Provide the serial or identification number at the " |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
52 |
"back of your laptop using which your laptop can be uniquely " |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
53 |
"identified. Ex: 8BDB8FB (Service Tag on Dell Laptops).<br /> - " |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
54 |
"This is for security reasons and will be used while you enter and " |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
55 |
"leave the venue.<br /> - Please don't provide the model number " |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
56 |
"like Dell Inspiron 1545. There may be many laptops of that model " |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
57 |
"and hence your laptop cannot be uniquely identified.", |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
58 |
blank=True, null=True) |
4801b7adbbc5
Add registration_id field to Wifi model and make necessary changes in the form.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
226
diff
changeset
|
59 |
|
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
60 |
|
198
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
61 |
class Accommodation(base_models.ScopedBase): |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
62 |
"""Defines accommodation information for SciPy.in |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
63 |
""" |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
64 |
|
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
65 |
user = models.ForeignKey(User) |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
66 |
|
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
67 |
sex = models.CharField(max_length=50, choices=SEX_CHOICES, |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
68 |
verbose_name="Gender", |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
69 |
blank=True, null=True) |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
70 |
|
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
71 |
accommodation_required = models.BooleanField( |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
72 |
default=False, blank=True, |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
73 |
verbose_name="Accommodation required", |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
74 |
help_text="Check if you need accommodation.") |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
75 |
|
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
76 |
accommodation_days = models.IntegerField( |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
77 |
default=0, blank=True, |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
78 |
verbose_name="Number of days", |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
79 |
help_text="Number of days the accommodation is required for?") |
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
80 |
|
92fbbbc4c97a
Added Django model for accommodation forms.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
137
diff
changeset
|
81 |
|
104
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
82 |
class Registration(base_models.ScopedBase): |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
83 |
"""Defines registration at SciPy.in""" |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
84 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
85 |
slug = models.SlugField() |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
86 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
87 |
registrant = models.ForeignKey(User) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
88 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
89 |
organisation = models.CharField(max_length=255, blank=True) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
90 |
|
137
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
91 |
occupation = models.CharField(max_length=255, |
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
92 |
choices=OCCUPATION_CHOICES, blank=True) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
93 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
94 |
city = models.CharField(max_length=255, blank=True) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
95 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
96 |
postcode = models.CharField(max_length=255, blank=True) |
104
1a83a26756c3
Renamed Base Model with scope and propogated it to other models.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
101
diff
changeset
|
97 |
|
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
98 |
phone_num = models.CharField(max_length=14, blank=True) |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
99 |
|
137
ec6e58c639bf
Added phone number, modified Occupation to be choice field.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
117
diff
changeset
|
100 |
tshirt = models.CharField(max_length=3, choices=SIZE_CHOICES) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
101 |
|
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
102 |
conference = models.BooleanField(default=False) |
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
103 |
|
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
104 |
tutorial = models.BooleanField(default=False) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
105 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
106 |
sprint = models.BooleanField(default=False) |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
107 |
|
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
108 |
final_conference = models.BooleanField(default=False) |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
109 |
|
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
110 |
final_tutorial = models.BooleanField(default=False) |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
111 |
|
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
112 |
final_sprint = models.BooleanField(default=False) |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
113 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
114 |
allow_contact = models.BooleanField(default=False) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
115 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
116 |
submitted = models.DateTimeField(auto_now_add=True) |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
117 |
|
94
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
118 |
last_mod = models.DateTimeField(auto_now=True) |
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
119 |
|
87e77aa18610
Moved the files to new Django app named scipycon and modified settings.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
diff
changeset
|
120 |
def __unicode__(self): |
101
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
121 |
return 'Registration for user: <%s %s> %s' % ( |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
122 |
self.registrant.first_name, |
61fc4aa7a09a
Added base app from which all other apps inherit and made corresponding changes in other apps.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
94
diff
changeset
|
123 |
self.registrant.last_name, self.registrant.email) |
236 | 124 |
|
125 |
||
244
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
126 |
class Payment(base_models.ScopedBase): |
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
127 |
"""Defines payment information for SciPy.in registrants |
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
128 |
""" |
238 | 129 |
|
244
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
130 |
user = models.ForeignKey(User) |
5e6411f210de
Add a skeleton payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
198
diff
changeset
|
131 |
|
260
c6f65d399286
Change the model field name of the payment from paid to confirmed.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
259
diff
changeset
|
132 |
confirmed = models.BooleanField( |
c6f65d399286
Change the model field name of the payment from paid to confirmed.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
259
diff
changeset
|
133 |
default=False, blank=True) |
248
0fc144c69e84
Add paid boolean field to payment model to know whether the user has already paid the fees or not.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
245
diff
changeset
|
134 |
|
245
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
135 |
type = models.CharField(max_length=25, choices=PAYMENT_MODE_CHOICES, |
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
136 |
verbose_name="Type", blank=True, null=True) |
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
137 |
|
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
138 |
details = models.CharField( |
6ba059b30281
Add type and detail fields for the payment model.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
244
diff
changeset
|
139 |
max_length=255, verbose_name="Details", |
259
93cc238021ae
Modify the help text for details field to be more harsh on users so that they are clear as to what they are supposed to provide.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
248
diff
changeset
|
140 |
help_text="If the payment mode was cheque or DD please provide " |
93cc238021ae
Modify the help text for details field to be more harsh on users so that they are clear as to what they are supposed to provide.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
248
diff
changeset
|
141 |
"the <font color='red'>cheque or DD number and the name of the bank " |
268
2d47a3eb5ec4
Modify the help text of payment details to reflect examples.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
260
diff
changeset
|
142 |
"and branch</font>. Example: 4536234, SBI, IIT Powai, Mumbai.<br/> " |
2d47a3eb5ec4
Modify the help text of payment details to reflect examples.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
260
diff
changeset
|
143 |
"If the payment mode was Net Banking please provide the <font " |
2d47a3eb5ec4
Modify the help text of payment details to reflect examples.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
260
diff
changeset
|
144 |
"color='red'>last four digits of the account number and the name " |
2d47a3eb5ec4
Modify the help text of payment details to reflect examples.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
260
diff
changeset
|
145 |
"of the account holder and the bank name</font> from which the " |
2d47a3eb5ec4
Modify the help text of payment details to reflect examples.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
260
diff
changeset
|
146 |
"transfer was made. Example: 8804, Harish Chandra", |
2d47a3eb5ec4
Modify the help text of payment details to reflect examples.
Madhusudan.C.S <madhusudancs@gmail.com>
parents:
260
diff
changeset
|
147 |
blank=True, null=True) |