- Timestamp:
- 7 Nov 2019, 15:43:51 (5 years ago)
- Location:
- main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/etranzact
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/etranzact/applicantsbrowser.py
r15768 r15770 42 42 try: 43 43 return getattr(grok.getSite()['configuration'][str(session)], 44 'etranzact_ payoutlet_enabled', False)44 'etranzact_webconnect_enabled', False) 45 45 except KeyError: 46 46 return False … … 58 58 def target_url(self): 59 59 if not module_activated( 60 self.context. student.current_session, self.context):60 self.context.__parent__.__parent__.year, self.context): 61 61 return '' 62 62 if self.context.p_state != 'unpaid': … … 76 76 def target_url(self): 77 77 if not module_activated( 78 self.context. student.current_session, self.context):78 self.context.__parent__.__parent__.year, self.context): 79 79 return '' 80 80 if self.context.p_state in ('paid', 'waived'): … … 107 107 def init_update(self): 108 108 if not module_activated( 109 self.context. student.current_session, self.context):109 self.context.__parent__.__parent__.year, self.context): 110 110 return _("Etranzact payments deactivated.") 111 111 if self.context.p_state == 'paid': … … 158 158 super(EtranzactReceiveResponseApplicant, self).update() 159 159 if not module_activated( 160 self.context. student.current_session, self.context):160 self.context.__parent__.__parent__.year, self.context): 161 161 return 162 162 applicant = self.context.__parent__ … … 192 192 def update(self): 193 193 if not module_activated( 194 self.context. student.current_session, self.context):194 self.context.__parent__.__parent__.year, self.context): 195 195 return 196 196 if self.context.p_state in ('paid', 'waived'): -
main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/etranzact/payoutletbrowser.py
r15755 r15770 44 44 grok.templatedir('browser_templates') 45 45 46 def module_activated(session): 46 def module_activated(session, payment): 47 if payment.r_company and payment.r_company != 'etranzact': 48 return False 47 49 try: 48 50 return getattr(grok.getSite()['configuration'][str(session)], … … 61 63 @property 62 64 def target_url(self): 63 if not module_activated(self.context.__parent__.__parent__.year): 65 if not module_activated( 66 self.context.__parent__.__parent__.year, self.context): 64 67 return '' 65 68 if self.context.p_state in ('paid', 'waived'): … … 77 80 @property 78 81 def target_url(self): 79 if not module_activated(self.context.student.current_session): 82 if not module_activated( 83 self.context.student.current_session, self.context): 80 84 return '' 81 85 if self.context.p_state in ('paid', 'waived'): … … 98 102 99 103 def update(self): 100 if not module_activated(self.context.student.current_session): 104 if not module_activated( 105 self.context.student.current_session, self.context): 101 106 return 102 if self.context.r_company and self.context.r_company != 'etranzact':103 return _("Payment ticket has been used for another payment gateway.")104 107 super(EtranzactEnterPinPageStudent, self).update() 105 108 # Already now it becomes an Etranzact payment. We set the net amount … … 129 132 130 133 def update(self, confirmation_number=None): 131 if not module_activated(self.context.student.current_session): 134 if not module_activated( 135 self.context.student.current_session, self.context): 132 136 return 133 137 if self.context.p_state == 'paid': … … 163 167 164 168 def update(self, confirmation_number=None): 165 if not module_activated(self.context.__parent__.__parent__.year): 169 if not module_activated( 170 self.context.__parent__.__parent__.year, self.context): 166 171 return 167 172 if self.context.p_state == 'paid': -
main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/etranzact/studentsbrowser.py
r15755 r15770 37 37 grok.templatedir('browser_templates') 38 38 39 def module_activated(session): 39 def module_activated(session, payment): 40 if payment.r_company and payment.r_company != 'etranzact': 41 return False 40 42 try: 41 43 return getattr(grok.getSite()['configuration'][str(session)], … … 55 57 @property 56 58 def target_url(self): 57 if not module_activated(self.context.student.current_session): 59 if not module_activated( 60 self.context.student.current_session, self.context): 58 61 return '' 59 62 if self.context.p_state != 'unpaid': … … 72 75 @property 73 76 def target_url(self): 74 if not module_activated(self.context.student.current_session): 77 if not module_activated( 78 self.context.student.current_session, self.context): 75 79 return '' 76 80 if self.context.p_state in ('paid', 'waived'): … … 102 106 103 107 def init_update(self): 104 if not module_activated(self.context.student.current_session): 108 if not module_activated( 109 self.context.student.current_session, self.context): 105 110 return _("Etranzact payments deactivated.") 106 111 if self.context.p_state == 'paid': … … 152 157 def update(self): 153 158 super(EtranzactReceiveResponseStudent, self).update() 154 if not module_activated(self.context.student.current_session): 159 if not module_activated( 160 self.context.student.current_session, self.context): 155 161 return 156 162 student = self.context.student … … 185 191 186 192 def update(self): 187 if not module_activated(self.context.student.current_session): 193 if not module_activated( 194 self.context.student.current_session, self.context): 188 195 return 189 196 if self.context.p_state in ('paid', 'waived'):
Note: See TracChangeset for help on using the changeset viewer.