Changeset 15210 for main/waeup.kofa/trunk/src/waeup/kofa
- Timestamp:
- 31 Oct 2018, 10:30:46 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
r15203 r15210 2129 2129 2130 2130 @property 2131 def actionsgroup1(self): 2132 if not self.with_hostel_selection: 2133 return [] 2131 def booking_allowed(self): 2134 2132 students_utils = getUtility(IStudentsUtils) 2135 2133 acc_details = students_utils.getAccommodationDetails(self.context.student) … … 2137 2135 self.context.student, acc_details) 2138 2136 if error_message: 2137 return False 2138 return True 2139 2140 @property 2141 def actionsgroup1(self): 2142 if not self.booking_allowed: 2143 return [] 2144 if not self.with_hostel_selection: 2139 2145 return [] 2140 2146 return [_('Save')] … … 2143 2149 def actionsgroup2(self): 2144 2150 if getattr(self.request.principal, 'user_type', None) == 'student': 2151 ## Book button can be disabled in custom packages by 2152 ## uncommenting the following lines. 2153 #if not self.booking_allowed: 2154 # return [] 2145 2155 return [_('Book accommodation')] 2146 2156 return [_('Book accommodation'), _('Remove selected')]
Note: See TracChangeset for help on using the changeset viewer.