Changeset 15141
- Timestamp:
- 18 Sep 2018, 06:27:29 (6 years ago)
- Location:
- main/waeup.kofa/branches/henrik-transcript-workflow/src/waeup/kofa/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/branches/henrik-transcript-workflow/src/waeup/kofa/students/permissions.py
r15134 r15141 158 158 class TranscriptOfficer(grok.Role): 159 159 """The Transcript Officer is allowed to view, to validate and to 160 release student transcripts. 160 release student transcripts. The officer is also allowed to 161 manage student data (global role only). 161 162 """ 162 163 grok.name('waeup.TranscriptOfficer') … … 167 168 'waeup.viewStudent', 168 169 'waeup.viewStudentsContainer', 170 'waeup.manageStudent', 169 171 ) 170 172 -
main/waeup.kofa/branches/henrik-transcript-workflow/src/waeup/kofa/students/tests/test_browser.py
r15140 r15141 2120 2120 print "Sample PDF transcript.pdf written to %s" % path 2121 2121 2122 def test_ release_transcript(self):2122 def test_process_transcript(self): 2123 2123 IWorkflowState(self.student).setState('transcript requested') 2124 2124 notify(grok.ObjectModifiedEvent(self.student)) … … 2151 2151 self.browser.getLink("K1000000").click() 2152 2152 self.assertFalse('Release transcript request' in self.browser.contents) 2153 # Officer has to validate the transcript 2153 # Officers can still edit studycourse, studylevel and course tickets. 2154 self.browser.open(self.studycourse_path + '/manage') 2155 self.assertTrue('Undergraduate Full-Time</option>' in self.browser.contents) 2156 self.browser.getControl(name="form.certificate").value = ['CERT1'] 2157 self.browser.getControl(name="form.current_session").value = ['2004'] 2158 self.browser.getControl(name="form.current_verdict").value = ['A'] 2159 self.browser.getControl(name="form.entry_mode").value = ['ug_ft'] 2160 self.browser.getControl("Save").click() 2161 self.browser.getControl(name="form.current_level").value = ['100'] 2162 self.browser.getControl("Save").click() 2163 self.browser.getControl(name="addlevel").value = ['100'] 2164 self.browser.getControl(name="level_session").value = ['2004'] 2165 self.browser.getControl("Add study level").click() 2166 self.browser.getLink("100").click() 2167 self.browser.getLink("Manage").click() 2168 self.browser.getControl(name="form.level_session").value = ['2002'] 2169 self.browser.getControl("Save").click() 2170 self.browser.getLink("COURSE1").click() 2171 self.browser.getLink("Manage").click() 2172 self.browser.getControl("Save").click() 2173 self.assertTrue('Form has been saved' in self.browser.contents) 2174 # Officer can validate the transcript 2175 self.browser.open(self.student_path) 2154 2176 self.browser.getLink("Validate transcript").click() 2155 2156 2157 2158 2159 self.assertTrue('Release transcript' in self.browser.contents) 2160 # Now the transcript can be released. 2177 # After validation all manage forms are locked. 2178 self.browser.open(self.studycourse_path + '/manage') 2179 self.assertTrue('The requested form is locked' in self.browser.contents) 2180 self.assertFalse('Undergraduate Full-Time</option>' in self.browser.contents) 2181 self.browser.open(self.studycourse_path + '/100/manage') 2182 self.assertTrue('The requested form is locked' in self.browser.contents) 2183 self.browser.open(self.studycourse_path + '/100/COURSE1/manage') 2184 self.assertTrue('The requested form is locked' in self.browser.contents) 2185 # Officer can release the transcript 2186 self.browser.open(self.student_path) 2161 2187 self.browser.getLink("Release transcript").click() 2162 2188 self.assertTrue(' UTC K1000000 wrote:<br><br>Comment line 1 <br>'
Note: See TracChangeset for help on using the changeset viewer.