Changeset 7205 for main/waeup.sirp/trunk/src/waeup/sirp/browser
- Timestamp:
- 26 Nov 2011, 06:49:16 (13 years ago)
- Location:
- main/waeup.sirp/trunk/src/waeup/sirp/browser
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/browser/pages.py
r7202 r7205 54 54 IPasswordValidator) 55 55 from waeup.sirp.permissions import get_users_with_local_roles, get_all_roles 56 from waeup.sirp.students.catalog import search as searchstudents 56 57 from waeup.sirp.university.catalog import search 57 58 from waeup.sirp.university.vocabularies import course_levels … … 1369 1370 yield(dict(url=url, name=key, container=val)) 1370 1371 1372 class ShowStudentsPage(WAeUPPage): 1373 """Page that lists all students in the department. 1374 """ 1375 grok.context(IDepartment) 1376 grok.require('waeup.showStudents') 1377 grok.name('showstudents') 1378 pnav = 1 1379 label = 'Students' 1380 1381 @property 1382 def title(self): 1383 return self.context.longtitle() 1384 1385 @property 1386 def getStudents(self): 1387 hitlist = searchstudents(query=self.context.code, 1388 searchtype='depcode', view=self) 1389 return hitlist 1390 1391 def update(self, *args, **kw): 1392 datatable.need() 1393 return 1394 1371 1395 class DepartmentManageFormPage(WAeUPEditFormPage): 1372 1396 """Manage the basic properties of a `Department` instance. -
main/waeup.sirp/trunk/src/waeup/sirp/browser/viewlets.py
r7202 r7205 416 416 text = 'Manage department' 417 417 418 class ShowDepartmentStudentsActionButton(ManageActionButton): 419 """ 'Show students' button for departments. 420 """ 421 grok.context(IDepartment) 422 grok.view(DepartmentPage) 423 grok.require('waeup.showStudents') 424 icon = 'actionicon_student.png' 425 text = 'Show students' 426 target = 'showstudents' 427 418 428 class ManageCourseActionButton(ManageActionButton): 419 429 """ 'Edit settings' button for courses.
Note: See TracChangeset for help on using the changeset viewer.