Changeset 16277
- Timestamp:
- 12 Oct 2020, 09:35:47 (4 years ago)
- Location:
- main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/applicants
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/applicants/browser.py
r16276 r16277 55 55 ICustomPGApplicantEdit, ICustomUGApplicantEdit, 56 56 ICustomApplicantOnlinePayment, ICustomApplicantRefereeReport, 57 ITranscriptApplicant , ICustomApplicantRegisterUpdate57 ITranscriptApplicant 58 58 ) 59 59 from kofacustom.iuokada.interfaces import MessageFactory as _ … … 369 369 return form_fields 370 370 371 class CustomApplicantRegistrationPage(ApplicantRegistrationPage):372 """Captcha'd registration page for applicants.373 """374 @property375 def form_fields(self):376 form_fields = None377 if self.context.mode == 'update':378 form_fields = grok.AutoFields(ICustomApplicantRegisterUpdate).select(379 'lastname','reg_number','email')380 else: #if self.context.mode == 'create':381 form_fields = grok.AutoFields(ICustomUGApplicant).select(382 'firstname', 'middlename', 'lastname', 'email', 'phone')383 return form_fields384 385 371 class RefereeReportAddFormPage(RefereeReportAddFormPage): 386 372 """Add-form to add an referee report. This form -
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/applicants/interfaces.py
r16276 r16277 36 36 nats_vocab, GenderSource, StudyLevelSource) 37 37 from waeup.kofa.applicants.interfaces import ( 38 contextual_reg_num_source, IApplicantBaseData, IApplicantRefereeReport, 39 contextual_email_source, IApplicantRegisterUpdate) 38 contextual_reg_num_source, IApplicantBaseData, IApplicantRefereeReport) 40 39 from waeup.kofa.refereeentries import RefereeEntryField 41 40 from kofacustom.nigeria.applicants.interfaces import ( … … 145 144 """ 146 145 147 email = TextLineChoice(148 title = _(u'Email Address Test'),149 required = False,150 constraint=validate_email,151 source = contextual_email_source,152 )153 154 146 subtype = schema.Choice( 155 147 title = _(u'Application Subtype'), … … 387 379 adding them to the PG_OMIT* tuples. 388 380 """ 389 390 email = TextLineChoice(391 title = _(u'Email Address Test'),392 required = False,393 constraint=validate_email,394 source = contextual_email_source,395 )396 381 397 382 sponsor = schema.Choice( … … 618 603 required = True, 619 604 ) 620 email = TextLineChoice(621 title = _(u'Email Address Test'),622 required = False,605 email = schema.ASCIILine( 606 title = _(u'Email Address'), 607 required = True, 623 608 constraint=validate_email, 624 source = contextual_email_source,625 609 ) 626 610 date_of_birth = FormattedDate( … … 654 638 required = True, 655 639 ) 656 email = TextLineChoice(657 title = _(u'Email Address Test'),658 required = False,640 email = schema.ASCIILine( 641 title = _(u'Email Address'), 642 required = True, 659 643 constraint=validate_email, 660 source = contextual_email_source,661 644 ) 662 645 date_of_birth = FormattedDate( … … 673 656 'phone'].order = ICustomPGApplicantEdit['email'].order 674 657 675 class ICustomApplicantRegisterUpdate(IApplicantRegisterUpdate):676 """This is a representation of an applicant for first-time registration.677 This interface is used when applicants use the registration page to678 update their records.679 """680 681 email = TextLineChoice(682 title = _(u'Email Address Test'),683 required = False,684 constraint=validate_email,685 source = contextual_email_source,686 )687 688 658 class ICustomApplicantOnlinePayment(INigeriaApplicantOnlinePayment): 689 659 """An applicant payment via payment gateways.
Note: See TracChangeset for help on using the changeset viewer.