Changeset 7539
- Timestamp:
- 30 Jan 2012, 11:26:01 (13 years ago)
- Location:
- main/waeup.sirp/trunk/src/waeup/sirp/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/students/browser.py
r7538 r7539 57 57 ) 58 58 from waeup.sirp.students.catalog import search 59 from waeup.sirp.students.workflow import ( 59 from waeup.sirp.students.workflow import (ADMITTED, PAID, 60 60 CLEARANCE, REQUESTED, RETURNING, CLEARED, REGISTERED, VALIDATED) 61 61 from waeup.sirp.students.studylevel import StudentStudyLevel, CourseTicket … … 1748 1748 1749 1749 def update(self): 1750 if self.context.getStudent().state != 'admitted':1750 if self.context.getStudent().state != ADMITTED: 1751 1751 emit_lock_message(self) 1752 1752 return … … 2021 2021 2022 2022 def update(self): 2023 if self.context.getStudent().state != 'school fee paid':2023 if self.context.getStudent().state != PAID: 2024 2024 emit_lock_message(self) 2025 2025 return … … 2070 2070 2071 2071 def update(self): 2072 if self.context.getStudent().state != PAID: 2073 emit_lock_message(self) 2074 return 2072 2075 super(StudyLevelEditFormPage, self).update() 2073 2076 datatable.need() … … 2131 2134 'grade', 'score', 'core_or_elective', 'automatic') 2132 2135 2136 def update(self): 2137 if self.context.getStudent().state != PAID: 2138 emit_lock_message(self) 2139 return 2140 super(CourseTicketAddFormPage2, self).update() 2141 return 2142 2133 2143 @action('Add course ticket') 2134 2144 def addCourseTicket(self, **data): 2145 # Double bottom ... 2146 if self.context.getStudent().state != PAID: 2147 return 2135 2148 ticket = CourseTicket() 2136 2149 course = data['course'] -
main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_browser.py
r7521 r7539 399 399 self.assertEqual(self.browser.headers['Status'], '200 Ok') 400 400 self.assertEqual(self.browser.url, self.personal_student_path) 401 self.browser.getLink(" Manage").click()401 self.browser.getLink("Edit").click() 402 402 self.assertEqual(self.browser.headers['Status'], '200 Ok') 403 403 self.assertEqual(self.browser.url, self.edit_personal_student_path)
Note: See TracChangeset for help on using the changeset viewer.