Changeset 8176 for main/waeup.kofa/trunk
- Timestamp:
- 16 Apr 2012, 09:16:34 (13 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/applicants/browser.py
r8173 r8176 55 55 FriendlyDateDisplayWidget, FriendlyDateDisplayWidget, 56 56 FriendlyDatetimeDisplayWidget) 57 from waeup.kofa.widgets.phonewidget import PhoneWidget58 57 from waeup.kofa.widgets.restwidget import ReSTDisplayWidget 59 58 … … 353 352 'firstname', 'middlename', 'lastname', 354 353 'email', 'phone') 355 form_fields['phone'].custom_widget = PhoneWidget356 354 label = _('Add applicant') 357 355 pnav = 3 … … 616 614 form_fields['student_id'].for_display = True 617 615 form_fields['applicant_id'].for_display = True 618 form_fields['phone'].custom_widget = PhoneWidget619 616 grok.template('applicanteditpage') 620 617 manage_applications = True … … 749 746 'screening_score', 750 747 ) 751 form_fields['phone'].custom_widget = PhoneWidget752 748 form_fields['applicant_id'].for_display = True 753 749 form_fields['reg_number'].for_display = True … … 872 868 form_fields = grok.AutoFields(IApplicantEdit).select( 873 869 'firstname', 'middlename', 'lastname', 'email', 'phone') 874 form_fields['phone'].custom_widget = PhoneWidget875 876 870 return form_fields 877 871 -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/interfaces.py
r8160 r8176 33 33 from waeup.kofa.interfaces import MessageFactory as _ 34 34 from waeup.kofa.payments.interfaces import IOnlinePayment 35 #from waeup.kofa.schoolgrades import ResultEntryField 35 from waeup.kofa.schema import PhoneNumber 36 36 from waeup.kofa.students.vocabularies import GenderSource 37 37 from waeup.kofa.university.vocabularies import ( … … 356 356 constraint=validate_email, 357 357 ) 358 phone = schema.TextLine(358 phone = PhoneNumber( 359 359 title = _(u'Phone'), 360 360 description = u'', -
main/waeup.kofa/trunk/src/waeup/kofa/browser/pages.py
r8079 r8176 61 61 from waeup.kofa.authentication import LocalRoleSetEvent 62 62 from waeup.kofa.widgets.restwidget import ReSTDisplayWidget 63 from waeup.kofa.widgets.phonewidget import PhoneWidget64 63 from waeup.kofa.authentication import get_principal_role_manager 65 64 from waeup.kofa.utils.helpers import get_user_account … … 430 429 grok.template('usereditformpage') 431 430 form_fields = grok.AutoFields(IUserAccount) 432 form_fields['phone'].custom_widget = PhoneWidget433 431 label = _('Add user') 434 432 … … 471 469 grok.require('waeup.manageUsers') 472 470 form_fields = grok.AutoFields(IUserAccount).omit('name') 473 form_fields['phone'].custom_widget = PhoneWidget474 471 475 472 def label(self): … … 552 549 'name', 'description', 'roles') 553 550 label = _(u"My Preferences") 554 form_fields['phone'].custom_widget = PhoneWidget555 551 556 552 def setUpWidgets(self, ignore_request=False): -
main/waeup.kofa/trunk/src/waeup/kofa/interfaces.py
r8079 r8176 33 33 from zope.schema.interfaces import IObject 34 34 from zope.schema.vocabulary import SimpleVocabulary, SimpleTerm 35 from waeup.kofa.schema import PhoneNumber 35 36 36 37 _ = MessageFactory = zope.i18nmessageid.MessageFactory('waeup.kofa') … … 394 395 required=False,) 395 396 396 phone = schema.TextLine(397 phone = PhoneNumber( 397 398 title = _(u'Phone'), 398 399 description = u'', … … 422 423 ) 423 424 424 phone = schema.TextLine(425 phone = PhoneNumber( 425 426 title = _(u'Phone'), 426 427 default = None, -
main/waeup.kofa/trunk/src/waeup/kofa/students/batching.py
r8174 r8176 63 63 @property 64 64 def available_fields(self): 65 fields = getFields(self.iface) 65 66 return sorted(list(set( 66 67 ['student_id','reg_number','matric_number', -
main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
r8173 r8176 49 49 FriendlyDatetimeDisplayWidget) 50 50 from waeup.kofa.widgets.restwidget import ReSTDisplayWidget 51 from waeup.kofa.widgets.phonewidget import PhoneWidget52 51 from waeup.kofa.students.interfaces import ( 53 52 IStudentsContainer, IStudent, … … 341 340 grok.require('waeup.manageStudent') 342 341 form_fields = grok.AutoFields(IStudentBase).omit('student_id') 343 form_fields['phone'].custom_widget = PhoneWidget344 342 grok.template('basemanagepage') 345 343 label = _('Manage base data') … … 1506 1504 form_fields = grok.AutoFields(IStudentBase).select( 1507 1505 'email', 'phone') 1508 form_fields['phone'].custom_widget = PhoneWidget1509 1506 label = _('Edit base data') 1510 1507 pnav = 4 -
main/waeup.kofa/trunk/src/waeup/kofa/students/interfaces.py
r8174 r8176 24 24 IKofaObject, academic_sessions_vocab, validate_email, IKofaUtils) 25 25 from waeup.kofa.interfaces import MessageFactory as _ 26 from waeup.kofa.schema import TextLineChoice, FormattedDate 26 from waeup.kofa.schema import TextLineChoice, FormattedDate, PhoneNumber 27 27 from waeup.kofa.students.vocabularies import ( 28 28 StudyLevelSource, contextual_reg_num_source, contextual_mat_num_source, … … 206 206 constraint=validate_email, 207 207 ) 208 phone = schema.TextLine(208 phone = PhoneNumber( 209 209 title = _(u'Phone'), 210 210 description = u'',
Note: See TracChangeset for help on using the changeset viewer.