Changeset 16258 for main/kofacustom.iuokada/trunk/src/kofacustom
- Timestamp:
- 29 Sep 2020, 20:20:08 (4 years ago)
- Location:
- main/kofacustom.iuokada/trunk/src/kofacustom/iuokada
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/students/browser.py
r16255 r16258 121 121 form_fields = grok.AutoFields(ICustomStudentPersonalEdit).omit('personal_updated') 122 122 123 def update(self): 124 if not self.context.is_fresh: 125 self.flash('Not allowed.', type="danger") 126 self.redirect(self.url(self.context)) 127 return 128 super(CustomStudentPersonalEditFormPage, self).update() 129 return 130 131 123 132 class CustomStudentPersonalManageFormPage(NigeriaStudentPersonalManageFormPage): 124 133 """ Page to edit personal data -
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/students/viewlets.py
r16256 r16258 39 39 text = _('Edit registration bio data') 40 40 41 @property 42 def target_url(self): 43 if not self.context.is_fresh: 44 return '' 45 return self.view.url(self.view.context, self.target) 46 41 47 class SwitchLibraryAccessActionButton(ManageActionButton): 42 48 grok.order(7) … … 65 71 target = 'edit_personal' 66 72 73 @property 74 def target_url(self): 75 if not self.context.is_fresh: 76 return '' 77 return self.view.url(self.view.context, self.target) 78 67 79 class PersonalDataSlipActionButton(ManageActionButton): 68 80 grok.order(10) … … 73 85 target = 'personal_slip.pdf' 74 86 icon = 'actionicon_pdf.png' 87 88 @property 89 def target_url(self): 90 if not self.context.is_fresh: 91 return '' 92 return self.view.url(self.view.context, self.target) 75 93 76 94 class AddBalancePaymentActionButton(AddBalancePaymentActionButton): -
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/utils/utils.py
r16233 r16258 151 151 'fine': 'Fine', 152 152 'id_card': 'Student ID Card', 153 'required_combi': 'Required Combi Payment', 153 154 'pg_other': 'PG Other Charges', 154 155 }
Note: See TracChangeset for help on using the changeset viewer.