Changeset 16412
- Timestamp:
- 10 Mar 2021, 12:25:31 (4 years ago)
- Location:
- main/waeup.kofa/trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/CHANGES.txt
r16387 r16412 4 4 1.6.1.dev0 (unreleased) 5 5 ======================= 6 7 * Allow lecturers to export all course tickets, not only 8 those of current academic session. 6 9 7 10 * Disable clearance request button if not in state 'clearance started'. -
main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
r16387 r16412 4429 4429 return 4430 4430 4431 # Disabled on 10/03/21 4432 #def _set_session_values(self): 4433 # # We allow only current academic session 4434 # academic_session = grok.getSite()['configuration'].current_academic_session 4435 # if not academic_session: 4436 # self.sessions = [] 4437 # return 4438 # x = academic_sessions_vocab.getTerm(academic_session) 4439 # self.sessions = [(x.title, x.token)] 4440 # return 4441 4431 4442 def _set_session_values(self): 4432 # We allow only current academic session 4433 academic_session = grok.getSite()['configuration'].current_academic_session 4434 if not academic_session: 4435 self.sessions = [] 4436 return 4437 x = academic_sessions_vocab.getTerm(academic_session) 4438 self.sessions = [(x.title, x.token)] 4443 vocab_terms = academic_sessions_vocab.by_value.values() 4444 self.sessions = sorted( 4445 [(x.title, x.token) for x in vocab_terms], reverse=True) 4446 self.sessions += [('All Sessions', 'all')] 4439 4447 return 4440 4448 … … 4449 4457 self._set_mode_values() 4450 4458 self._set_exporter_values() 4451 if not self.sessions: 4452 self.flash( 4453 _('Academic session not set. ' 4454 'Please contact the administrator.'), 4455 type='danger') 4456 self.redirect(self.url(self.context)) 4457 return 4459 # Disabled on 10/03/21 4460 #if not self.sessions: 4461 # self.flash( 4462 # _('Academic session not set. ' 4463 # 'Please contact the administrator.'), 4464 # type='danger') 4465 # self.redirect(self.url(self.context)) 4466 # return 4458 4467 if START is None: 4459 4468 return -
main/waeup.kofa/trunk/src/waeup/kofa/students/export.py
r16351 r16412 114 114 """Get course tickets of `students`. 115 115 Filter course tickets which belong to this course code and 116 which are editable by lecturers. 116 which are editable by lecturers. The latter requirement was disabled 117 on 10/03/21. 117 118 """ 118 119 tickets = [] … … 124 125 if ticket.code != code: 125 126 continue 126 if not ticket.editable_by_lecturer: 127 continue 127 # Disabled on 10/03/21 128 #if not ticket.editable_by_lecturer: 129 # continue 128 130 if level not in ('all', None): 129 131 if level_obj.level in (10, 999, None) \ … … 545 547 tickets catalog and exports those course tickets which belong to the 546 548 given course code, meet level and session passed through at the 547 same time, and which are editable by lecturers . This exporter can only548 be called at course level in the academic section.549 same time, and which are editable by lecturers (disabled on 10/03/21). 550 This exporter can only be called at course level in the academic section. 549 551 """ 550 552 grok.name('lecturer') -
main/waeup.kofa/trunk/src/waeup/kofa/students/student.py
r16248 r16412 235 235 @property 236 236 def current_verdict(self): 237 level= getattr(237 current_verdict = getattr( 238 238 self.get('studycourse', None), 'current_verdict', None) 239 return level239 return current_verdict 240 240 241 241 @property -
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
r16333 r16412 4520 4520 self.browser.open(course1_path) 4521 4521 self.browser.getLink("Export student data").click() 4522 self.browser.getControl("Set export parameters").click() 4523 self.assertTrue( 4524 'Academic session not set. Please contact the administrator.' 4525 in self.browser.contents) 4526 self.app['configuration'].current_academic_session = 2004 4522 # Disabled on 10/03/21 4523 #self.browser.getControl("Set export parameters").click() 4524 #self.assertTrue( 4525 # 'Academic session not set. Please contact the administrator.' 4526 # in self.browser.contents) 4527 #self.app['configuration'].current_academic_session = 2004 4527 4528 self.browser.getControl("Set export parameters").click() 4528 4529 self.browser.getControl(name="exporter").value = ['lecturer']
Note: See TracChangeset for help on using the changeset viewer.