Changeset 11291 for main/waeup.aaue/trunk/src/waeup
- Timestamp:
- 22 Feb 2014, 20:41:35 (11 years ago)
- Location:
- main/waeup.aaue/trunk
- Files:
-
- 4 deleted
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.aaue/trunk
- Property svn:ignore
-
old new 5 5 develop-eggs 6 6 parts 7 sources 7 8 var
-
- Property svn:mergeinfo changed
/main/waeup.aaue/branches/henrik-diazo-themed (added) merged: 11100-11101,11110,11127,11133,11151,11250
- Property svn:ignore
-
main/waeup.aaue/trunk/src/waeup/aaue
- Property svn:mergeinfo changed
/main/waeup.aaue/branches/henrik-diazo-themed/src/waeup/aaue (added) merged: 11100,11250
- Property svn:mergeinfo changed
-
main/waeup.aaue/trunk/src/waeup/aaue/applicants/browser.py
r10929 r11291 35 35 UG_OMIT_PDF_FIELDS, 36 36 UG_OMIT_MANAGE_FIELDS, 37 UG_OMIT_EDIT_FIELDS, 38 PG_OMIT_DISPLAY_FIELDS, 39 PG_OMIT_PDF_FIELDS, 40 PG_OMIT_MANAGE_FIELDS, 41 PG_OMIT_EDIT_FIELDS) 37 UG_OMIT_EDIT_FIELDS) 42 38 from waeup.aaue.applicants.interfaces import ( 43 39 ICustomApplicant, 44 40 ICustomUGApplicant, 45 ICustomPGApplicant, 46 ICustomPGApplicantEdit, 47 ICustomUGApplicantEdit) 41 ICustomUGApplicantEdit 42 ) 48 43 49 UG_OMIT_PDF_FIELDS = [50 element for element in UG_OMIT_PDF_FIELDS if not element == 'phone'] 44 UG_OMIT_PDF_FIELDS = tuple([ 45 element for element in UG_OMIT_PDF_FIELDS if not element == 'phone']) 51 46 UG_OMIT_PDF_FIELDS += ('reg_number','alr_fname', 'alr_no', 'alr_date', 52 47 'alr_results', 'notice') 48 49 FP_OMIT_FIELDS = ('hq_type', 'hq_fname', 'hq_matric_no', 50 'hq_degree', 'hq_school', 'hq_session', 'hq_disc') 51 FP_OMIT_DISPLAY_FIELDS = UG_OMIT_DISPLAY_FIELDS + FP_OMIT_FIELDS 52 FP_OMIT_PDF_FIELDS = UG_OMIT_PDF_FIELDS + FP_OMIT_FIELDS 53 FP_OMIT_MANAGE_FIELDS = UG_OMIT_MANAGE_FIELDS + FP_OMIT_FIELDS 54 FP_OMIT_EDIT_FIELDS = UG_OMIT_EDIT_FIELDS + FP_OMIT_FIELDS 53 55 54 56 class CustomApplicantDisplayFormPage(NigeriaApplicantDisplayFormPage): … … 58 60 @property 59 61 def form_fields(self): 60 if self.target is not None and self.target.startswith('pg'):61 form_fields = grok.AutoFields(ICustomPGApplicant)62 for field in PG_OMIT_DISPLAY_FIELDS:62 form_fields = grok.AutoFields(ICustomUGApplicant) 63 if self.target is not None and self.target.startswith('fp'): 64 for field in FP_OMIT_DISPLAY_FIELDS: 63 65 form_fields = form_fields.omit(field) 64 66 else: 65 form_fields = grok.AutoFields(ICustomUGApplicant)66 67 for field in UG_OMIT_DISPLAY_FIELDS: 67 68 form_fields = form_fields.omit(field) … … 104 105 @property 105 106 def form_fields(self): 106 if self.target is not None and self.target.startswith('pg'):107 form_fields = grok.AutoFields(ICustomPGApplicant)108 for field in PG_OMIT_PDF_FIELDS:107 form_fields = grok.AutoFields(ICustomUGApplicant) 108 if self.target is not None and self.target.startswith('fp'): 109 for field in FP_OMIT_PDF_FIELDS: 109 110 form_fields = form_fields.omit(field) 110 111 else: 111 form_fields = grok.AutoFields(ICustomUGApplicant)112 112 for field in UG_OMIT_PDF_FIELDS: 113 113 form_fields = form_fields.omit(field) … … 128 128 @property 129 129 def form_fields(self): 130 if self.target is not None and self.target.startswith('pg'):131 form_fields = grok.AutoFields(ICustomPGApplicant)132 for field in PG_OMIT_MANAGE_FIELDS:130 form_fields = grok.AutoFields(ICustomUGApplicant) 131 if self.target is not None and self.target.startswith('fp'): 132 for field in FP_OMIT_MANAGE_FIELDS: 133 133 form_fields = form_fields.omit(field) 134 134 else: 135 form_fields = grok.AutoFields(ICustomUGApplicant)136 135 for field in UG_OMIT_MANAGE_FIELDS: 137 136 form_fields = form_fields.omit(field) … … 146 145 @property 147 146 def form_fields(self): 148 if self.target is not None and self.target.startswith('pg'):149 form_fields = grok.AutoFields(ICustomPGApplicantEdit)150 for field in PG_OMIT_EDIT_FIELDS:147 form_fields = grok.AutoFields(ICustomUGApplicantEdit) 148 if self.target is not None and self.target.startswith('fp'): 149 for field in FP_OMIT_EDIT_FIELDS: 151 150 form_fields = form_fields.omit(field) 152 151 else: 153 form_fields = grok.AutoFields(ICustomUGApplicantEdit)154 152 for field in UG_OMIT_EDIT_FIELDS: 155 153 form_fields = form_fields.omit(field) -
main/waeup.aaue/trunk/src/waeup/aaue/browser/tests.py
r8444 r11291 49 49 shutil.rmtree(self.dc_root) 50 50 51 def test_custom_theme(self):52 self.browser.addHeader('Authorization', 'Basic mgr:mgrpw')53 self.browser.open('http://localhost/app/configuration')54 self.assertMatches('...AAUE Theme...', self.browser.contents)55 self.browser.getControl(name="form.skin").value = ['custom theme']56 self.browser.getControl("Save").click()57 self.browser.open('http://localhost/app/configuration')58 return59 60 51 #def test_access_live_url(self): 61 52 # # We can't access the system with basic authentication -
main/waeup.aaue/trunk/src/waeup/aaue/etranzact/browser.py
r10983 r11291 271 271 label = _('Requery eTranzact History') 272 272 action = 'query_history' 273 placeholder = _('Confirmation Number (PIN)') 273 274 274 275 class EtranzactEnterPinPageApplicant(EtranzactEnterPinPageStudent): -
main/waeup.aaue/trunk/src/waeup/aaue/etranzact/browser_templates/enterpin.pt
r9853 r11291 1 <form tal:attributes="action view/action" 2 method="POST" i18n:domain="waeup.aaue"> 3 <table class="form-table"> 4 <tbody> 5 <tr> 6 <td i18n:translate=""> 7 Confirmation Number (PIN): 8 </td> 9 <td> 10 <input name="confirmation_number" type="text" class="span5" maxlength="" 11 value="" /> 12 </td> 13 </tr> 14 <tr> 15 <td colspan="2"> 16 <input type="submit" name="SUBMIT" class="btn primary" 17 tal:attributes="value view/buttonname" /> 18 </td> 19 </tr> 20 </tbody> 21 </table> 1 <form method="POST" class="form-inline" tal:attributes="action view/action"> 2 <br /> 3 <div class="form-group half"> 4 <input name="confirmation_number" type="text" class="form-control" maxlength="" 5 value="" tal:attributes="placeholder view/placeholder"/> 6 </div> 7 <div class="form-group"> 8 <input type="submit" name="SUBMIT" class="btn btn-primary" 9 tal:attributes="value view/buttonname" /> 10 </div> 22 11 </form> -
main/waeup.aaue/trunk/src/waeup/aaue/etranzact/tests.py
r10978 r11291 71 71 self.browser.getLink("Query eTranzact History").click() 72 72 self.assertMatches( 73 '...Confirmation Number (PIN) :...',73 '...Confirmation Number (PIN)...', 74 74 self.browser.contents) 75 75
Note: See TracChangeset for help on using the changeset viewer.