Changeset 13362
- Timestamp:
- 29 Oct 2015, 22:05:33 (9 years ago)
- Location:
- main/waeup.aaue/trunk/src/waeup/aaue/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py
r13360 r13362 43 43 NigeriaStudentPersonalEditFormPage, 44 44 NigeriaStudentPersonalManageFormPage, 45 NigeriaStudentClearanceEditFormPage, 45 46 ) 46 47 from waeup.aaue.students.interfaces import ( … … 49 50 ICustomStudent, 50 51 ICustomStudentPersonal, 51 ICustomStudentPersonalEdit) 52 ICustomStudentPersonalEdit, 53 ICustomUGStudentClearance) 52 54 from waeup.aaue.interfaces import MessageFactory as _ 53 55 … … 75 77 form_fields[ 76 78 'personal_updated'].custom_widget = FriendlyDatetimeDisplayWidget('le') 79 80 class CustomStudentClearanceEditFormPage(NigeriaStudentClearanceEditFormPage): 81 """ View to edit student clearance data by student 82 """ 83 84 @property 85 def form_fields(self): 86 if self.context.is_postgrad: 87 form_fields = grok.AutoFields(ICustomPGStudentClearance).omit( 88 'clearance_locked', 'nysc_location', 'clr_code', 'officer_comment', 89 'physical_clearance_date') 90 else: 91 form_fields = grok.AutoFields(ICustomUGStudentClearance).omit( 92 'clearance_locked', 'clr_code', 'officer_comment', 93 'physical_clearance_date') 94 return form_fields 77 95 78 96 class CustomStartClearancePage(StartClearancePage): -
main/waeup.aaue/trunk/src/waeup/aaue/students/interfaces.py
r13351 r13362 22 22 from zope.component import getUtility 23 23 from waeup.kofa.interfaces import IKofaObject 24 from waeup.kofa.schema import PhoneNumber 24 from waeup.kofa.schema import PhoneNumber, FormattedDate 25 from kofacustom.nigeria.interfaces import LGASource 25 26 from kofacustom.nigeria.students.interfaces import ( 26 27 INigeriaStudentBase, INigeriaUGStudentClearance, INigeriaPGStudentClearance, … … 194 195 """ 195 196 197 date_of_birth = FormattedDate( 198 title = _(u'Date of Birth'), 199 required = True, 200 show_year = True, 201 ) 202 203 lga = schema.Choice( 204 source = LGASource(), 205 title = _(u'State / LGA'), 206 required = True, 207 ) 208 209 ICustomUGStudentClearance['lga'].order = INigeriaUGStudentClearance[ 210 'lga'].order 211 ICustomUGStudentClearance['date_of_birth'].order = INigeriaUGStudentClearance[ 212 'date_of_birth'].order 213 214 196 215 class ICustomPGStudentClearance(INigeriaPGStudentClearance): 197 216 """Representation of pg student clearance data.
Note: See TracChangeset for help on using the changeset viewer.